Spaces:
Runtime error
Runtime error
Commit
·
19dd7f6
1
Parent(s):
7ffe108
Upload app.py
Browse files
app.py
CHANGED
|
@@ -48,13 +48,13 @@ def main():
|
|
| 48 |
|
| 49 |
|
| 50 |
inputpath = "temp//temp.pdf"
|
| 51 |
-
outputpath = ""
|
| 52 |
with st.spinner('Converting pdf to images...'):
|
| 53 |
result = pdf2jpg.convert_pdf2jpg(inputpath,outputpath, pages="ALL")
|
| 54 |
|
| 55 |
st.markdown('### Images of detected tables')
|
| 56 |
with st.spinner('Detecting table in images...'):
|
| 57 |
-
for index, entry in enumerate(os.listdir('temp.pdf_dir')):
|
| 58 |
# Construct the full file path
|
| 59 |
full_path = os.path.join('temp.pdf_dir', entry)
|
| 60 |
print(full_path)
|
|
|
|
| 48 |
|
| 49 |
|
| 50 |
inputpath = "temp//temp.pdf"
|
| 51 |
+
outputpath = "temp_pdf"
|
| 52 |
with st.spinner('Converting pdf to images...'):
|
| 53 |
result = pdf2jpg.convert_pdf2jpg(inputpath,outputpath, pages="ALL")
|
| 54 |
|
| 55 |
st.markdown('### Images of detected tables')
|
| 56 |
with st.spinner('Detecting table in images...'):
|
| 57 |
+
for index, entry in enumerate(os.listdir('./temp.pdf_dir')):
|
| 58 |
# Construct the full file path
|
| 59 |
full_path = os.path.join('temp.pdf_dir', entry)
|
| 60 |
print(full_path)
|