glenn-jocher commited on
Commit
b894e69
1 Parent(s): bfad364

Update mosaic plots font size (#4596)

Browse files
Files changed (1) hide show
  1. utils/plots.py +1 -1
utils/plots.py CHANGED
@@ -162,7 +162,7 @@ def plot_images(images, targets, paths=None, fname='images.jpg', names=None, max
162
  mosaic = cv2.resize(mosaic, tuple(int(x * ns) for x in (w, h)))
163
 
164
  # Annotate
165
- fs = int(h * ns * 0.02) # font size
166
  annotator = Annotator(mosaic, line_width=round(fs / 10), font_size=fs)
167
  for i in range(i + 1):
168
  x, y = int(w * (i // ns)), int(h * (i % ns)) # block origin
 
162
  mosaic = cv2.resize(mosaic, tuple(int(x * ns) for x in (w, h)))
163
 
164
  # Annotate
165
+ fs = int((h + w) * ns * 0.01) # font size
166
  annotator = Annotator(mosaic, line_width=round(fs / 10), font_size=fs)
167
  for i in range(i + 1):
168
  x, y = int(w * (i // ns)), int(h * (i % ns)) # block origin