bug fix on #1114
This commit is contained in:
parent
0ffbf5534e
commit
b0629d622c
|
@ -938,7 +938,7 @@ def plot_images(images, targets, paths=None, fname='images.jpg', names=None, max
|
|||
img = cv2.resize(img, (w, h))
|
||||
|
||||
mosaic[block_y:block_y + h, block_x:block_x + w, :] = img
|
||||
if targets is not None:
|
||||
if len(targets) > 0:
|
||||
image_targets = targets[targets[:, 0] == i]
|
||||
boxes = xywh2xyxy(image_targets[:, 2:6]).T
|
||||
classes = image_targets[:, 1].astype('int')
|
||||
|
|
Loading…
Reference in New Issue