pytesseract努力识别字体编号和7个seg数字的干净的黑白图片(python) [英] pytesseract struggling to recognize clean black and white pictures with font numbers and 7 seg digits(python)

查看:272
本文介绍了pytesseract努力识别字体编号和7个seg数字的干净的黑白图片(python)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我一直在尝试让tesseract识别这张图片上的数字:

I've been trying to get tesseract to recognize the numbers on this image:

但是运行脚本时,输出为空,这意味着不能

but when running the script the output is empty meaning it can't

任何想法如何使其起作用?似乎应该没有不好的时间将图像转换为文本,并且同样发生了7段数字 并且尝试在此图像的带噪点的彩色版本上运行tesseract时,在此示例中,它实际上似乎确实运行良好:

Any idea how to make it work? it doesn't seem like it should have a bad time converting the image into text and the same happens 7 segment digital digits and when trying to run tesseract on a noisier colored version of this image this does actually seem to work well in this example:

关于如何使其工作的任何提示?

Any hints on how to get it to work?

感谢您的帮助

推荐答案

Tesseract对图像边框非常敏感,因此在过滤后的图像周围添加大约20个pix边框将解决此问题.

Tesseract is very sensitive to the image borders, so adding about 20 pix border around your filtered image will solve the issue.

关于tesseract问题中所述的7段字体- LSTM( tess 4. *)可能不是最好的方法,并且有很多不同的库可以更好地处理此问题.您可以尝试此tessdata for tesseract 3.4;

Regarding 7-segment font as stated in tesseract issue - LSTM (tess 4.*) might not be the best approach and there are different libraries which can handle this better. You can try this tessdata for tesseract 3.4;

这篇关于pytesseract努力识别字体编号和7个seg数字的干净的黑白图片(python)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆