python pytesseractpytesseractTesseractNotFoundError tesseract is not installed or its not in your PATH See README file for more information
This error message indicates that the Tesseract OCR engine is not installed on your computer or it cannot be found in your system's PATH environment variable.
To resolve this issue, you need to install Tesseract OCR engine on your computer and add it to the system's PATH environment variable.
Here are the steps to install Tesseract OCR engine:
-
Download and install Tesseract OCR engine from the official website: https://github.com/UB-Mannheim/tesseract/wiki
-
Once installed, add the Tesseract installation directory to your PATH environment variable.
-
On Windows:
- Open the Control Panel and go to System > Advanced system settings > Environment Variables.
- In the System Variables section, scroll down and find the "Path" variable.
- Click on "Edit" and add the path to the Tesseract installation directory (e.g. C:\Program Files\Tesseract-OCR) to the list of paths.
- Click "OK" to save the changes.
-
On Mac or Linux:
- Open the Terminal and enter the following command:
export PATH="/usr/local/bin:$PATH" - Replace "/usr/local/bin" with the path to the Tesseract installation directory on your system.
- Open the Terminal and enter the following command:
-
-
Verify that Tesseract is installed and added to the PATH by running the following command in the Terminal or Command Prompt:
tesseract --version
If Tesseract is installed and added to the PATH correctly, you should see the version number of Tesseract displayed in the output. Once Tesseract is installed and configured, you should be able to use it with Python's pytesseract module without any issues.
原文地址: http://www.cveoy.top/t/topic/5RY 著作权归作者所有。请勿转载和采集!