R/gen-namespace-docs.R
, R/gen-namespace-examples.R
, R/gen-namespace.R
torch_cummin.Rd
Cummin
torch_cummin(self, dim)
self | (Tensor) the input tensor. |
---|---|
dim | (int) the dimension to do the operation over |
Returns a namedtuple (values, indices)
where values
is the cumulative minimum of
elements of input
in the dimension dim
. And indices
is the index
location of each maximum value found in the dimension dim
.
$$ y_i = min(x_1, x_2, x_3, \dots, x_i) $$
#> [[1]] #> torch_tensor #> -0.8204 #> -0.8204 #> -0.8204 #> -0.8204 #> -0.9557 #> -0.9557 #> -0.9557 #> -0.9557 #> -0.9557 #> -0.9557 #> [ CPUFloatType{10} ] #> #> [[2]] #> torch_tensor #> 0 #> 0 #> 0 #> 0 #> 4 #> 4 #> 4 #> 4 #> 4 #> 4 #> [ CPULongType{10} ] #>