datumaro icon indicating copy to clipboard operation
datumaro copied to clipboard

error in 'find_mask_bbox' @ util.mask_tools

Open jihyeonyi opened this issue 4 years ago • 0 comments

I've tried to get_bbox of Mask with an image below.

Mask(image = [ 
    [ 0, 0, 0, 0, 0 ],
    [ 0, 0, 1, 1, 1 ],
    [ 0, 0, 1, 1, 1 ],
    [ 0, 0, 1, 1, 1 ],
    [ 0, 0, 1, 1, 1 ] 
])

I expected (2, 1, 3, 4), but I got (2, 1, 2, 3)

I think the find_mask_bbox function in the util.mask_tools should be corrected in calculating the width and height.

jihyeonyi avatar Apr 23 '21 06:04 jihyeonyi