Replies: 1 comment 1 reply
-
Hello, your method of calling seems correct. Here is an example code: from paddleocr import PaddleOCR
ocr = PaddleOCR(
lang="fr", # Specify French recognition model with the lang parameter
text_detection_model_name="PP-OCRv5_mobile_det",
use_doc_orientation_classify=False, # Disable document orientation classification model
use_doc_unwarping=False, # Disable text image unwarping model
use_textline_orientation=False, # Disable text line orientation classification model
)
result = ocr.predict("https://paddle-model-ecology.bj.bcebos.com/paddlex/imgs/demo_image/general_ocr_french01.png")
for res in result:
res.print()
res.save_to_img("output")
res.save_to_json("output") |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
If the model name is specified, the lang param is not effective.
I need to set the detection model to the mobile version and choose the recognition model based on the lang. Is there a way?
Beta Was this translation helpful? Give feedback.
All reactions