From 41d7eb777a4f5eecaf2936a873fae02908632f3e Mon Sep 17 00:00:00 2001 From: raxtemur Date: Thu, 30 Nov 2023 09:03:47 +0000 Subject: [PATCH] TLDR-531 bug fix --- dedoc/readers/pdf_reader/data_classes/tables/table_tree.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dedoc/readers/pdf_reader/data_classes/tables/table_tree.py b/dedoc/readers/pdf_reader/data_classes/tables/table_tree.py index a1f06c5e..90bad38a 100644 --- a/dedoc/readers/pdf_reader/data_classes/tables/table_tree.py +++ b/dedoc/readers/pdf_reader/data_classes/tables/table_tree.py @@ -96,7 +96,7 @@ def __build_childs(self, cur: "TableTree", hierarchy: List, contours: List) -> " if h[3] == cur.id_contours: bbox = cv2.boundingRect(contours[i]) # [x_begin, y_begin, width, height] # Эвристика №1 на ячейку - if bbox[2] < self.config["min_w_cell"] or bbox[3] < self.config["min_h_cell"]: + if bbox[2] < self.min_w_cell or bbox[3] < self.min_h_cell: if self.config.get("debug_mode", False): self.logger.debug(f"Contour {i} isn't correct") continue