I am looking at the example here: https://pytorch.org/docs/_modules/torch/nn/modules/loss.html 177 . I noticed that the input data is passed as:
input = autograd.Variable(torch.randn(3, 5), requires_grad=True)

Shouldn’t requires_grad be set to False, since this is the input data and not the weights.