forked from mindspore-Ecosystem/mindspore
add npu include path for test
This commit is contained in:
parent
72b6382d5d
commit
7072e470f4
|
@ -233,6 +233,18 @@ if(PLATFORM_ARM64)
|
|||
install(DIRECTORY ${TOP_DIR}/mindspore/lite/build/minddata/ DESTINATION ${TEST_CASE_DIR}
|
||||
COMPONENT ${RUNTIME_COMPONENT_NAME} FILES_MATCHING PATTERN "*.so")
|
||||
install(FILES ${JPEGTURBO_LIB_LIST} DESTINATION ${TEST_CASE_DIR})
|
||||
if(SUPPORT_NPU)
|
||||
install(FILES ${DDK_LIB_PATH}/libhiai.so DESTINATION ${TEST_CASE_DIR}
|
||||
COMPONENT ${RUNTIME_COMPONENT_NAME})
|
||||
install(FILES ${DDK_LIB_PATH}/libhiai_ir.so DESTINATION ${TEST_CASE_DIR}
|
||||
COMPONENT ${RUNTIME_COMPONENT_NAME})
|
||||
install(FILES ${DDK_LIB_PATH}/libhiai_ir_build.so DESTINATION ${TEST_CASE_DIR}
|
||||
COMPONENT ${RUNTIME_COMPONENT_NAME})
|
||||
if(EXISTS "${DDK_LIB_PATH}/libhiai_hcl_model_runtime.so")
|
||||
install(FILES ${DDK_LIB_PATH}/libhiai_hcl_model_runtime.so
|
||||
DESTINATION ${TEST_CASE_DIR} COMPONENT ${RUNTIME_COMPONENT_NAME})
|
||||
endif()
|
||||
endif()
|
||||
endif()
|
||||
elseif(PLATFORM_ARM32)
|
||||
if(SUPPORT_NPU)
|
||||
|
|
|
@ -127,7 +127,7 @@ if(MSLITE_ENABLE_NPU)
|
|||
if(DEFINED ENV{HWHIAI_DDK})
|
||||
message("HWHIAI_DDK=$ENV{HWHIAI_DDK}")
|
||||
else()
|
||||
message(FATAL_ERROR "please set HWHIAI_DDK, example: export HWHIAI_DDK=/root/usr/hwhiai-ddk-100.500.010.010/")
|
||||
message(FATAL_ERROR "please set HWHIAI_DDK, example: export HWHIAI_DDK=/root/usr/hwhiai-ddk-100.510.010.010/")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
|
|
|
@ -419,6 +419,7 @@ endif()
|
|||
|
||||
if(SUPPORT_NPU)
|
||||
include_directories(${DDK_PATH})
|
||||
include_directories(${DDK_INCLUDE_PATH})
|
||||
target_link_libraries(lite-test npu_kernel_mid c++_shared)
|
||||
endif()
|
||||
if(MSLITE_ENABLE_CONVERTER)
|
||||
|
|
|
@ -97,6 +97,7 @@ function Push_Files() {
|
|||
cp -a $1/mindspore-lite-$3-android-$2/runtime/third_party/hiai_ddk/lib/libhiai.so $4/libhiai.so || exit 1
|
||||
cp -a $1/mindspore-lite-$3-android-$2/runtime/third_party/hiai_ddk/lib/libhiai_ir.so $4/libhiai_ir.so || exit 1
|
||||
cp -a $1/mindspore-lite-$3-android-$2/runtime/third_party/hiai_ddk/lib/libhiai_ir_build.so $4/libhiai_ir_build.so || exit 1
|
||||
cp -a $1/mindspore-lite-$3-android-$2/runtime/third_party/hiai_ddk/lib/libhiai_hcl_model_runtime.so $4/libhiai_hcl_model_runtime.so
|
||||
cp -a $1/mindspore-lite-$3-android-$2/runtime/lib/libmindspore-lite.so $4/libmindspore-lite.so || exit 1
|
||||
cp -a $1/mindspore-lite-$3-android-$2/tools/benchmark/benchmark $4/benchmark || exit 1
|
||||
|
||||
|
|
|
@ -41,9 +41,6 @@ function Run_gpu_ut() {
|
|||
echo 'cd /data/local/tmp/ut_test' > adb_cmd.txt
|
||||
echo 'cp /data/local/tmp/libc++_shared.so ./' >> adb_cmd.txt
|
||||
echo 'cp /data/local/tmp/libgtest.so ./' >> adb_cmd.txt
|
||||
echo 'cp /data/local/tmp/libhiai.so ./' >> adb_cmd.txt
|
||||
echo 'cp /data/local/tmp/libhiai_ir.so ./' >> adb_cmd.txt
|
||||
echo 'cp /data/local/tmp/libhiai_ir_build.so ./' >> adb_cmd.txt
|
||||
echo 'chmod 777 lite-test' >> adb_cmd.txt
|
||||
|
||||
adb -s ${device_id} shell < adb_cmd.txt
|
||||
|
|
Loading…
Reference in New Issue