Spaces:
Running
Running
kneelesh48
commited on
Commit
•
5484471
1
Parent(s):
7e333d1
Add application file
Browse files- app_blocks.py +1 -1
app_blocks.py
CHANGED
@@ -2,7 +2,7 @@ import gradio as gr
|
|
2 |
import pytesseract
|
3 |
from PIL import Image
|
4 |
|
5 |
-
def tesseract_ocr(filepath, languages):
|
6 |
image = Image.open(filepath)
|
7 |
return pytesseract.image_to_string(image=image, lang=', '.join(languages) if languages else None)
|
8 |
|
|
|
2 |
import pytesseract
|
3 |
from PIL import Image
|
4 |
|
5 |
+
def tesseract_ocr(filepath, languages=None):
|
6 |
image = Image.open(filepath)
|
7 |
return pytesseract.image_to_string(image=image, lang=', '.join(languages) if languages else None)
|
8 |
|