tensorflow:: ops:: ArgMax

#include <math_ops.h>

テンソルの各次元において、最も大きな値を持つインデックスを返します。

まとめ

なお、同点の場合は、戻り値の同一性は保証されません。

使用法:

  import tensorflow as tf
  a = [1, 10, 26.9, 2.8, 166.32, 62.3]
  b = tf.math.argmax(input = a)
  c = tf.keras.backend.eval(b)
  # c = 4
  # here a[4] = 166.32 which is the largest element of a across axis 0
  

議論:

  • スコープ:スコープオブジェクト
  • dimension: int32 または int64、範囲は[-rank(input), rank(input))である必要があります。入力テンソルのどの次元で削減するかを示します。ベクトルの場合は dimension = 0 を使用します。

返品:

  • Output :出力テンソル。

コンストラクターとデストラクタ

ArgMax (const :: tensorflow::Scope & scope, :: tensorflow::Input input, :: tensorflow::Input dimension)
ArgMax (const :: tensorflow::Scope & scope, :: tensorflow::Input input, :: tensorflow::Input dimension, const ArgMax::Attrs & attrs)

公開属性

operation
output

公的機能

node () const
::tensorflow::Node *
operator::tensorflow::Input () const
operator::tensorflow::Output () const

パブリック静的関数

OutputType (DataType x)

構造

tensorflow:: ops:: ArgMax:: Attrs

ArgMaxのオプション属性セッター。

公開属性

手術

Operation operation

出力

::tensorflow::Output output

公的機能

ArgMax

 ArgMax(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input input,
  ::tensorflow::Input dimension
)

ArgMax

 ArgMax(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input input,
  ::tensorflow::Input dimension,
  const ArgMax::Attrs & attrs
)

ノード

::tensorflow::Node * node() const 

operator::tensorflow::Input

 operator::tensorflow::Input() const 

operator::tensorflow::Output

 operator::tensorflow::Output() const 

パブリック静的関数

出力タイプ

Attrs OutputType(
  DataType x
)