Can anyone solve this?
torch.tensor(2,require_grad=True)


  
    
      Traceback (most recent call last):
      
      File "", line 1, in 
       torch.tensor(2,require_grad=True)
      
      TypeError: tensor() got an unexpected keyword argument 'require_grad'
    
  


It's actually:


  requires_grad

