Skip to content

Instantly share code, notes, and snippets.

@nidhinp
Created August 9, 2019 10:20
Show Gist options
  • Save nidhinp/7c2349fc3199dcfda5dbb7f259345edd to your computer and use it in GitHub Desktop.
Save nidhinp/7c2349fc3199dcfda5dbb7f259345edd to your computer and use it in GitHub Desktop.
make bigger image
def make_bigger_image():
""" To get a better result from OCR images should be large.
Function enlarges the image
"""
bolder_image = Image.open("bold_image.gif")
big = bolder_image.resize((1000, 500), Image.NEAREST)
big.save("bigger_image.tif")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment