Hi，we do not need the gradient of input(In most cases, they are useless, unless some special works like neural style transfer, where we only iteratively change the input to optimize the total loss).  Usually, we only want to get the model trained. Parameters in each layer are default to be requires_grad=True.
So there is no worry about it.