Mar 2020 / Coding Python Tesseract 4.0 OCR: Recognize only Numbers / Digits and exclude all other Characters The OCR software Tesseract 4.0 doesn't allow you to whitelist a list of characters. I will give 3 solution to extract only numbers out of an image with the Tesseract Python wrapper called "PyTesseract".