浏览代码

fix(magic_pdf): include List and Index block types in processing

Add List and Index to the list of block types being processed in the draw_bbox.py file. This inclusion ensures that these block types are handled similarly to other text-containing blocks, improving the overall document processing accuracy and consistency.
myhloli 1 年之前
父节点
当前提交
0a9a6d3e53
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      magic_pdf/libs/draw_bbox.py

+ 2 - 0
magic_pdf/libs/draw_bbox.py

@@ -237,6 +237,8 @@ def draw_span_bbox(pdf_info, pdf_bytes, out_path, filename):
                 BlockType.Text,
                 BlockType.Title,
                 BlockType.InterlineEquation,
+                BlockType.List,
+                BlockType.Index,
             ]:
                 for line in block['lines']:
                     for span in line['spans']: