RuntimeError: cuda runtime error(59): device-side assert triggered at /pytorch/aten/src/THC/generic/THCTensorMath.cu:24

It looks like your target values are not in the expected range of [0, nb_classes-1].
Could you check that and if possible post some code how you’ve created the target indices?

8 Likes