Last active
April 27, 2024 09:38
-
-
Save documentprocessing/b883d532025eec8cf7ebff0640fa7255 to your computer and use it in GitHub Desktop.
Extract tables from PDF file using pdf2docx API
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pdf2docx import Converter | |
pdf_file = 'sample_pdf.pdf' | |
converter = Converter(pdf_file) | |
tables = converter.extract_tables(start=0, end=1) | |
converter.close() | |
#loop through the tables to print these | |
for table in tables: | |
print(table) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment