Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
pdf-miner
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Qin Kaijie
pdf-miner
Commits
1340a97a
Commit
1340a97a
authored
Apr 22, 2024
by
赵小蒙
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
统一使用ocr组装markdown
parent
f6d8f6ca
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
2 deletions
+3
-2
AbsPipe.py
magic_pdf/pipe/AbsPipe.py
+3
-2
No files found.
magic_pdf/pipe/AbsPipe.py
View file @
1340a97a
...
@@ -106,8 +106,9 @@ class AbsPipe(ABC):
...
@@ -106,8 +106,9 @@ class AbsPipe(ABC):
parse_type
=
pdf_mid_data
[
"_parse_type"
]
parse_type
=
pdf_mid_data
[
"_parse_type"
]
pdf_info_list
=
pdf_mid_data
[
"pdf_info"
]
pdf_info_list
=
pdf_mid_data
[
"pdf_info"
]
if
parse_type
==
AbsPipe
.
PIP_TXT
:
if
parse_type
==
AbsPipe
.
PIP_TXT
:
content_list
=
mk_universal_format
(
pdf_info_list
,
img_buket_path
)
# content_list = mk_universal_format(pdf_info_list, img_buket_path)
md_content
=
mk_mm_markdown
(
content_list
)
# md_content = mk_mm_markdown(content_list)
md_content
=
ocr_mk_mm_markdown_with_para
(
pdf_info_list
,
img_buket_path
)
elif
parse_type
==
AbsPipe
.
PIP_OCR
:
elif
parse_type
==
AbsPipe
.
PIP_OCR
:
md_content
=
ocr_mk_mm_markdown_with_para
(
pdf_info_list
,
img_buket_path
)
md_content
=
ocr_mk_mm_markdown_with_para
(
pdf_info_list
,
img_buket_path
)
return
md_content
return
md_content
...
...
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