Since you write inplace into it a Tensor that requires gradient, it will work fine.
You only need to set requires_grad=True explicitly for a Tensor if you plan to access it .grad field or ask for gradients for it in autograd.grad.