TensorDictBase.amax#
- TensorDictBase.amax(dim: int | NO_DEFAULT = NO_DEFAULT, keepdim: bool = False, *, reduce: bool | None = None) Self | Tensor#
Returns the maximum values of all elements in the input tensordict.
Same as
max()withreturn_indices=False. A tupledimreduces only its first dim. Starting with TensorDict 0.17, the default will change to reducing every dim of the tuple, astorch.amax()does.
Every tensordict class and every tensorclass has this method. For the other methods, see Methods by task.