未验证 提交 d8c0dbda 编写于 作者: Z zhoujun 提交者: GitHub

Add custom detection and recognition model usage instructions in re (#8930)

* Add custom detection and recognition model usage instructions in re

* update

* Add custom detection and recognition model usage instructions in re
上级 3629d5a3
...@@ -186,6 +186,10 @@ python3 ./tools/infer_kie_token_ser_re.py \ ...@@ -186,6 +186,10 @@ python3 ./tools/infer_kie_token_ser_re.py \
The visual result images and the predicted text file will be saved in the `Global.save_res_path` directory. The visual result images and the predicted text file will be saved in the `Global.save_res_path` directory.
If you want to use a custom ocr model, you can set it through the following fields
- `Global.kie_det_model_dir`: the detection inference model path
- `Global.kie_rec_model_dir`: the recognition inference model path
If you want to load the text detection and recognition results collected before, you can use the following command to predict. If you want to load the text detection and recognition results collected before, you can use the following command to predict.
...@@ -257,6 +261,9 @@ python3 kie/predict_kie_token_ser_re.py \ ...@@ -257,6 +261,9 @@ python3 kie/predict_kie_token_ser_re.py \
The visual results and text file will be saved in directory `output`. The visual results and text file will be saved in directory `output`.
If you want to use a custom ocr model, you can set it through the following fields
- `--det_model_dir`: the detection inference model path
- `--rec_model_dir`: the recognition inference model path
### 4.3 More ### 4.3 More
......
...@@ -170,6 +170,10 @@ python3 ./tools/infer_kie_token_ser_re.py \ ...@@ -170,6 +170,10 @@ python3 ./tools/infer_kie_token_ser_re.py \
`Global.save_res_path`目录中会保存可视化的结果图像以及预测的文本文件。 `Global.save_res_path`目录中会保存可视化的结果图像以及预测的文本文件。
如果想使用自定义OCR模型,可通过如下字段进行设置
- `Global.kie_det_model_dir`: 设置检测inference模型地址
- `Global.kie_rec_model_dir`: 设置识别inference模型地址
如果希望加载标注好的文本检测与识别结果,仅预测可以使用下面的命令进行预测。 如果希望加载标注好的文本检测与识别结果,仅预测可以使用下面的命令进行预测。
...@@ -239,6 +243,9 @@ python3 kie/predict_kie_token_ser_re.py \ ...@@ -239,6 +243,9 @@ python3 kie/predict_kie_token_ser_re.py \
可视化结果保存在`output`目录下。 可视化结果保存在`output`目录下。
如果想使用自定义OCR模型,可通过如下字段进行设置
- `--det_model_dir`: 设置检测inference模型地址
- `--rec_model_dir`: 设置识别inference模型地址
### 4.3 更多 ### 4.3 更多
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册