SalML commited on
Commit
bd31499
1 Parent(s): 9e0401e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -434,10 +434,10 @@ class TableExtractionPipeline():
434
  '''
435
  image = Image.open(image_path).convert("RGB")
436
  model, probas, bboxes_scaled = table_detector(image, THRESHOLD_PROBA=TD_THRESHOLD)
437
- st.write(bboxes_scaled)
438
- #if bboxes_scaled.nelement() == 0:
439
- #st.write('No table found in the pdf-page image')
440
- #return ''
441
 
442
  # try:
443
  # st.write('Document: '+image_path.split('/')[-1])
 
434
  '''
435
  image = Image.open(image_path).convert("RGB")
436
  model, probas, bboxes_scaled = table_detector(image, THRESHOLD_PROBA=TD_THRESHOLD)
437
+
438
+ if bboxes_scaled.nelement() == 0:
439
+ st.write('No table found in the pdf-page image')
440
+ return ''
441
 
442
  # try:
443
  # st.write('Document: '+image_path.split('/')[-1])