diff --git a/references/detection/utils.py b/references/detection/utils.py index 1a84f2340d..265f63ff37 100644 --- a/references/detection/utils.py +++ b/references/detection/utils.py @@ -28,7 +28,7 @@ def plot_samples(images, targets: List[Dict[str, np.ndarray]]) -> None: for box in boxes: if boxes.ndim == 3: - cv2.fillPoly(target, [np.int0(box)], 1) + cv2.fillPoly(target, [np.intp(box)], 1) else: target[int(box[1]) : int(box[3]) + 1, int(box[0]) : int(box[2]) + 1] = 1 if nb_samples > 1: