How the dim parameter of the Softmax() is reflected in CrossEntropyLoss()

nn.CrossEntropyLoss expects the class dimension in dim1 as explained here.