Tesseract is an open-source Optical Character Recognition (OCR) engine that can recognize text in images. To install Tesseract and its associated language data (tessdata) on your system, follow the instructions below.
pip install pytesseract
Repo: https://github.com/tesseract-ocr/tesseract
-
Download Tesseract: The latest installers for Tesseract OCR can be found on the GitHub releases page. Download the appropriate version for your system (32-bit or 64-bit).
-
Install Tesseract: Run the downloaded installer. We recommend using the default settings for installation.
-
Set the Tesseract path in your Environment Variables:
- Right-click on 'This PC' (or 'My Computer') and choose 'Properties'.
- Click on 'Advanced system settings'.
- Click on 'Environment Variables...'.
- In the System Variables section, find the 'Path' variable, select it and click on 'Edit'.
- In the 'Edit Environment Variable' window, click 'New' and add the path where the Tesseract-OCR has been installed (for example,
C:\Program Files\Tesseract-OCR
).
-
Verify Installation: Open a new command prompt and run
tesseract -v
. If Tesseract has been installed correctly, the version number of the Tesseract engine will be displayed.
- Install Tesseract: You can install Tesseract directly from the Ubuntu repositories. Open a terminal and run the following command:
sudo apt install tesseract-ocr
- language pack: https://github.com/tesseract-ocr/tessdata
- Download tessdata and replace it in your tessearct-ocr dir.