OSError: [Errno 2] No such file or directory using pytesser

前端 未结 7 2046
鱼传尺愫
鱼传尺愫 2020-12-16 05:50

This is my problem, I want to use pytesser to get a picture\'s contents. My operating system is Mac OS 10.11, and I have already installed PIL, pytesser, tesseract-ocr engin

7条回答
  •  不知归路
    2020-12-16 05:59

    I had the same problem, but i managed to convert image to string. using apt-get should do the trick:

    sudo apt-get install tesseract-ocr
    

    and if you can't use it in a python script just do this:

    from os import system
    
    system("tesseract -l eng /image.png text.txt")
    

提交回复
热议问题