Add Paddle exports to benchmarks (#9459)

* Add Paddle exports to benchmarks

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>

* Update plots.py

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>

* Update common.py

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
This commit is contained in:
Glenn Jocher authored and GitHub committed 2022-09-18 00:17:31 +02:00
1 parent 0608374065
commit afb9860522
3 files changed
+7 -9

No files matched your search

+2 -2
View File
@@ -99,9 +99,9 @@ def plot_images_and_masks(images, targets, masks, paths=None, fname='images.jpg'
if mh != h or mw != w:
mask = image_masks[j].astype(np.uint8)
mask = cv2.resize(mask, (w, h))
mask = mask.astype(np.bool)
mask = mask.astype(bool)
else:
mask = image_masks[j].astype(np.bool)
mask = image_masks[j].astype(bool)
with contextlib.suppress(Exception):
im[y:y + h, x:x + w, :][mask] = im[y:y + h, x:x + w, :][mask] * 0.4 + np.array(color) * 0.6
annotator.fromarray(im)