From 9ecd586a6db39d0d27334f1062fb5afe0d8d1b77 Mon Sep 17 00:00:00 2001 From: jianghui58 Date: Thu, 1 Jul 2021 15:06:22 +0800 Subject: [PATCH] add nnie models to ci --- cmake/package_lite.cmake | 6 +++++- mindspore/lite/test/config/models_nnie.cfg | 12 ++++++------ .../lite/test/st/scripts/nnie/run_converter_nnie.sh | 5 +++-- 3 files changed, 14 insertions(+), 9 deletions(-) diff --git a/cmake/package_lite.cmake b/cmake/package_lite.cmake index 20d2251bbac..eb7f7ec2b02 100644 --- a/cmake/package_lite.cmake +++ b/cmake/package_lite.cmake @@ -373,6 +373,10 @@ else() DESTINATION ${CONVERTER_ROOT_DIR}/lib COMPONENT ${RUNTIME_COMPONENT_NAME}) install(FILES ${glog_LIBPATH}/libglog.so.0.4.0 DESTINATION ${CONVERTER_ROOT_DIR}/lib RENAME libglog.so.0 COMPONENT ${RUNTIME_COMPONENT_NAME}) + if(MSLITE_ENABLE_NNIE) + install(FILES ${glog_LIBPATH}/libglog.so.0.4.0 DESTINATION ${CONVERTER_ROOT_DIR}/lib RENAME libglog.so + COMPONENT ${RUNTIME_COMPONENT_NAME}) + endif() __install_micro_wrapper() __install_micro_codegen() endif() @@ -390,7 +394,7 @@ else() install(FILES ${TOP_DIR}/mindspore/lite/build/tools/cropper/cropper_mapping_npu.cfg DESTINATION ${CROPPER_ROOT_DIR} COMPONENT ${RUNTIME_COMPONENT_NAME}) endif() - if(NOT SUPPORT_TRAIN) + if(MSLITE_ENABLE_CONVERTER) install(DIRECTORY ${TOP_DIR}/mindspore/lite/build/schema/ DESTINATION ${CONVERTER_ROOT_DIR}/include/schema COMPONENT ${RUNTIME_COMPONENT_NAME} FILES_MATCHING PATTERN "*.h") install(DIRECTORY ${TOP_DIR}/mindspore/core/abstract/ DESTINATION ${CONVERTER_ROOT_DIR}/include/core/abstract diff --git a/mindspore/lite/test/config/models_nnie.cfg b/mindspore/lite/test/config/models_nnie.cfg index 99b2087a7af..bccc71eb9e8 100644 --- a/mindspore/lite/test/config/models_nnie.cfg +++ b/mindspore/lite/test/config/models_nnie.cfg @@ -29,9 +29,9 @@ ci_models mtk_detect-mbv1-shortcut-400-400_nopostprocess_simplified 1 1 0 0.5 ci_models mtk_detect_mbv1_640_480_nopostprocess_simplified 1 1 0 0.5 ci_models ml_Heatmap_depth_180240 2 1 0 0.5 ci_models ml_video_edit_person_divison_video 2 1 0 0.5 -#ci_models bolt_deploy_color-server 1 1 0 1.9 -#ci_models hiai_video_seg 1 1 0 3.0 -#ci_models ml_video_edit_have_imageProcessLayer_interpTo145_20201015 1 1 0 2.8 -#ci_models ml_ocr_identify_card_fcny 1 1 0 0.5 -#ci_models ml_2012_ocr_rec_caffe 1 1 0 0.5 -#ci_models ml_tabel_recog 1 1 0 0.5 +ci_models bolt_deploy_color-server 1 1 0 1.9 +ci_models hiai_video_seg 1 1 0 3.0 +ci_models ml_video_edit_have_imageProcessLayer_interpTo145_20201015 1 1 0 2.8 +ci_models ml_ocr_identify_card_fcny 1 1 0 0.5 +ci_models ml_2012_ocr_rec_caffe 1 1 0 0.5 +ci_models ml_tabel_recog 1 1 0 0.5 diff --git a/mindspore/lite/test/st/scripts/nnie/run_converter_nnie.sh b/mindspore/lite/test/st/scripts/nnie/run_converter_nnie.sh index 4250a4903f1..a7a40c331c1 100755 --- a/mindspore/lite/test/st/scripts/nnie/run_converter_nnie.sh +++ b/mindspore/lite/test/st/scripts/nnie/run_converter_nnie.sh @@ -34,8 +34,9 @@ function Run_Converter() { model_location=`echo ${nnie_line_info}|awk -F ' ' '{print $1}'` model_info=`echo ${nnie_line_info}|awk -F ' ' '{print $2}'` model_name=${model_info%%;*} - echo 'export NNIE_CONFIG_PATH='${models_path}'/'${model_location}'/'${model_name}'.cfg' >> "${run_converter_log_file}" - export NNIE_CONFIG_PATH=${models_path}/${model_location}/${model_name}.cfg + cp ${models_path}/${model_location}/${model_name}.cfg ./ || exit 1 + echo 'export NNIE_CONFIG_PATH=./'${model_name}'.cfg' >> "${run_converter_log_file}" + export NNIE_CONFIG_PATH=./${model_name}.cfg echo ${model_name} >> "${run_converter_log_file}" echo './converter_lite --fmk=CAFFE --modelFile='${models_path}'/'${model_location}'/model/'${model_name}'.prototxt --weightFile='${models_path}'/'${model_location}'/model/'${model_name}'.caffemodel --configFile='${ms_config_file}' --outputFile='${ms_models_path}'/'${model_name}'' >> "${run_converter_log_file}" ./converter_lite --fmk=CAFFE --modelFile=${models_path}/${model_location}/model/${model_name}.prototxt --weightFile=${models_path}/${model_location}/model/${model_name}.caffemodel --configFile=${ms_config_file} --outputFile=${ms_models_path}/${model_name}