tensorflow::ops::SparseBincount
#include <math_ops.h>Conta il numero di occorrenze di ciascun valore in un array di interi.
Riepilogo
Restituisce un vettore di lunghezza size e dello stesso tipo di dati di weights . Se weights è vuoto, l'indice i memorizza il numero di volte in cui il valore i viene contato in arr . Se weights non è vuoto, l'indice i memorizza la somma dei valori in weights in ciascun indice in cui il valore corrispondente in arr è i .
I valori in arr al di fuori dell'intervallo [0, size) vengono ignorati.
Argomentazioni:
- ambito: un oggetto Scope
- indici:
Tensor2D int64. - valori:
Tensorintero 1D. - dense_shape:
Tensorint64 1D. - dimensione:
Tensorscalare intero non negativo. - pesi: è un
Tensorint32, int64, float32 o float64 con la stessa forma diinput, oppure unTensordi lunghezza 0, nel qual caso agisce come se tutti i pesi fossero uguali a 1.
Attributi opzionali (vedere Attrs ):
- binary_output: bool; Indica se il kernel deve contare la presenza o il numero di occorrenze.
Resi:
-
Output:Tensor1D con lunghezza pari asizeoTensor2D con [batch_size,size]. I conteggi o i pesi sommati per ciascun valore nell'intervallo [0, size).
Costruttori e distruttori | |
|---|---|
SparseBincount (const :: tensorflow::Scope & scope, :: tensorflow::Input indices, :: tensorflow::Input values, :: tensorflow::Input dense_shape, :: tensorflow::Input size, :: tensorflow::Input weights) | |
SparseBincount (const :: tensorflow::Scope & scope, :: tensorflow::Input indices, :: tensorflow::Input values, :: tensorflow::Input dense_shape, :: tensorflow::Input size, :: tensorflow::Input weights, const SparseBincount::Attrs & attrs) |
attributi pubblici | |
|---|---|
operation | |
output | |
Funzioni pubbliche | |
|---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const | |
Funzioni statiche pubbliche | |
|---|---|
BinaryOutput (bool x) | |
Strutture | |
|---|---|
| tensorflow::ops::SparseBincount::Attrs | Impostatori di attributi opzionali per SparseBincount . |
attributi pubblici
operazione
Operation operation
produzione
::tensorflow::Output output
Funzioni pubbliche
SparseBincount
SparseBincount( const ::tensorflow::Scope & scope, ::tensorflow::Input indices, ::tensorflow::Input values, ::tensorflow::Input dense_shape, ::tensorflow::Input size, ::tensorflow::Input weights )
SparseBincount
SparseBincount( const ::tensorflow::Scope & scope, ::tensorflow::Input indices, ::tensorflow::Input values, ::tensorflow::Input dense_shape, ::tensorflow::Input size, ::tensorflow::Input weights, const SparseBincount::Attrs & attrs )
nodo
::tensorflow::Node * node() const
operatore::tensorflow::Input
operator::tensorflow::Input() const
operatore::tensoreflusso::output
operator::tensorflow::Output() const
Funzioni statiche pubbliche
Uscita binaria
Attrs BinaryOutput( bool x )