def ReadImages(Path):
LabelList = list()
ImageCV = list()
classes = ["nonPdr", "pdr"]
FolderList = [f for f in os.listdir(Path) if not f.startswith('.')]
for File in FolderList:
for index, Image in enumerate(os.listdir(os.path.join(Path, File))):
ImageCV.append(cv2.resize(cv2.imread(os.path.join(Path, File) + os.path.sep + Image), (224,224)))
LabelList.append(classes.index(os.path.splitext(File)[0]))
print(FolderList)
return ImageCV, LabelList
I got this method, and I'm not understanding properly what it do line by line, can someone help me?