Dimensions of an input image - vision - PyTorch Forums
discuss.pytorch.org › t › dimensions-of-an-inputJun 09, 2018 · In PyTorch, images are represented as [channels, height, width], so a color image would be [3, 256, 256]. During the training you will get batches of images, so your shape in the forward method will get an additional batch dimension at dim0: [batch_size, channels, height, width].