mirror of
https://github.com/DS4SD/docling.git
synced 2025-12-08 20:58:11 +00:00
fix(pypdfium2): Fix OCR bounding box misalignment caused by mismatched rotation metadata (#2039)
* Fix OCR bounding box misalignment caused by rotation metadata Signed-off-by: AndrewTsai0406 <tsai247365@gmail.com> * Add rotation-mismatch scanned pdf test case Signed-off-by: AndrewTsai0406 <tsai247365@gmail.com> * add ground truth for ocr_test_rotation_mismatch.pdf Signed-off-by: AndrewTsai0406 <tsai247365@gmail.com> * add ground truth for ocr_test_rotation_mismatch.pdf Signed-off-by: AndrewTsai0406 <tsai247365@gmail.com> * Updated test GT and merged from main Signed-off-by: Christoph Auer <cau@zurich.ibm.com> * Fix OCR test by excluding mismatched rotation example Signed-off-by: Christoph Auer <cau@zurich.ibm.com> --------- Signed-off-by: AndrewTsai0406 <tsai247365@gmail.com> Signed-off-by: Christoph Auer <cau@zurich.ibm.com> Co-authored-by: Christoph Auer <cau@zurich.ibm.com>
This commit is contained in:
@@ -31,7 +31,8 @@ def get_pdf_paths():
|
||||
directory = Path("./tests/data_scanned")
|
||||
|
||||
# List all PDF files in the directory and its subdirectories
|
||||
pdf_files = sorted(directory.rglob("*.pdf"))
|
||||
pdf_files = sorted(directory.rglob("ocr_test*.pdf"))
|
||||
|
||||
return pdf_files
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user