derivative of multivariable function pytorch

Solutions on MaxInterview for derivative of multivariable function pytorch by the best coders in the world

showing results for - "derivative of multivariable function pytorch"
Enes
18 Aug 2017
1import torch
2
3x = torch.autograd.Variable(torch.Tensor([2]),requires_grad=True)
4y = 5*x**4 + 3*x**3 + 7*x**2 + 9*x - 5
5
6y.backward()
7x.grad
8
similar questions