tensorflow:: ops:: Sign
#include <math_ops.h>Restituisce un'indicazione, elemento per elemento, del segno di un numero.
Riepilogo
y = sign(x) = -1 se x < 0 ; 0 se x == 0 ; 1 se x > 0 .
Per i numeri complessi, y = sign(x) = x / |x| se x != 0 , altrimenti y = 0 .
Esempio di utilizzo: tf.math.sign([0., 2., -3.])
Argomentazioni:
- ambito: un oggetto Scope
Resi:
-
Output: Il tensore y.
Costruttori e distruttori | |
|---|---|
Sign (const :: tensorflow::Scope & scope, :: tensorflow::Input x) |
attributi pubblici | |
|---|---|
operation | |
y | |
Funzioni pubbliche | |
|---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const | |
attributi pubblici
operazione
Operation operation
y
::tensorflow::Output y
Funzioni pubbliche
Cartello
Sign( const ::tensorflow::Scope & scope, ::tensorflow::Input x )
nodo
::tensorflow::Node * node() const
operatore::tensorflow::Input
operator::tensorflow::Input() const
operatore::tensoreflusso::output
operator::tensorflow::Output() const