updates
This commit is contained in:
parent
286257c5ac
commit
c5e58b6484
|
@ -143,7 +143,7 @@ class LoadImagesAndLabels(Dataset): # for training/testing
|
||||||
for x in self.img_files]
|
for x in self.img_files]
|
||||||
|
|
||||||
if n < 200: # preload all images into memory if possible
|
if n < 200: # preload all images into memory if possible
|
||||||
self.imgs = (cv2.imread(img_files[i]) for i in range(n))
|
self.imgs = [cv2.imread(img_files[i]) for i in range(n)]
|
||||||
|
|
||||||
def __len__(self):
|
def __len__(self):
|
||||||
return len(self.img_files)
|
return len(self.img_files)
|
||||||
|
|
Loading…
Reference in New Issue