From 520e58aa05c333bb970fdc9df2aa625142b4ff9c Mon Sep 17 00:00:00 2001 From: Glenn Jocher Date: Tue, 21 May 2019 16:11:08 +0200 Subject: [PATCH] updates --- utils/datasets.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/utils/datasets.py b/utils/datasets.py index c4395ccd..b1459d4e 100755 --- a/utils/datasets.py +++ b/utils/datasets.py @@ -185,7 +185,7 @@ class LoadImagesAndLabels(Dataset): # for training/testing self.batch = bi # batch index of image # Preload images - if cache & n < 1001: # preload all images into memory if possible + if cache and (n < 1001): # preload all images into memory if possible self.imgs = [cv2.imread(self.img_files[i]) for i in tqdm(range(n), desc='Reading images')] # Preload labels (required for weighted CE training)