argmax - Maple Help

Online Help

All Products    Maple    MapleSim


DeepLearning,Tensor,argmax

find index with maximal value over entries of a Tensor

DeepLearning,Tensor,argmin

find index with minimal value over entries of a Tensor

 

Calling Sequence

Parameters

Options

Description

Examples

Compatibility

Calling Sequence

argmax(t,opts)

argmin(t,opts)

Parameters

t

-

Tensor

opts

-

options, as specified below

Options

• 

axis=list(integer) or integer

The value of option axis is an integer or list of integers which describes which axis of the input Tensor to reduce across.

• 

datatype=integer[4] or integer[8]

The value of option datatype specifies the type of data this Tensor will hold. The default is integer[8].

• 

name=string

The value of option name specifies an optional name for this Tensor, to be displayed in output and when visualizing the dataflow graph.

Description

• 

The argmax(t) command returns the index with the largest value across the axes of a Tensor.

• 

The argmin(t) command behaves similarly but returns the index with the smallest value across the axes of a Tensor.

• 

The index returns by argmax and argmin is zero-based.

Examples

withDeepLearning:

tConstant0,7,2,9,3,6,8:

argmaxt,axis=0

DeepLearning TensorName: noneShape: []Data Type: integer[8]

(1)

argmint,axis=0

DeepLearning TensorName: noneShape: []Data Type: integer[8]

(2)

Compatibility

• 

The DeepLearning,Tensor,argmax and DeepLearning,Tensor,argmin commands were introduced in Maple 2018.

• 

For more information on Maple 2018 changes, see Updates in Maple 2018.

See Also

DeepLearning Overview

Tensor