Error in Pytorch RuntimeError: 0D or 1D target tensor expected, multi-target not supported

Double post from here without a follow-up.