Method argMaxAxis
static member argMaxAxis: int -> Tensor<'T> -> Tensor<int64>
Finds the index of the maximum value along the specified axis.
Declaration
static member argMaxAxis: ax:int -> src:Tensor<'T> -> Tensor<int64>
Parameters
Type | Name | Description |
---|---|---|
int | ax | The axis to calculate the maximum along. |
Tensor<'T> | src | The tensor containing the source values. |
Returns
Type | Description |
---|---|
Tensor<int64> | A new tensor containing the result of this operation. |
Remarks
The index of the maximum is calculated along the specified axis. An empty tensor gives val NotFound.
Examples
let a = HostTensor.ofList2D [[1.0; 2.0; 3.0; 4.0]
[5.0; 6.0; 7.0; 8.0]]
let b = Tensor.argMaxAxis 1 a // b = [3L; 3L]