Function autograd::ops::grad_with_default
[−]
[src]
pub fn grad_with_default(
ys: &[&Tensor],
xs: &[&Tensor],
output_grads: &[&Tensor]
) -> Vec<Tensor>
Returns gradient tensors wrt input tensors.
Arguments
ys
- Targets of differentiation.xs
- tensors with which differentiateys
.output_grads
- Already known gradients ofys
.
The length must be same as ys
's. If each objective is not a scalar,
you must pass the "Some" value. In most cases, it is initialized with 1s.
Returns
Symbolic gradient tensors corresponding to xs
in the same order as xs
For detailed, see grad.