TheGreenBird commited on
Commit
e8ed84b
·
verified ·
1 Parent(s): 0d680c5

Update app_blocks.py

Browse files
Files changed (1) hide show
  1. 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."