Compute the minimum and maximum of input.
Parameters
inputTensorInput tensor.
dimint or NoneDimension along which to compute minimum and maximum. When
None
(default), reduces over the entire tensor.keepdimboolIf
True, retains the reduced dimensions with size 1.Returns
Examples
>>> import lucid
>>> out = lucid.aminmax(lucid.tensor([3.0, -1.0, 4.0]))
>>> (out.min.item(), out.max.item())
(-1.0, 4.0)