Tensorflow :: ops :: ArgMax
#include <math_ops.h>
Gibt den Index mit dem größten Wert über die Dimensionen eines Tensors zurück.
Zusammenfassung
Beachten Sie, dass bei Bindungen die Identität des Rückgabewerts nicht garantiert wird.
Verwendung:
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
Argumente:
- scope: Ein Scope- Objekt
- Dimension: int32 oder int64, muss im Bereich
[-rank(input), rank(input))
. Beschreibt , welche Dimension des Eingangs Tensor zu reduzieren über. Verwenden Sie für Vektoren dimension = 0.
Kehrt zurück:
-
Output
: Der Ausgangstensor.
Konstruktoren und Destruktoren | |
---|---|
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) |
Öffentliche Attribute | |
---|---|
operation | |
output |
Öffentliche Funktionen | |
---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const |
Öffentliche statische Funktionen | |
---|---|
OutputType (DataType x) |
Strukturen | |
---|---|
tensorflow :: ops :: ArgMax :: Attrs | Optionale Attributsetzer für ArgMax . |
Öffentliche Attribute
Operation
Operation operation
Ausgabe
::tensorflow::Output output
Öffentliche Funktionen
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 )
Knoten
::tensorflow::Node * node() const
operator :: tensorflow :: Input
operator::tensorflow::Input() const
operator :: tensorflow :: Output
operator::tensorflow::Output() const
Öffentliche statische Funktionen
Ausgabetyp
Attrs OutputType( DataType x )