datasets.py self.batch_shapes fix

This commit is contained in:
Glenn Jocher committed 2020-06-01 18:11:18 -07:00
1 parent 7a00a5eff2
commit ee8988b8a2
3 files changed
+3 -4

No files matched your search

+1 -1
View File
@@ -322,7 +322,7 @@ class LoadImagesAndLabels(Dataset): # for training/testing
elif mini > 1:
shapes[i] = [1, 1 / mini]
self.batch_shapes = np.ceil(np.array(shapes) * img_size / 64.).astype(np.int) * 64
self.batch_shapes = np.round(np.array(shapes) * img_size / 32. + 1.).astype(np.int) * 32
# Cache labels
self.imgs = [None] * n