Update tensorboard logging
This commit is contained in:
1 parent
7f1640695b
commit
453acdec67
3 files changed
+9
-8
No files matched your search
+3
-2
@@ -19,6 +19,7 @@ import numpy as np
|
||||
import torch
|
||||
import torch.nn as nn
|
||||
import yaml
|
||||
from PIL import Image
|
||||
from scipy.cluster.vq import kmeans
|
||||
from scipy.signal import butter, filtfilt
|
||||
from tqdm import tqdm
|
||||
@@ -1096,8 +1097,8 @@ def plot_images(images, targets, paths=None, fname='images.jpg', names=None, max
|
||||
|
||||
if fname is not None:
|
||||
mosaic = cv2.resize(mosaic, (int(ns * w * 0.5), int(ns * h * 0.5)), interpolation=cv2.INTER_AREA)
|
||||
cv2.imwrite(fname, cv2.cvtColor(mosaic, cv2.COLOR_BGR2RGB))
|
||||
|
||||
# cv2.imwrite(fname, cv2.cvtColor(mosaic, cv2.COLOR_BGR2RGB)) # cv2 save
|
||||
Image.fromarray(mosaic).save(fname) # PIL save
|
||||
return mosaic
|
||||
|
||||
|
||||
|
||||
Reference in new issue
Block a user