/ocr-clipboard

Extract text from a picture on the clipboard and paste the text into the clipboard. MSW

Primary LanguagePython

To install Tesseract OCR for Windows:

  1. Run the installer(find 2021) from UB Mannheim
  2. Configure your installation (choose installation path and language data to include)
  3. Add Tesseract OCR to your environment variables

To install and use Pytesseract on Windows:

  1. Simply run pip install pytesseract
  2. You will also need to install Pillow with pip install Pillow to use Pytesseract. Import it in your Python document like so from PIL import Image.
  3. You will need to add the following line in your code in order to be able to call pytesseract on your machine: pytesseract.pytesseract.tesseract_cmd = 'C:\\Program Files\\Tesseract-OCR\\tesseract.exe'
python -m venv env
source env/bin/activate
source env/Scripts/activate # for Windows
python -m pip install --upgrade pip
pip install -r requirements.txt
python ocr.py
python.exe ocr.py
 [INFO] Save a picture with text to the clipboard and recognize it with a hotkey:
     For Russian text <Alt + r>
     For English text <Alt + q>
 [INFO] Exit the program <Alt + z>

My thanks

Convenient to use in conjunction with a program that places a screen fragment on the clipboard

https://app.prntscr.com/ru/index.html