Performs back-propagation on a Torch Tensor, given some external gradient.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(torch_tensor), | intent(in) | :: | tensor |
Tensor to compute gradients of |
||
| type(torch_tensor), | intent(in) | :: | external_gradient |
External tensor used as an initial scaling of the gradient calculation |
||
| logical, | intent(in), | optional | :: | retain_graph |
Should the computational graph be retained? |
Performs back-propagation on a Torch Tensor, with an assumed external_gradient of ones.
| Type | Intent | Optional | Attributes | Name | ||
|---|---|---|---|---|---|---|
| type(torch_tensor), | intent(in) | :: | tensor |
Tensor to compute gradients of |
||
| logical, | intent(in), | optional | :: | retain_graph |
Should the computational graph be retained? |