when i use criterion = torch.nn.CrossEntropyLoss() to get the loss between the predicted value and the label, there is a error like this:
TypeError: CudaClassNLLCriterion_updateOutput received an invalid combination of arguments - got (int, torch.cuda.FloatTensor, !torch.cuda.FloatTensor!, torch.cuda.FloatTensor, bool, NoneType, torch.cuda.FloatTensor), but expected (int state, torch.cuda.FloatTensor input, torch.cuda.LongTensor target, torch.cuda.FloatTensor output, bool sizeAverage, [torch.cuda.FloatTensor weights or None], torch.cuda.FloatTensor total_weight)
i have checked my inputs many times, the two inputs are no problem. While this error still exist. Does any one can give some suggestions?