i suspect that the data returned from the DataLoader is returned as DoubleTensor instead of what the model wants by default: FloatTensor.
Right after # get the inputs, i.e. after the inputs, labels = ..., add the line:
inputs = inputs.float()