get_tables_from_model: utilise artificial bound thresholding…

(to improve separation of neighbouring tables, esp. across
 columns; since model's threshold class is particularly weak,
 also use lower threshold here)
This commit is contained in:
Robert Sachunsky 2026-04-16 04:49:07 +02:00
parent 12b1271487
commit 9d6ff65e1d

View file

@ -1539,7 +1539,11 @@ class Eynollah:
return image_revised_last
def get_tables_from_model(self, img):
prediction_table, _ = self.do_prediction_new_concept(False, img, self.model_zoo.get("table"))
prediction_table, _ = self.do_prediction_new_concept(False, img,
self.model_zoo.get("table"),
thresholding_for_artificial_class=True,
threshold_art_class=0.05,
artificial_class=2)
prediction_table = prediction_table.astype(np.uint8)
return prediction_table