Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
weixin_41840029
PaddleOCR
提交
8fda0c4f
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看板
提交
8fda0c4f
编写于
8月 13, 2021
作者:
T
tink2123
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
replace rec dataset
上级
0b3aa575
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
55 addition
and
2 deletion
+55
-2
tests/ocr_det_params.txt
tests/ocr_det_params.txt
+10
-1
tests/ocr_rec_params.txt
tests/ocr_rec_params.txt
+1
-1
tests/prepare.sh
tests/prepare.sh
+10
-0
tests/test.sh
tests/test.sh
+34
-0
未找到文件。
tests/ocr_det_params.txt
浏览文件 @
8fda0c4f
...
...
@@ -49,4 +49,13 @@ inference:tools/infer/predict_det.py
--save_log_path:null
--benchmark:True
null:null
===========================deploy_params===========================
trans_model:-m paddle_serving_client.convert
--dirname:./inference/ch_ppocr_mobile_v2.0_det_infer/
--model_filename:inference.pdmodel
--params_filename:inference.pdiparams
--serving_server:./deploy/pdserving/ppocr_det_mobile_2.0_serving/
--serving_client:./deploy/pdserving/ppocr_det_mobile_2.0_client/
serving_dir:./deploy/pdserving
web_service:web_service_det.py &>log.txt &
pipline:pipeline_http_client.py --image_dir=../../doc/imgs
tests/ocr_rec_params.txt
浏览文件 @
8fda0c4f
...
...
@@ -9,7 +9,7 @@ Global.save_model_dir:./output/
Train.loader.batch_size_per_card:lite_train_infer=128|whole_train_infer=128
Global.pretrained_model:null
train_model_name:latest
train_infer_img_dir:./train_data/ic15_data/t
rain
train_infer_img_dir:./train_data/ic15_data/t
est
null:null
##
trainer:norm_train|pact_train
...
...
tests/prepare.sh
浏览文件 @
8fda0c4f
...
...
@@ -74,3 +74,13 @@ else
fi
fi
# prepare serving env
python_name
=
$(
func_parser_value
"
${
lines
[2]
}
"
)
${
python_name
}
-m
pip
install install
paddle-serving-server-gpu
==
0.6.1.post101
${
python_name
}
-m
pip
install
paddle_serving_client
==
0.6.1
${
python_name
}
-m
pip
install
paddle-serving-app
==
0.6.1
wget
-nc
-P
./inference https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_det_infer.tar
wget
-nc
-P
./inference https://paddleocr.bj.bcebos.com/dygraph_v2.0/ch/ch_ppocr_mobile_v2.0_rec_infer.tar
cd
./inference
&&
tar
xf ch_ppocr_mobile_v2.0_det_infer.tar
&&
tar
xf ch_ppocr_mobile_v2.0_rec_infer.tar
tests/test.sh
浏览文件 @
8fda0c4f
...
...
@@ -144,6 +144,22 @@ benchmark_key=$(func_parser_key "${lines[49]}")
benchmark_value
=
$(
func_parser_value
"
${
lines
[49]
}
"
)
infer_key1
=
$(
func_parser_key
"
${
lines
[50]
}
"
)
infer_value1
=
$(
func_parser_value
"
${
lines
[50]
}
"
)
# parser serving
trans_model_py
=
$(
func_parser_value
"
${
lines
[52]
}
"
)
infer_model_dir_key
=
$(
func_parser_key
"
${
lines
[53]
}
"
)
infer_model_dir_value
=
$(
func_parser_value
"
${
lines
[53]
}
"
)
model_filename_key
=
$(
func_parser_key
"
${
lines
[54]
}
"
)
model_filename_value
=
$(
func_parser_value
"
${
lines
[54]
}
"
)
params_filename_key
=
$(
func_parser_key
"
${
lines
[55]
}
"
)
params_filename_value
=
$(
func_parser_value
"
${
lines
[55]
}
"
)
serving_server_key
=
$(
func_parser_key
"
${
lines
[56]
}
"
)
serving_server_value
=
$(
func_parser_value
"
${
lines
[56]
}
"
)
serving_client_key
=
$(
func_parser_key
"
${
lines
[57]
}
"
)
serving_client_value
=
$(
func_parser_value
"
${
lines
[57]
}
"
)
serving_dir_value
=
$(
func_parser_value
"
${
lines
[58]
}
"
)
web_service_py
=
$(
func_parser_value
"
${
lines
[59]
}
"
)
pipline_py
=
$(
func_parser_value
"
${
lines
[60]
}
"
)
LOG_PATH
=
"./tests/output"
mkdir
-p
${
LOG_PATH
}
...
...
@@ -250,6 +266,23 @@ if [ ${MODE} = "infer" ]; then
is_quant
=
${
infer_quant_flag
[Count]
}
func_inference
"
${
python
}
"
"
${
inference_py
}
"
"
${
save_infer_dir
}
"
"
${
LOG_PATH
}
"
"
${
infer_img_dir
}
"
${
is_quant
}
Count
=
$((
$Count
+
1
))
#run serving
set_dirname
=
$(
func_set_params
"
${
infer_model_dir_key
}
"
"
${
infer_model_dir_value
}
"
)
set_model_filename
=
$(
func_set_params
"
${
model_filename_key
}
"
"
${
model_filename_value
}
"
)
set_params_filename
=
$(
func_set_params
"
${
params_filename_key
}
"
"
${
params_filename_value
}
"
)
set_serving_server
=
$(
func_set_params
"
${
serving_server_key
}
"
"
${
serving_server_value
}
"
)
set_serving_client
=
$(
func_set_params
"
${
serving_client_key
}
"
"
${
serving_client_value
}
"
)
trans_model_cmd
=
"
${
python
}
${
trans_model_py
}
${
set_dirname
}
${
set_model_filename
}
${
set_params_filename
}
${
set_serving_server
}
${
set_serving_client
}
"
eval
$trans_model_cmd
cd
${
serving_dir_value
}
echo
$PWD
web_service_cmd
=
"
${
python
}
${
web_service_py
}
"
echo
$web_service_cmd
eval
$web_service_cmd
pipline_cmd
=
"
${
python
}
${
pipline_py
}
"
echo
$pipline_cmd
eval
$pipline_cmd
done
else
...
...
@@ -363,3 +396,4 @@ else
done
# done with: for autocast in ${autocast_list[*]}; do
done
# done with: for gpu in ${gpu_list[*]}; do
fi
# end if [ ${MODE} = "infer" ]; then
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录