ClikaRT::ops::argmin
function
argmin()
Tensor argmin(
Tensor x,
ClikaRT::Span<const std::int64_t> dims = {},
bool keepdim = false,
DataType index_dtype = DataType::Int64
)
Index of the minimum of x over dims.
Empty dims reduces every dimension (the index is then into the flattened tensor). The index dtype is Int64 by default; Int32 narrows it (an Int32 index addresses a reduced extent of at most INT32_MAX elements).
Parameters
x: the input tensor.dims: axes to reduce; empty = all axes.keepdim: keep reduced axes as size-1 dims; default false.index_dtype:DataType::Int64(default) orDataType::Int32.
Returns: indices of the minima in index_dtype; shape = x minus dims.
Throws
ClikaRT::Error: (INVALID_ARGUMENT) on an out-of-rangedimsentry, anindex_dtypeother than Int64 / Int32, or an Int32 index over a reduced extent past INT32_MAX elements.
Declared in ClikaRT/compute/ops.h, line 4246