I have grey-scale images in .png and i’m loading them in using ImageFolder(), and I then do the following transforms to get them as a single channel tensor,
transformations = transforms.Compose([transforms.ToTensor(),
transforms.ToPILImage(),
transforms.Grayscale(),
transforms.ToTensor()])
It works, but im wondering if this is making the whole process a bit slow, perhaps there is a more efficient way of doing this?