尝试使用 easyocr 准备图像,但我发现它需要更多时间,或者有时内核已经死掉并且输出为空
我已将 pdf 转换为图像并转换为数组。
然而,在此过程中花费了太多时间或几乎内核死亡,并最终得到空的o/p。
如何处理这个问题。请建议。
代码:
images = convert_from_path('abc.pdf',poppler_path= r'C:\Program Files (x86)\poppler-0.68.0\bin')
final=[]
for i in range(len(images)): bounds=reader.readtext(np.array(images[i]),min_size=0,slope_ths=0.2,ycenter_ths=0.7,height_ths=0.6,width_ths=0.8,decoder='beamsearch')
final.append(bounds)
上面代码的o/p为空:[]
我尝试过的:
在不使用循环的情况下,如果我只给出 image[0]
或 image[1]
等,那么我会看到所需的o/p结果。
I have converted a pdf into a image and converting into arrays.
However its taking too much time or almost kernel dead during this process and at the end getting empty o/p.
How to handle this issue. kindly suggest.
Code:
images = convert_from_path('abc.pdf',poppler_path= r'C:\Program Files (x86)\poppler-0.68.0\bin')
final=[]
for i in range(len(images)): bounds=reader.readtext(np.array(images[i]),min_size=0,slope_ths=0.2,ycenter_ths=0.7,height_ths=0.6,width_ths=0.8,decoder='beamsearch')
final.append(bounds)
Here the o/p of the above code is empty : []
What I've tried:
Without using a loop , if I just give image[0]
or image[1]
etc, then I see the desired o/p result.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论