Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
magicwindyyd
mindspore
提交
340f10c3
M
mindspore
项目概览
magicwindyyd
/
mindspore
与 Fork 源项目一致
Fork自
MindSpore / mindspore
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
M
mindspore
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
提交
340f10c3
编写于
8月 21, 2020
作者:
M
mindspore-ci-bot
提交者:
Gitee
8月 21, 2020
浏览文件
操作
浏览文件
下载
差异文件
!4920 Add fp16 ci
Merge pull request !4920 from mengchunyang/master
上级
b7d9d5e0
2b923e56
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
56 addition
and
1 deletion
+56
-1
mindspore/lite/test/models_fp16.cfg
mindspore/lite/test/models_fp16.cfg
+7
-0
mindspore/lite/test/run_benchmark_nets.sh
mindspore/lite/test/run_benchmark_nets.sh
+49
-1
未找到文件。
mindspore/lite/test/models_fp16.cfg
0 → 100644
浏览文件 @
340f10c3
detect-deeper-halfdeeper-mbv1-shortcut-400-400_nopostprocess_simplified.fp16
model_emotions_0727_nosoftmax.fp16
mtk_isface.fp16
mtk_landmark.fp16
mtk_pose_tuku.fp16
mtk_age_gender.fp16
mtk_model_face_dress.fp16
mindspore/lite/test/run_benchmark_nets.sh
浏览文件 @
340f10c3
...
@@ -203,7 +203,7 @@ function Run_arm64() {
...
@@ -203,7 +203,7 @@ function Run_arm64() {
#sleep 1
#sleep 1
done
<
${
models_caffe_config
}
done
<
${
models_caffe_config
}
# Run onnx converted models:
# Run onnx converted models:
while
read
line
;
do
while
read
line
;
do
model_name
=
${
line
}
model_name
=
${
line
}
if
[[
$model_name
==
\#
*
]]
;
then
if
[[
$model_name
==
\#
*
]]
;
then
...
@@ -238,6 +238,42 @@ function Run_arm64() {
...
@@ -238,6 +238,42 @@ function Run_arm64() {
fi
fi
#sleep 1
#sleep 1
done
<
${
models_onnx_config
}
done
<
${
models_onnx_config
}
# Run fp16 converted models:
while
read
line
;
do
model_name
=
${
line
}
if
[[
$model_name
==
\#
*
]]
;
then
continue
fi
echo
${
model_name
}
echo
'cd /data/local/tmp/benchmark_test'
>
adb_run_cmd.txt
echo
'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/data/local/tmp/benchmark_test;./benchmark --modelPath='
${
model_name
}
'.ms --inDataPath=/data/local/tmp/input_output/input/'
${
model_name
}
'.ms.bin --calibDataPath=/data/local/tmp/input_output/output/'
${
model_name
}
'.ms.out --warmUpLoopCount=1 --loopCount=1 --fp16Priority=true --accuracyThreshold=5'
echo
'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/data/local/tmp/benchmark_test;./benchmark --modelPath='
${
model_name
}
'.ms --inDataPath=/data/local/tmp/input_output/input/'
${
model_name
}
'.ms.bin --calibDataPath=/data/local/tmp/input_output/output/'
${
model_name
}
'.ms.out --warmUpLoopCount=1 --loopCount=1 --fp16Priority=true --accuracyThreshold=5'
>>
adb_run_cmd.txt
adb
-s
${
device_id
}
shell < adb_run_cmd.txt
if
[
$?
=
0
]
;
then
run_result
=
'Run_arm64: '
${
model_name
}
' pass'
echo
${
run_result
}
>>
${
run_benchmark_result_file
}
else
run_result
=
'Run_arm64:'
${
model_name
}
' fail <<===========================this is the failed case'
echo
${
run_result
}
>>
${
run_benchmark_result_file
}
return
1
fi
# run benchmark test without clib data
echo
${
model_name
}
echo
'cd /data/local/tmp/benchmark_test'
>
adb_run_cmd.txt
echo
'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/data/local/tmp/benchmark_test;./benchmark --modelPath='
${
model_name
}
'.ms --warmUpLoopCount=1 --loopCount=2 --fp16Priority=true --accuracyThreshold=5'
echo
'export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/data/local/tmp/benchmark_test;./benchmark --modelPath='
${
model_name
}
'.ms --warmUpLoopCount=1 --loopCount=2 --fp16Priority=true --accuracyThreshold=5'
>>
adb_run_cmd.txt
adb
-s
${
device_id
}
shell < adb_run_cmd.txt
if
[
$?
=
0
]
;
then
run_result
=
'Run_arm64: '
${
model_name
}
' pass'
echo
${
run_result
}
>>
${
run_benchmark_result_file
}
else
run_result
=
'Run_arm64:'
${
model_name
}
' fail <<===========================this is the failed case'
echo
${
run_result
}
>>
${
run_benchmark_result_file
}
return
1
fi
#sleep 1
done
<
${
models_fp16_config
}
}
}
# Print start msg before run testcase
# Print start msg before run testcase
...
@@ -311,12 +347,23 @@ models_caffe_config=${basepath}/models_caffe.cfg
...
@@ -311,12 +347,23 @@ models_caffe_config=${basepath}/models_caffe.cfg
models_tflite_awaretraining_config
=
${
basepath
}
/models_tflite_awaretraining.cfg
models_tflite_awaretraining_config
=
${
basepath
}
/models_tflite_awaretraining.cfg
models_tflite_posttraining_config
=
${
basepath
}
/models_tflite_posttraining.cfg
models_tflite_posttraining_config
=
${
basepath
}
/models_tflite_posttraining.cfg
models_onnx_config
=
${
basepath
}
/models_onnx.cfg
models_onnx_config
=
${
basepath
}
/models_onnx.cfg
models_fp16_config
=
${
basepath
}
/models_fp16.cfg
models_mindspore_config
=
${
basepath
}
/models_mindspore.cfg
models_mindspore_config
=
${
basepath
}
/models_mindspore.cfg
rm
-rf
${
basepath
}
/ms_models
rm
-rf
${
basepath
}
/ms_models
mkdir
-p
${
basepath
}
/ms_models
mkdir
-p
${
basepath
}
/ms_models
ms_models_path
=
${
basepath
}
/ms_models
ms_models_path
=
${
basepath
}
/ms_models
# Copy fp16 ms models:
while
read
line
;
do
model_name
=
${
line
}
if
[[
$model_name
==
\#
*
]]
;
then
continue
fi
echo
'cp '
${
models_path
}
'/'
${
model_name
}
'.ms'
${
ms_models_path
}
'/'
${
model_name
}
'.ms'
cp
$models_path
/
${
model_name
}
.ms
${
ms_models_path
}
/
${
model_name
}
.ms
done
<
${
models_fp16_config
}
# Convert tflite models:
# Convert tflite models:
while
read
line
;
do
while
read
line
;
do
model_name
=
${
line
}
model_name
=
${
line
}
...
@@ -393,6 +440,7 @@ mkdir -p ${basepath}/benchmark_test
...
@@ -393,6 +440,7 @@ mkdir -p ${basepath}/benchmark_test
benchmark_test_path
=
${
basepath
}
/benchmark_test
benchmark_test_path
=
${
basepath
}
/benchmark_test
cd
${
benchmark_test_path
}
||
exit
1
cd
${
benchmark_test_path
}
||
exit
1
cp
-a
${
arm_path
}
/mindspore-lite-
${
version
}
-runtime-arm64-
${
process_unit
}
/lib/libmindspore-lite.so
${
benchmark_test_path
}
/libmindspore-lite.so
||
exit
1
cp
-a
${
arm_path
}
/mindspore-lite-
${
version
}
-runtime-arm64-
${
process_unit
}
/lib/libmindspore-lite.so
${
benchmark_test_path
}
/libmindspore-lite.so
||
exit
1
cp
-a
${
arm_path
}
/mindspore-lite-
${
version
}
-runtime-arm64-
${
process_unit
}
/lib/liboptimize.so
${
benchmark_test_path
}
/liboptimize.so
||
exit
1
cp
-a
${
arm_path
}
/mindspore-lite-
${
version
}
-runtime-arm64-
${
process_unit
}
/benchmark/benchmark
${
benchmark_test_path
}
/benchmark
||
exit
1
cp
-a
${
arm_path
}
/mindspore-lite-
${
version
}
-runtime-arm64-
${
process_unit
}
/benchmark/benchmark
${
benchmark_test_path
}
/benchmark
||
exit
1
# Copy the MindSpore models:
# Copy the MindSpore models:
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录