Neurolingua commited on
Commit
955c3d0
·
verified ·
1 Parent(s): d622f91

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -482,12 +482,12 @@ def eval():
482
  if question_path.endswith('.pdf'):
483
  question_text = extract_text_from_pdf(question_path)
484
  else:
485
- question_text = extract_text_from_image(question_path)
486
 
487
  if answer_path.endswith('.pdf'):
488
  answer_text = extract_text_from_pdf(answer_path)
489
  else:
490
- answer_text = extract_text_from_image(answer_path)
491
 
492
  elif input_type == 'text':
493
  question_text = request.form['question_text']
 
482
  if question_path.endswith('.pdf'):
483
  question_text = extract_text_from_pdf(question_path)
484
  else:
485
+ question_text = perform_ocr(question_path)
486
 
487
  if answer_path.endswith('.pdf'):
488
  answer_text = extract_text_from_pdf(answer_path)
489
  else:
490
+ answer_text = perform_ocr(answer_path)
491
 
492
  elif input_type == 'text':
493
  question_text = request.form['question_text']