尝试使用 easyocr 准备图像,但我发现它需要更多时间,或者有时内核已经死掉并且输出为空

发布于 2025-01-09 17:54:30 字数 574 浏览 0 评论 0原文

我已将 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 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文