ptrblck:

This shouldn’t be the case, as I’m using nn.NLLLoss and it works on my machine.


That’s the strangest bit. It’s not working with my code. And another strange thing is, I am explicitly converting the tensors to the expected dtype (and printing the dtype for confirmation ) and yet the criterion is throwing the same error.