Spaces:
Running
Running
Update app_blocks.py
Browse files- app_blocks.py +1 -1
app_blocks.py
CHANGED
@@ -7,7 +7,7 @@ import gradio as gr
|
|
7 |
|
8 |
def tesseract_ocr(filepath: str, languages: List[str]=None):
|
9 |
image = Image.open(filepath)
|
10 |
-
return pytesseract.image_to_string(image=image, lang=', '.join(languages) if languages else None)
|
11 |
|
12 |
title = "Tesseract OCR"
|
13 |
description = "Gradio demo for Tesseract. Tesseract is an open source text recognition (OCR) Engine."
|
|
|
7 |
|
8 |
def tesseract_ocr(filepath: str, languages: List[str]=None):
|
9 |
image = Image.open(filepath)
|
10 |
+
return pytesseract.image_to_string(image=image, lang=', '.join(languages) if languages else None, config='--psm 7')
|
11 |
|
12 |
title = "Tesseract OCR"
|
13 |
description = "Gradio demo for Tesseract. Tesseract is an open source text recognition (OCR) Engine."
|