diff --git a/vidocp/utils/post_processing.py b/vidocp/utils/post_processing.py index 79626d2..a3a04b1 100644 --- a/vidocp/utils/post_processing.py +++ b/vidocp/utils/post_processing.py @@ -43,6 +43,7 @@ def adjacent(a, b): """ def adjacent2d(g, h, i, j, k, l): + #print(adjacent1d(g, h) and any(k <= p <= l for p in [i, j])) return adjacent1d(g, h) and any(k <= p <= l for p in [i, j]) if any(x is None for x in (a, b)): @@ -78,6 +79,7 @@ def __remove_isolated_unsorted(rectangles): def __remove_isolated_sorted(rectangles): def is_connected(left, center, right): + # print(left,center,right, list(starmap(adjacent, [(left, center), (center, right)]))) return any(starmap(adjacent, [(left, center), (center, right)])) rectangles = list(map(xywh_to_vec_rect, rectangles))