ptrblck:

Each layer specifies the input and target dimensions.
E.g. in the docs of nn.Conv2d you see the input defined as [N, Cin​, Hin​, Win​] .


Right, I was reading that earlier. Am I making this more complicated than it is? What about the 3d, 2d and 1d tensors?
For instance, if I get the shape of one of my images, let’s just use MNIST. It’s [1, 28, 28]. To me, I’m reading [channel, height, width] as a human. As an input to a Conv2d, Pytorch just sees it as missing a dimension, and in a Conv1d would read [batch, channels, length]?