TensorDictBase.detach#
- TensorDictBase.detach() Self#
Detach the tensors in the tensordict.
- Returns:
a new tensordict with no tensor requiring gradient.
Every tensordict class and every tensorclass has this method. For the other methods, see Methods by task.