Masks are now bool

This commit is contained in:
LinasKo 2024-06-21 12:56:14 +03:00
parent ec517124f8
commit fc11f4d7af
1 changed files with 1 additions and 1 deletions

View File

@ -143,7 +143,7 @@ def from_florence_2(
for polygons_of_same_class in result["polygons"]:
for polygon in polygons_of_same_class:
polygon = np.reshape(polygon, (-1, 2)).astype(np.int32)
mask = polygon_to_mask(polygon, resolution_wh)
mask = polygon_to_mask(polygon, resolution_wh).astype(bool)
masks_list.append(mask)
xyxy = polygon_to_xyxy(polygon)
xyxy_list.append(xyxy)