diff --git a/models/common.py b/models/common.py index 346fa37ae2d0..557163310e74 100644 --- a/models/common.py +++ b/models/common.py @@ -446,10 +446,7 @@ def forward(self, im, augment=False, visualize=False, val=False): if int8: scale, zero_point = output['quantization'] y = (y.astype(np.float32) - zero_point) * scale # re-scale - y[..., 0] *= w # x - y[..., 1] *= h # y - y[..., 2] *= w # w - y[..., 3] *= h # h + y[..., :4] *= [w, h, w, h] # xywh normalized to pixels y = torch.tensor(y) if isinstance(y, np.ndarray) else y return (y, []) if val else y