Skip to content

Commit

Permalink
Merge branch 'eigen-benchmark'
Browse files Browse the repository at this point in the history
Replace amardillo+openblas with eigen, which provides parsing speed of over 9000 tokens/sec.
Fix HIT-SCIR#104 and HIT-SCIR#106.
  • Loading branch information
Oneplus committed May 23, 2015
2 parents 663adf9 + 7cfbe97 commit eac0146
Show file tree
Hide file tree
Showing 760 changed files with 80,040 additions and 128,436 deletions.
4 changes: 0 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ if (APPLE)
set(CMAKE_CXX_FLAGS "-std=c++11 -Wno-c++11-narrowing")
endif(APPLE)

if (MINGW)
set(CMAKE_CXX_FLAGS "-std=c++11 -Wno-narrowing -fpermissive")
endif (MINGW)

# -- config output directories
set (EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin)
set (LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib)
Expand Down
11 changes: 3 additions & 8 deletions src/console/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -52,16 +52,11 @@ set_target_properties (ner_cmdline PROPERTIES
RUNTIME_OUTPUT_DIRECTORY ${EXECUTABLE_OUTPUT_PATH}/examples/)


if (MSVC)
target_link_libraries (ltp_test
${THIRDPARTY_DIR}/openblas/lib/libopenblas.dll.a)
target_link_libraries (par_cmdline
${THIRDPARTY_DIR}/openblas/lib/libopenblas.dll.a)
else()
target_link_libraries (ltp_test openblas pthread)
if (NOT MSVC AND NOT MINGW)
target_link_libraries (ltp_test pthread)
target_link_libraries (cws_cmdline pthread)
target_link_libraries (pos_cmdline pthread)
target_link_libraries (par_cmdline openblas pthread)
target_link_libraries (par_cmdline pthread)
target_link_libraries (ner_cmdline pthread)
endif ()

Expand Down
15 changes: 2 additions & 13 deletions src/parser.n/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
include_directories (${SOURCE_DIR}/
${THIRDPARTY_DIR}/boost/include
${THIRDPARTY_DIR}/armadillo-5.100.1/include/)
${THIRDPARTY_DIR}/eigen-3.2.4/
)

set (nndepparser_VERSION "0.0.1")
set (nndepparser_SRC
Expand All @@ -22,18 +23,6 @@ set_target_properties (parser_shared_lib PROPERTIES
# redirect output binary to tools/train
add_executable (nndepparser main.cpp parser_frontend.cpp io.cpp ${nndepparser_SRC})
target_link_libraries (nndepparser boost_program_options_static_lib)
if (MSVC)
target_link_libraries (parser_static_lib
${THIRDPARTY_DIR}/openblas/lib/libopenblas.dll.a)
target_link_libraries (parser_shared_lib
${THIRDPARTY_DIR}/openblas/lib/libopenblas.dll.a)
target_link_libraries (nndepparser
${THIRDPARTY_DIR}/openblas/lib/libopenblas.dll.a)
else()
target_link_libraries (parser_static_lib openblas)
target_link_libraries (parser_shared_lib openblas)
target_link_libraries (nndepparser openblas)
endif ()
set_target_properties (nndepparser PROPERTIES
OUTPUT_NAME nndepparser
RUNTIME_OUTPUT_DIRECTORY ${TOOLS_DIR}/train/)
Expand Down
Loading

0 comments on commit eac0146

Please sign in to comment.