From df6120a093843d1f528c61cbfa129ae2c6e88a80 Mon Sep 17 00:00:00 2001 From: lubin10 Date: Fri, 29 Apr 2022 03:48:06 +0000 Subject: [PATCH] add image exmaple --- doc/doc_ch/algorithm_rec_rare.md | 10 +++++++++- doc/doc_ch/algorithm_rec_rosetta.md | 10 +++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) diff --git a/doc/doc_ch/algorithm_rec_rare.md b/doc/doc_ch/algorithm_rec_rare.md index e5b5e54c..3d36da7c 100644 --- a/doc/doc_ch/algorithm_rec_rare.md +++ b/doc/doc_ch/algorithm_rec_rare.md @@ -77,8 +77,16 @@ python3 tools/export_model.py -c configs/rec/rec_r34_vd_tps_bilstm_att.yml -o Gl RARE文本识别模型推理,可以执行如下命令: ```shell -python3 tools/infer/predict_rec.py --image_dir="doc/imgs_words/en/word_1.png" --rec_model_dir="./inference/rec_rare/" +python3 tools/infer/predict_rec.py --image_dir="doc/imgs_words/en/word_1.png" --rec_model_dir="./inference/rec_rare/" --rec_image_shape="3, 32, 100" --rec_char_dict_path="./ppocr/utils/ic15_dict.txt" ``` +推理结果如下所示: + +![](../../doc/imgs_words/en/word_1.png) + +``` +Predicts of doc/imgs_words/en/word_1.png:('joint ', 0.9999969601631165) +``` + ### 4.2 C++推理 diff --git a/doc/doc_ch/algorithm_rec_rosetta.md b/doc/doc_ch/algorithm_rec_rosetta.md index 097a142b..c1784cac 100644 --- a/doc/doc_ch/algorithm_rec_rosetta.md +++ b/doc/doc_ch/algorithm_rec_rosetta.md @@ -79,7 +79,15 @@ python3 tools/export_model.py -c configs/rec/rec_r34_vd_none_none_ctc.yml -o Glo Rosetta文本识别模型推理,可以执行如下命令: ```shell -python3 tools/infer/predict_rec.py --image_dir="doc/imgs_words/en/word_1.png" --rec_model_dir="./inference/rec_rosetta/" +python3 tools/infer/predict_rec.py --image_dir="doc/imgs_words/en/word_1.png" --rec_model_dir="./inference/rec_rosetta/" --rec_image_shape="3, 32, 100" --rec_char_dict_path="./ppocr/utils/ic15_dict.txt" +``` + +推理结果如下所示: + +![](../../doc/imgs_words/en/word_1.png) + +``` +Predicts of doc/imgs_words/en/word_1.png:('joint', 0.9999982714653015) ``` -- GitLab