mirror of
https://github.com/PaddlePaddle/FastDeploy.git
synced 2025-10-06 00:57:33 +08:00
[Bug Fix] Modify TRT dynamic input shape for PP-OCRv2 python demo. (#775)
* Imporve OCR Readme * Improve OCR Readme * Improve OCR Readme * Improve OCR Readme * Improve OCR Readme * Add Initialize function to PP-OCR * Add Initialize function to PP-OCR * Add Initialize function to PP-OCR * Make all the model links come from PaddleOCR * Improve OCR readme * Improve OCR readme * Improve OCR readme * Improve OCR readme * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add Readme for vision results * Add check for label file in postprocess of Rec model * Add check for label file in postprocess of Rec model * Add check for label file in postprocess of Rec model * Add check for label file in postprocess of Rec model * Add check for label file in postprocess of Rec model * Add check for label file in postprocess of Rec model * Add comments to create API docs * Improve OCR comments * Rename OCR and add comments * Make sure previous python example works * Make sure previous python example works * Fix Rec model bug * Fix Rec model bug * Fix rec model bug * Add SetTrtMaxBatchSize function for TensorRT * Add SetTrtMaxBatchSize Pybind * Add set_trt_max_batch_size python function * Set TRT dynamic shape in PPOCR examples * Set TRT dynamic shape in PPOCR examples * Set TRT dynamic shape in PPOCR examples * Fix PPOCRv2 python example * Fix PPOCR dynamic input shape bug * Remove useless code * Fix PPOCR bug * Remove useless comments in PaddleSeg example * Fix quantize docs readme * Fix PP-OCRv2 readme * Modify dynamic shape in PP-OCRv2 example * Modify TRT dynamic shape for PP-OCRv2 Co-authored-by: Jason <jiangjiajun@baidu.com>
This commit is contained in:
@@ -119,7 +119,7 @@ det_model = fd.vision.ocr.DBDetector(
|
||||
|
||||
cls_option = runtime_option
|
||||
cls_option.set_trt_input_shape("x", [1, 3, 48, 10], [10, 3, 48, 320],
|
||||
[64, 3, 48, 1024])
|
||||
[32, 3, 48, 1024])
|
||||
# 用户可以把TRT引擎文件保存至本地
|
||||
# cls_option.set_trt_cache_file(args.cls_model + "/cls_trt_cache.trt")
|
||||
cls_model = fd.vision.ocr.Classifier(
|
||||
@@ -127,7 +127,7 @@ cls_model = fd.vision.ocr.Classifier(
|
||||
|
||||
rec_option = runtime_option
|
||||
rec_option.set_trt_input_shape("x", [1, 3, 32, 10], [10, 3, 32, 320],
|
||||
[64, 3, 32, 2304])
|
||||
[32, 3, 32, 2304])
|
||||
# 用户可以把TRT引擎文件保存至本地
|
||||
# rec_option.set_trt_cache_file(args.rec_model + "/rec_trt_cache.trt")
|
||||
rec_model = fd.vision.ocr.Recognizer(
|
||||
|
Reference in New Issue
Block a user