PyTesseract image_to_data错误:临时文件

时间:2018-04-15 08:28:42

标签: python ocr python-tesseract

我想提高pytesseract的准确性,我看到Here一种方法是可视化pytesseract的预处理输出,以确保问题不是坏分割。所以,我试过

pytesseract.image_to_data(in_img, lang='eng')

但它给了我这个错误same as the problem in this github issue

Traceback (most recent call last):
  File "main.py", line 50, in <module>
    text = pytesseract.image_to_data(in_img)
  File "/usr/local/lib/python2.7/dist-packages/pytesseract/pytesseract.py", line 232, in image_to_data
    return run_and_get_output(image, 'tsv', lang, config, nice)
  File "/usr/local/lib/python2.7/dist-packages/pytesseract/pytesseract.py", line 142, in run_and_get_output
    with open(filename, 'rb') as output_file:
IOError: [Errno 2] No such file or directory: '/tmp/tess_wRF6OP_out.tsv'

我该如何解决这个问题?

0 个答案:

没有答案
相关问题