IotaCluster commited on
Commit
bee4c7a
·
verified ·
1 Parent(s): c6c0682

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -13,7 +13,8 @@ def ocr_image(image, language):
13
  return "Please upload an image."
14
  lang = '+'.join(language)
15
  text = pytesseract.image_to_string(image, lang=lang)
16
- return text.strip()
 
17
 
18
  # Translation function
19
  def translate_text(text, direction):
 
13
  return "Please upload an image."
14
  lang = '+'.join(language)
15
  text = pytesseract.image_to_string(image, lang=lang)
16
+ return f"OCR Text of the image:\n\n{text.strip()}"
17
+
18
 
19
  # Translation function
20
  def translate_text(text, direction):