Skip to content

Instantly share code, notes, and snippets.

@edwhu
Created May 30, 2018 04:08
Show Gist options
  • Save edwhu/b66da5d213c3e5420e6c01646e2dcffa to your computer and use it in GitHub Desktop.
Save edwhu/b66da5d213c3e5420e6c01646e2dcffa to your computer and use it in GitHub Desktop.
ocr
import pyocr
import pyocr.builders
from PIL import Image
tools = pyocr.get_available_tools()[0]
text = tools.image_to_string(Image.open(image),
builder=pyocr.builders.DigitBuilder())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment