OCR-Translator / main.py
Sarath0x8f's picture
Upload 9 files
d69917c verified
raw
history blame
400 Bytes
from ObjCharRec import ocr_with_paddle
from textblob import TextBlob
def demo():
paths = ['Images/download.jpeg', 'Images/download.png', 'Images/hq720.jpg', 'Images/testocr.png']
l = []
for img in paths:
text = ocr_with_paddle(img)
txtblob = TextBlob(text)
l.append(str(txtblob.correct()))
return l
if __name__ == "__main__":
print(demo())