未验证 提交 640196c4 编写于 作者: S silingtong123 提交者: GitHub

test=develop, remove the tensorrt dll file from windows package (#24922)

上级 feba1318
...@@ -72,7 +72,10 @@ if(WITH_GPU) ...@@ -72,7 +72,10 @@ if(WITH_GPU)
endif() endif()
if (USE_TENSORRT AND WITH_GPU) if (USE_TENSORRT AND WITH_GPU)
set(TENSORRT_ROOT ${PADDLE_LIB_THIRD_PARTY_PATH}tensorrt) set(TENSORRT_ROOT "" CACHE STRING "The root directory of TensorRT library")
if("${TENSORRT_ROOT}" STREQUAL "")
message(FATAL_ERROR "The TENSORRT_ROOT is empty, you must assign it a value with CMake command. Such as: -DTENSORRT_ROOT=TENSORRT_ROOT_PATH ")
endif()
set(TENSORRT_INCLUDE_DIR ${TENSORRT_ROOT}/include) set(TENSORRT_INCLUDE_DIR ${TENSORRT_ROOT}/include)
set(TENSORRT_LIB_DIR ${TENSORRT_ROOT}/lib) set(TENSORRT_LIB_DIR ${TENSORRT_ROOT}/lib)
endif() endif()
......
...@@ -87,14 +87,7 @@ IF NOT EXIST "%source_path%\%demo_name%.cc" ( ...@@ -87,14 +87,7 @@ IF NOT EXIST "%source_path%\%demo_name%.cc" (
if "%demo_name%"=="windows_mobilenet" set model_name=mobilenet if "%demo_name%"=="windows_mobilenet" set model_name=mobilenet
if "%demo_name%"=="vis_demo" set model_name=mobilenet if "%demo_name%"=="vis_demo" set model_name=mobilenet
if "%demo_name%"=="simple_on_word2vec" set model_name=word2vec.inference.model if "%demo_name%"=="simple_on_word2vec" set model_name=word2vec.inference.model
if "%demo_name%"=="trt_mobilenet_demo" ( if "%demo_name%"=="trt_mobilenet_demo" set model_name=mobilenet
echo "The trt_mobilenet_demo need tensorRT inference library"
if NOT exist "%paddle_infernece_lib%\third_party\install\tensorrt" (
echo "------------It's not a tensorRT inference library------------"
goto:eof
)
set model_name=mobilenet
)
rem download model rem download model
if NOT EXIST "%source_path%\%model_name%.tar.gz" ( if NOT EXIST "%source_path%\%model_name%.tar.gz" (
......
...@@ -252,11 +252,6 @@ package_data['paddle.libs']= [] ...@@ -252,11 +252,6 @@ package_data['paddle.libs']= []
package_data['paddle.libs']=[('libwarpctc' if os.name != 'nt' else 'warpctc') + ext_name] package_data['paddle.libs']=[('libwarpctc' if os.name != 'nt' else 'warpctc') + ext_name]
shutil.copy('${WARPCTC_LIBRARIES}', libs_path) shutil.copy('${WARPCTC_LIBRARIES}', libs_path)
if '${TENSORRT_FOUND}' == 'ON' and os.name == 'nt':
shutil.copy(os.path.join('${TENSORRT_LIBRARY_DIR}', '${TR_INFER_RT}'), libs_path)
shutil.copy(os.path.join('${TENSORRT_LIBRARY_DIR}', '${TR_INFER_PLUGIN_RT}'), libs_path)
package_data['paddle.libs'] += ['${TR_INFER_RT}', '${TR_INFER_PLUGIN_RT}']
if '${WITH_MKL}' == 'ON': if '${WITH_MKL}' == 'ON':
shutil.copy('${MKLML_SHARED_LIB}', libs_path) shutil.copy('${MKLML_SHARED_LIB}', libs_path)
shutil.copy('${MKLML_SHARED_IOMP_LIB}', libs_path) shutil.copy('${MKLML_SHARED_IOMP_LIB}', libs_path)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册