The in_channels of the second convolution would be defined by the out_channels of the previous one, which defines the size of dim1 (32 in your example). Besides that you can pick other parameters as you wish.