diff --git a/ultralytics/utils/ops.py b/ultralytics/utils/ops.py index f8600f45d..46e96f11e 100644 --- a/ultralytics/utils/ops.py +++ b/ultralytics/utils/ops.py @@ -528,7 +528,7 @@ def ltwh2xywh(x): def xyxyxyxy2xywhr(x): """ Convert batched Oriented Bounding Boxes (OBB) from [xy1, xy2, xy3, xy4] to [xywh, rotation]. Rotation values are - expected in degrees from 0 to 90. + returned in radians from 0 to pi/2. Args: x (numpy.ndarray | torch.Tensor): Input box corners [xy1, xy2, xy3, xy4] of shape (n, 8). @@ -551,7 +551,7 @@ def xyxyxyxy2xywhr(x): def xywhr2xyxyxyxy(x): """ Convert batched Oriented Bounding Boxes (OBB) from [xywh, rotation] to [xy1, xy2, xy3, xy4]. Rotation values should - be in degrees from 0 to 90. + be in radians from 0 to pi/2. Args: x (numpy.ndarray | torch.Tensor): Boxes in [cx, cy, w, h, rotation] format of shape (n, 5) or (b, n, 5).