Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -69,12 +69,17 @@ def process_pdf(pdf_file):
|
|
69 |
return all_figures, all_tables
|
70 |
|
71 |
# Create Gradio interface
|
|
|
72 |
iface = gr.Interface(
|
73 |
fn=process_pdf,
|
74 |
inputs=gr.File(label="Upload a PDF"),
|
75 |
outputs=[
|
76 |
-
gr.
|
77 |
-
|
|
|
|
|
|
|
|
|
78 |
],
|
79 |
title="PDF figures and tables extraction based on YOLOv10",
|
80 |
description="Upload a PDF file to get figures and tables in the PDF"
|
|
|
69 |
return all_figures, all_tables
|
70 |
|
71 |
# Create Gradio interface
|
72 |
+
|
73 |
iface = gr.Interface(
|
74 |
fn=process_pdf,
|
75 |
inputs=gr.File(label="Upload a PDF"),
|
76 |
outputs=[
|
77 |
+
gr.Row(
|
78 |
+
[
|
79 |
+
gr.Gallery(label="Figures from PDF", object_fit='scale-down'),
|
80 |
+
gr.Gallery(label="Tables from PDF", object_fit='scale-down')
|
81 |
+
]
|
82 |
+
)
|
83 |
],
|
84 |
title="PDF figures and tables extraction based on YOLOv10",
|
85 |
description="Upload a PDF file to get figures and tables in the PDF"
|