• Returns the indices of the minimum values along an axis.

    The result has the same shape as input with the dimension along axis removed.

    const x = tf.tensor1d([1, 2, 3]);

    x.argMin().print(); // or tf.argMin(x)
    const x = tf.tensor2d([1, 2, 4, 3], [2, 2]);

    const axis = 1;
    x.argMin(axis).print(); // or tf.argMin(x, axis)

    Type Parameters

    Parameters

    • x: Tensor<Rank> | TensorLike

      The input tensor.

    • Optional axis: number

      The dimension to reduce. Defaults to 0 (outer-most dimension).

    Returns T

    Doc

Generated using TypeDoc