Created
September 13, 2024 23:26
-
-
Save AdelMmdi/e6536298b29a6bad8b73aa4837a2f365 to your computer and use it in GitHub Desktop.
convert image to text words simple translate manual is better
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import pytesseract as tess | |
| from PIL import Image | |
| import glob | |
| path = r"C:\Users\AAAdel\Desktop\Movie" | |
| tess.pytesseract.tesseract_cmd= r"C:\Program Files\Tesseract-OCR\tesseract.exe" | |
| for pic in glob.glob(path+"\\*.jpg"): | |
| img = Image.open(pic) | |
| text= tess.image_to_string(img) | |
| print(text) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment