docling-project / docling-project/docling
How to obtain image coordinates for detection of headers/footers images from PDF pages?
- Dominant language
- Python
- Stars
- 66.4k
- Forks
- 4.8k
- Avg merge
- 2d 21h
- Merged PRs (30d)
- 84
Description
I was reading [this question](https://github.com/docling-project/docling/issues/2037) and saw the suggestion to define a fixed vertical area (e.g. top/bottom 5% of the page) to remove extracted images during post-processing.
Currently, I'm saving to markdown, which creates image files:
`result.document.save_as_markdown(md_filename, image_mode=ImageRefMode.REFERENCED)`
I found that I can get the coordinates separately using extract_image_coordinates(), but I can't figure out how to properly match the images from both processes. Are they processed in the same sequence, such that the first image of both is the same, second image the same, etc.? Or is there some other way to link them?
Contributor guide
Assessment
This issue has not been assessed yet.