camelot icon indicating copy to clipboard operation
camelot copied to clipboard

fail when detect abnormal border table

Open GloryVu opened this issue 1 year ago • 1 comments

Screenshot from 2024-03-25 17-41-44

python code: tables = camelot.read_pdf(temp_pdf.name, pages='1-end', line_scale=60)

result: duplicate table extracted, incorrect table (each border will be a columns/rows)

for table in tables: print('table:\n',table.page,table._bbox,table.df)

console:
table: 1 (72.0, 105.6, 540.48, 124.56) 0 1 2 3 4 0
1 Lãi suất cho vay tối thiểu Thời gian vay tối thiểu
table: 1 (72.24, 103.92, 540.48, 123.6) 0 1 2 3 0 Lãi suất cho vay tối thiểu Thời gian vay tối thiểu table: 2 (72.0, 558.72, 539.52, 720.0) 0 1 2 3 0 6%/năm trong 06 tháng đầu tiên kể từ thời điểm... 36 tháng 1
2 6%/năm trong 12 tháng đầu tiên kể từ thời điểm... 36 tháng 3
4 6%/năm trong 18 tháng đầu tiên kể từ thời điểm... 60 tháng 5
6 6%/năm trong 24 tháng đầu tiên kể từ thời điểm... 60 tháng 7
8 7%/năm trong 36 tháng đầu tiên kể từ thời điểm... 60 tháng table: 2 (72.24, 557.04, 540.48, 719.28) 0 1 2 3 0 6%/năm trong 06 tháng đầu tiên kể từ thời điểm... 36 tháng 1
2 6%/năm trong 12 tháng đầu tiên kể từ thời điểm... 36 tháng 3
4 6%/năm trong 18 tháng đầu tiên kể từ thời điểm... 60 tháng 5
6 6%/năm trong 24 tháng đầu tiên kể từ thời điểm... 60 tháng 7
8 7%/năm trong 36 tháng đầu tiên kể từ thời điểm... 60 tháng

GloryVu avatar Mar 25 '24 10:03 GloryVu

Hey!

As https://github.com/camelot-dev/camelot/issues/343 this repo is no longer maintained, we try to build a maintained fork at pypdf_table_extraction.

Do you want to check out the cod ethere to see if the issue still persists. If so please open an issue there.

bosd avatar Apr 03 '24 05:04 bosd

Closing for lack of information/action, issue was not opened at previous repo and without the file there's nothing to be done.

DoomedJupiter avatar Mar 14 '25 21:03 DoomedJupiter