HumanSignal / HumanSignal/label-studio

RectangleLabels: x,y values inconsistant wrt typed or dragged rotation

Open
#4,554 0 comments 0 reactions 1 assignee Claimed by @makseq View on GitHub
Dominant language
TypeScript
Stars
28.3k
Forks
3.7k
Avg merge
14h
Merged PRs (30d)
15

Description

First posted here accidentally :
https://github.com/heartexlabs/label-studio-converter/issues/235

The values of x,y is NOT "_ coordinate of the top left corner before rotation (0-100)" when the BBox is rotated using anchor thingy (by dragging). In this the rotation transformation occurs around cx,cy.

However, values of x,y is "_ coordinate of the top left corner before rotation (0-100)" when BBox rotation values is typed. In this the rotation transformation occurs around x,y.

Help. This is expected behavious or a bug in rotation using dragging method?

BBox:
![Screenshot (820)](https://github.com/heartexlabs/label-studio-converter/assets/24550022/8723a2c1-9338-45ea-ac42-60d03d292a76)
` "value": {
"x": 21.331058020477816,
"y": 22.727272727272727,
"width": 33.27645051194539,
"height": 18.181818181818183,
"rotation": 0,
"rectanglelabels": [
"bbox"
]`

Typed-Rotation:
![Screenshot (822)](https://github.com/heartexlabs/label-studio-converter/assets/24550022/f55269db-7d4e-4bb8-aee3-9c1464cfb51b)
`
"value": {
"x": 21.331058020477816,
"y": 22.727272727272727,
"width": 33.27645051194539,
"height": 18.181818181818183,
"rotation": 45,
"rectanglelabels": [
"typed-rotated-bbox"
]
`

Drag-Rotation:
![Screenshot (821)](https://github.com/heartexlabs/label-studio-converter/assets/24550022/4413b325-a110-4807-ac7a-1b8165e61cd1)
`
"value": {
"x": 29.54614896742924,
"y": 3.0447607617210197,
"width": 33.27645051194534,
"height": 18.181818181818233,
"rotation": 44.8606754121663,
"rectanglelabels": [
"drag-rotated-bbox"
]
`

_Values below images are from json export, notice the value.x ,value.y for dragged and typed_

Thanking in anticipation.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.