浏览代码

Merge pull request #2402 from myhloli/dev

build(deps): pin pdfminer.six version to 20250324
Xiaomeng Zhao 6 月之前
父节点
当前提交
5e15d9b664
共有 2 个文件被更改,包括 4 次插入2 次删除
  1. 3 1
      magic_pdf/model/sub_modules/mfr/unimernet/unimernet_hf/modeling_unimernet.py
  2. 1 1
      requirements.txt

+ 3 - 1
magic_pdf/model/sub_modules/mfr/unimernet/unimernet_hf/modeling_unimernet.py

@@ -343,7 +343,9 @@ REPLACEMENTS_PATTERNS = {
     re.compile(r'\\slash'): r'/',
     re.compile(r'\\slash'): r'/',
     re.compile(r'\\textperthousand'): r'‰',
     re.compile(r'\\textperthousand'): r'‰',
     re.compile(r'\\sun'): r'☉',
     re.compile(r'\\sun'): r'☉',
-    re.compile(r'\\textunderscore'): r'\\_'
+    re.compile(r'\\textunderscore'): r'\\_',
+    re.compile(r'\\fint'): r'⨏',
+    re.compile(r'\\up '): r'\\ ',
 }
 }
 QQUAD_PATTERN = re.compile(r'\\qquad(?!\s)')
 QQUAD_PATTERN = re.compile(r'\\qquad(?!\s)')
 
 

+ 1 - 1
requirements.txt

@@ -10,6 +10,6 @@ scikit-learn>=1.0.2
 torch>=2.2.2,!=2.5.0,!=2.5.1
 torch>=2.2.2,!=2.5.0,!=2.5.1
 torchvision
 torchvision
 transformers>=4.49.0,!=4.51.0,<5.0.0
 transformers>=4.49.0,!=4.51.0,<5.0.0
-pdfminer.six>=20250416
+pdfminer.six==20250324
 tqdm>=4.67.1
 tqdm>=4.67.1
 # The requirements.txt must ensure that only necessary external dependencies are introduced. If there are new dependencies to add, please contact the project administrator.
 # The requirements.txt must ensure that only necessary external dependencies are introduced. If there are new dependencies to add, please contact the project administrator.