Closed ledikari closed 4 years ago
Tesseract is an executable program, which you need to install separately (see https://github.com/tesseract-ocr/tesseract/wiki). You also need to make sure the installed directory is added to your PATH environment variable (usually happens automatically in Linux-based OS-s and there must be a checkbox in the Windows installer).
PyTesseract is a very thin Python wrapper which tries to locate that binary and run it. As you don't have the binary installed, PyTesseract complains.
Once you're at it, note that the recent Tesseract versions are only bundled with a "new", LSTM-based OCR model (maybe it only applies to Windows, though, I don't remember 100%). The "new" model tends to work worse than the legacy one for PassportEye purposes, and thus PassportEye tries to use the legacy model by default. If your installation won't have that model, you may observe another exception when trying to use the function.
You may overcome this error by passing a particular command-line option, but, better, make sure you get the "complete" eng.tessdata file at installation time. If it won't come with the installer you will need to download it manually from here: https://github.com/tesseract-ocr/tessdata and put into the tessdata directory of your tesseract installation.
installed by pip but it did not work.
do note that pytessearact and pillow is already installed.