docling-project / docling-project/docling
Incorrect detection of tables in pfd in debug mode
- Dominant language
- Python
- Stars
- 66.4k
- Forks
- 4.8k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 84
Description
### Bug
Hello
I have tried to extract tables from document: ["Czyste powietrze"](https://www.google.com/url?sa=t&source=web&rct=j&opi=89978449&url=https://www.gov.pl/attachment/84cc97e4-2c14-4732-a99e-8857e89e81fb&ved=2ahUKEwibz7vp8aGPAxVMIBAIHVYlGmIQFnoECBYQAQ&usg=AOvVaw1917J7cS3Ygv4d39wo8F0l)
On page 22 the first table is detected when docling debug mode is switched OFF and not detected when docling debug mode is switched ON.
**Page 22 presented when debug is swithed OFF**
**Page 22 presented when debug is swithed ON**
**Page 22 from docling debug mode**
### Steps to reproduce
pipeline_options = PdfPipelineOptions()
pipeline_options.do_ocr = False
pipeline_options.do_table_structure = True
pipeline_options.table_structure_options.do_cell_matching = False
pipeline_options.table_structure_options.mode = TableFormerMode.ACCURATE
pipeline_options.accelerator_options = AcceleratorOptions(
num_threads=4, device=AcceleratorDevice.AUTO
)
pipeline_options.generate_page_images = True
pipeline_options.generate_table_images = True
pipeline_options.generate_parsed_pages = True
pipeline_options.generate_picture_images = True
settings.debug.visualize_layout = True
settings.debug.visualize_tables = True
settings.debug.visualize_cells = True
doc_converter = DocumentConverter(
format_options={
InputFormat.PDF: PdfFormatOption(
pipeline_options=pipeline_options
)
}
)
### Docling version
Docling version: 2.47.0
Docling Core version: 2.45.0
Docling IBM Models version: 3.9.0
Docling Parse version: 4.2.3
### Python version
Python: cpython-312 (3.12.10)
Contributor guide
Assessment
This issue has not been assessed yet.