Implementing kernel
C++ engine symbols that back this Python API.Return the running minimum and indices of input along dim.
Output i along dim is the minimum of elements 0..i and the
index along dim where that running minimum was reached (on ties, the
latest index).
Parameters
inputTensorSource tensor.
dimint= -1Dimension to scan along.
Returns
_ValuesIndices[Tensor]A (values, indices) pair with .values and .indices
attributes.
Notes
The gradient of output i flows to the element that set the running
minimum at step i; differentiable twice.
Examples
>>> import lucid
>>> x = lucid.tensor([1.0, 3.0, 2.0, 4.0])
>>> lucid.cummin(x, dim=0).values
Tensor([1., 1., 1., 1.])