imagetagger icon indicating copy to clipboard operation
imagetagger copied to clipboard

Coordinates of right image border

Open ChristPi opened this issue 7 years ago • 2 comments

When labeling a 640x480 image the coordinates possible for bounding boxes are 0 to 480 in vertical direction and 0 to 641 in horizontal direction. It seems to be impossible to get exactly the coordinate 640. When saving a label with the coordinate 641, editing the label will result in editing a replacement 2x2 box.

ChristPi avatar Nov 09 '18 11:11 ChristPi

I think the problem is a result of a rounding error. We should set those values to min(0) and max(width or height -1)after drawing them into the image.

NFiedler avatar Nov 09 '18 11:11 NFiedler

Trying to edit an old image with a coordinate of 640 will result in a similar scenario of a replacement 2x2 box. Editing a box at any other of the edges will not result in this bug

ChristPi avatar Nov 09 '18 11:11 ChristPi