Thank you very much! Could you be kind enough to verify if my understanding is correct?
From the example in the link you provided -
a = torch.rand(10, requires_grad=True).double() # a is NOT a leaf variable as it was created by the operation that cast a float tensor into a double tensor

a = torch.rand(10).double().requires_grad_() # a requires gradients and has no operations creating it: it's a leaf variable and can be given to an optimizer.

So, this means autograd starts tracking the tensor only when requires_grad is set to True. Is that correct?
Thanks a lot