Jun-12-2020, 10:20 AM
Sorry, my mistake - it should work if you do this:
import glob def open_train_data(): return glob.glob('/home/mojito/Desktop/CNN/datasets/training_data/images/*') #the '*' is a 'wildcard' and it means to match one or more characters for f in open_train_data(): dict1 = pickle.load(open(f, 'rb')) ###do whatever else you need toI forgot to open the file.