瀏覽代碼

chore: Add .gitignore and a script to verify GridRecovery module import and cell computation with mocked dependencies.

zhch158_admin 3 天之前
父節點
當前提交
3a5b2ab300
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      ocr_utils/pdf_utils.py

+ 2 - 1
ocr_utils/pdf_utils.py

@@ -145,7 +145,8 @@ class PDFUtils:
                     'img_pil': img_dict['img_pil'],
                     'scale': img_dict.get('scale', dpi / 72),
                     'source_path': str(document_path),
-                    'page_idx': idx  # 原始页码索引
+                    'page_idx': idx,  # 原始页码索引
+                    'page_name': f"{document_path.stem}_page_{idx + 1:03d}"
                 })
                 
         elif document_path.suffix.lower() in ['.png', '.jpg', '.jpeg', '.bmp', '.tiff', '.tif']: