merge minor changes before branching
This commit is contained in:
parent
44d4eb5a98
commit
4c06206445
@ -26,7 +26,6 @@ def remove_included(rectangles):
|
|||||||
|
|
||||||
def is_not_included(rect, rectangles):
|
def is_not_included(rect, rectangles):
|
||||||
return not any(included(r2, rect) for r2 in rectangles if not rect == r2)
|
return not any(included(r2, rect) for r2 in rectangles if not rect == r2)
|
||||||
return not any(includes(r2, rect) for r2 in rectangles if not rect == r2)
|
|
||||||
|
|
||||||
rectangles = list(map(xywh_to_vec_rect, rectangles))
|
rectangles = list(map(xywh_to_vec_rect, rectangles))
|
||||||
rectangles = filter(partial(is_not_included, rectangles=rectangles), rectangles)
|
rectangles = filter(partial(is_not_included, rectangles=rectangles), rectangles)
|
||||||
@ -132,7 +131,6 @@ def xywh_to_vecs(rect):
|
|||||||
x2 = x1 + w
|
x2 = x1 + w
|
||||||
y2 = y1 + h
|
y2 = y1 + h
|
||||||
return Rectangle(x1, y1, x2, y2)
|
return Rectangle(x1, y1, x2, y2)
|
||||||
return (x1, y1), (x2, y2)
|
|
||||||
|
|
||||||
|
|
||||||
def vec_rect_to_xywh(rect):
|
def vec_rect_to_xywh(rect):
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user