Scale the box with horizontal and vertical scaling factors
(self, scale_x: float, scale_y: float)
| 271 | return (self.tensor[:, :2] + self.tensor[:, 2:]) / 2 |
| 272 | |
| 273 | def scale(self, scale_x: float, scale_y: float) -> None: |
| 274 | """ |
| 275 | Scale the box with horizontal and vertical scaling factors |
| 276 | """ |
| 277 | self.tensor[:, 0::2] *= scale_x |
| 278 | self.tensor[:, 1::2] *= scale_y |
| 279 | |
| 280 | @classmethod |
| 281 | def cat(cls, boxes_list: List["Boxes"]) -> "Boxes": |
no outgoing calls
no test coverage detected