Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
weixin_41840029
PaddleOCR
提交
1417a3c2
P
PaddleOCR
项目概览
weixin_41840029
/
PaddleOCR
与 Fork 源项目一致
Fork自
PaddlePaddle / PaddleOCR
通知
1
Star
1
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
P
PaddleOCR
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
未验证
提交
1417a3c2
编写于
11月 11, 2021
作者:
M
MissPenguin
提交者:
GitHub
11月 11, 2021
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #4626 from MissPenguin/dygraph
[TIPC] rename cpp infer
上级
883fea10
c90752a3
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
44 addition
and
44 deletion
+44
-44
test_tipc/configs/ppocr_det_mobile/model_linux_gpu_normal_normal_infer_cpp_linux_gpu_cpu.txt
...model_linux_gpu_normal_normal_infer_cpp_linux_gpu_cpu.txt
+16
-0
test_tipc/prepare.sh
test_tipc/prepare.sh
+3
-19
test_tipc/test_inference_cpp.sh
test_tipc/test_inference_cpp.sh
+25
-25
未找到文件。
test_tipc/configs/ppocr_det_mobile/model_linux_gpu_normal_normal_infer_cpp_linux_gpu_cpu.txt
浏览文件 @
1417a3c2
===========================cpp_infer_params===========================
model_name:ocr_det
use_opencv:True
infer_model:./inference/ch_ppocr_mobile_v2.0_det_infer/
infer_quant:False
inference:./deploy/cpp_infer/build/ppocr det
--use_gpu:True|False
--enable_mkldnn:True|False
--cpu_threads:1|6
--rec_batch_num:1
--use_tensorrt:False|True
--precision:fp32|fp16
--det_model_dir:
--image_dir:./inference/ch_det_data_50/all-sum-510/
null:null
--benchmark:True
\ No newline at end of file
test_tipc/prepare.sh
浏览文件 @
1417a3c2
#!/bin/bash
source
test_tipc/common_func.sh
FILENAME
=
$1
# MODE be one of ['lite_train_lite_infer' 'lite_train_whole_infer' 'whole_train_whole_infer',
...
...
@@ -12,30 +14,12 @@ dataline=$(cat ${FILENAME})
# parser params
IFS
=
$'
\n
'
lines
=(
${
dataline
}
)
function
func_parser_key
(){
strs
=
$1
IFS
=
":"
array
=(
${
strs
}
)
tmp
=
${
array
[0]
}
echo
${
tmp
}
}
function
func_parser_value
(){
strs
=
$1
IFS
=
":"
array
=(
${
strs
}
)
tmp
=
${
array
[1]
}
echo
${
tmp
}
}
IFS
=
$'
\n
'
# The training params
model_name
=
$(
func_parser_value
"
${
lines
[1]
}
"
)
trainer_list
=
$(
func_parser_value
"
${
lines
[14]
}
"
)
# MODE be one of ['lite_train_lite_infer' 'lite_train_whole_infer' 'whole_train_whole_infer',
# 'whole_infer', 'klquant_whole_infer',
# 'cpp_infer', 'serving_infer']
MODE
=
$2
if
[
${
MODE
}
=
"lite_train_lite_infer"
]
;
then
# pretrain lite train data
...
...
test_tipc/test_inference_cpp.sh
浏览文件 @
1417a3c2
...
...
@@ -2,38 +2,38 @@
source
test_tipc/common_func.sh
FILENAME
=
$1
dataline
=
$(
awk
'NR==
52, NR==6
6{print}'
$FILENAME
)
dataline
=
$(
awk
'NR==
1, NR==1
6{print}'
$FILENAME
)
# parser params
IFS
=
$'
\n
'
lines
=(
${
dataline
}
)
# parser cpp inference model
use_opencv
=
$(
func_parser_value
"
${
lines
[1]
}
"
)
cpp_infer_model_dir_list
=
$(
func_parser_value
"
${
lines
[2]
}
"
)
cpp_infer_is_quant
=
$(
func_parser_value
"
${
lines
[3]
}
"
)
model_name
=
$(
func_parser_value
"
${
lines
[1]
}
"
)
use_opencv
=
$(
func_parser_value
"
${
lines
[2]
}
"
)
cpp_infer_model_dir_list
=
$(
func_parser_value
"
${
lines
[3]
}
"
)
cpp_infer_is_quant
=
$(
func_parser_value
"
${
lines
[4]
}
"
)
# parser cpp inference
inference_cmd
=
$(
func_parser_value
"
${
lines
[4]
}
"
)
cpp_use_gpu_key
=
$(
func_parser_key
"
${
lines
[5]
}
"
)
cpp_use_gpu_list
=
$(
func_parser_value
"
${
lines
[5]
}
"
)
cpp_use_mkldnn_key
=
$(
func_parser_key
"
${
lines
[6]
}
"
)
cpp_use_mkldnn_list
=
$(
func_parser_value
"
${
lines
[6]
}
"
)
cpp_cpu_threads_key
=
$(
func_parser_key
"
${
lines
[7]
}
"
)
cpp_cpu_threads_list
=
$(
func_parser_value
"
${
lines
[7]
}
"
)
cpp_batch_size_key
=
$(
func_parser_key
"
${
lines
[8]
}
"
)
cpp_batch_size_list
=
$(
func_parser_value
"
${
lines
[8]
}
"
)
cpp_use_trt_key
=
$(
func_parser_key
"
${
lines
[9]
}
"
)
cpp_use_trt_list
=
$(
func_parser_value
"
${
lines
[9]
}
"
)
cpp_precision_key
=
$(
func_parser_key
"
${
lines
[10]
}
"
)
cpp_precision_list
=
$(
func_parser_value
"
${
lines
[10]
}
"
)
cpp_infer_model_key
=
$(
func_parser_key
"
${
lines
[11]
}
"
)
cpp_image_dir_key
=
$(
func_parser_key
"
${
lines
[12]
}
"
)
cpp_infer_img_dir
=
$(
func_parser_value
"
${
lines
[12]
}
"
)
cpp_infer_key1
=
$(
func_parser_key
"
${
lines
[13]
}
"
)
cpp_infer_value1
=
$(
func_parser_value
"
${
lines
[13]
}
"
)
cpp_benchmark_key
=
$(
func_parser_key
"
${
lines
[14]
}
"
)
cpp_benchmark_value
=
$(
func_parser_value
"
${
lines
[14]
}
"
)
inference_cmd
=
$(
func_parser_value
"
${
lines
[5]
}
"
)
cpp_use_gpu_key
=
$(
func_parser_key
"
${
lines
[6]
}
"
)
cpp_use_gpu_list
=
$(
func_parser_value
"
${
lines
[6]
}
"
)
cpp_use_mkldnn_key
=
$(
func_parser_key
"
${
lines
[7]
}
"
)
cpp_use_mkldnn_list
=
$(
func_parser_value
"
${
lines
[7]
}
"
)
cpp_cpu_threads_key
=
$(
func_parser_key
"
${
lines
[8]
}
"
)
cpp_cpu_threads_list
=
$(
func_parser_value
"
${
lines
[8]
}
"
)
cpp_batch_size_key
=
$(
func_parser_key
"
${
lines
[9]
}
"
)
cpp_batch_size_list
=
$(
func_parser_value
"
${
lines
[9]
}
"
)
cpp_use_trt_key
=
$(
func_parser_key
"
${
lines
[10]
}
"
)
cpp_use_trt_list
=
$(
func_parser_value
"
${
lines
[10]
}
"
)
cpp_precision_key
=
$(
func_parser_key
"
${
lines
[11]
}
"
)
cpp_precision_list
=
$(
func_parser_value
"
${
lines
[11]
}
"
)
cpp_infer_model_key
=
$(
func_parser_key
"
${
lines
[12]
}
"
)
cpp_image_dir_key
=
$(
func_parser_key
"
${
lines
[13]
}
"
)
cpp_infer_img_dir
=
$(
func_parser_value
"
${
lines
[13]
}
"
)
cpp_infer_key1
=
$(
func_parser_key
"
${
lines
[14]
}
"
)
cpp_infer_value1
=
$(
func_parser_value
"
${
lines
[14]
}
"
)
cpp_benchmark_key
=
$(
func_parser_key
"
${
lines
[15]
}
"
)
cpp_benchmark_value
=
$(
func_parser_value
"
${
lines
[15]
}
"
)
LOG_PATH
=
"./test_tipc/output"
mkdir
-p
${
LOG_PATH
}
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录