Skip to content

Commit e3fad08

Browse files
committed
lint
1 parent 8f85465 commit e3fad08

1 file changed

Lines changed: 3 additions & 7 deletions

File tree

  • unstructured/partition/pdf_image

unstructured/partition/pdf_image/ocr.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -478,13 +478,9 @@ def supplement_layout_with_ocr_elements(
478478
else:
479479
ocr_regions_to_add = ocr_layout
480480
else:
481-
mask = (
482-
~bboxes1_is_almost_subregion_of_bboxes2(
483-
ocr_layout.element_coords, layout.element_coords, subregion_threshold
484-
)
485-
.sum(axis=1)
486-
.astype(bool)
487-
)
481+
mask = ~bboxes1_is_almost_subregion_of_bboxes2(
482+
ocr_layout.element_coords, layout.element_coords, subregion_threshold
483+
).sum(axis=1).astype(bool)
488484

489485
# add ocr regions that are not covered by layout
490486
ocr_regions_to_add = ocr_layout.slice(mask)

0 commit comments

Comments
 (0)