I have realised this isn’t an issue with ToTensor but rather an issue with loading the images with ImageFolder. The images I am loading are 256x256, however when loaded with ImageFolder they become 3x256x256, why is it adding this dimension?