Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
wangsen
MinerU
Commits
5f794533
Unverified
Commit
5f794533
authored
Nov 08, 2024
by
Xiaomeng Zhao
Committed by
GitHub
Nov 08, 2024
Browse files
Merge pull request #902 from myhloli/fix-line-over-512
refactor(pdf_parse): adjust line count threshold for layoutreader
parents
2600d324
5936684f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
1 deletion
+1
-1
magic_pdf/pdf_parse_union_core_v2.py
magic_pdf/pdf_parse_union_core_v2.py
+1
-1
No files found.
magic_pdf/pdf_parse_union_core_v2.py
View file @
5f794533
...
@@ -298,7 +298,7 @@ def sort_lines_by_model(fix_blocks, page_w, page_h, line_height):
...
@@ -298,7 +298,7 @@ def sort_lines_by_model(fix_blocks, page_w, page_h, line_height):
block
[
'lines'
].
append
({
'bbox'
:
line
,
'spans'
:
[]})
block
[
'lines'
].
append
({
'bbox'
:
line
,
'spans'
:
[]})
page_line_list
.
extend
(
lines
)
page_line_list
.
extend
(
lines
)
if
len
(
page_line_list
)
>
512
:
# layoutreader最高支持512line
if
len
(
page_line_list
)
>
200
:
# layoutreader最高支持512line
return
None
return
None
# 使用layoutreader排序
# 使用layoutreader排序
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment