albanD:

labels.squeeze_(-1)


Hi AlbanD,
Thank you very much for the suggestion.
But this:
RuntimeError: Assertion `cur_target >= 0 && cur_target < n_classes’ failed.  at …\aten\src\THNN/generic/ClassNLLCriterion.c:92
Any idea please?