-
-
Notifications
You must be signed in to change notification settings - Fork 392
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bug:输入图像没有参数可以限制其最大和最小尺寸 #265
Comments
这一点需要仔细debug一下,因为在 RapidOCR/python/rapidocr_onnxruntime/ch_ppocr_det/text_detect.py Lines 63 to 72 in 6bcabdd
原有逻辑是: RapidOCR/python/rapidocr_onnxruntime/main.py Lines 129 to 140 in 6bcabdd
两者关系如何,是否可以合并?需要具体探讨,来确定进一步修改方向。 |
如果考虑内存问题,例如1920x1080的RGB未压缩为6MB。 那么设置为 反而当设置为 |
设定最小尺寸和最大尺寸。如果超出,则直接返回,避免OOM。这一点是从CnOCR项目源码中看到的。
当前代码中并没有此类限制。
min_height
参数是用来决定图像进入检测前是否padding。min_side_len
和max_side_len
:用来缩放图像使用。最大边超出尺寸,则拉到min
或max
尺寸width_height_ratio
: 只计算了宽高比,同样用来决定文本检测是否padding的。只限制很宽的图像类型。缺少了限制很长的类型。The text was updated successfully, but these errors were encountered: