tensoreflusso:: ops:: Cumprod

#include <math_ops.h>

Calcola il prodotto cumulativo del tensore x lungo axis .

Riepilogo

Per impostazione predefinita, questa operazione esegue un cumprod inclusivo, il che significa che il primo elemento dell'input è identico al primo elemento dell'output:

tf.cumprod([a, b, c])  # => [a, a * b, a * b * c]

Impostando kwarg exclusive su True , viene invece eseguito un cumprod esclusivo:

tf.cumprod([a, b, c], exclusive=True)  # => [1, a, a * b]

Impostando il kwarg reverse su True , il cumprod viene eseguito nella direzione opposta:

tf.cumprod([a, b, c], reverse=True)  # => [a * b * c, b * c, c]

Questo è più efficiente rispetto all'utilizzo di operazioni tf.reverse separate.

I kwarg reverse ed exclusive possono anche essere combinati:

tf.cumprod([a, b, c], exclusive=True, reverse=True)  # => [b * c, c, 1]

Argomenti:

  • scope: un oggetto Scope
  • x: un Tensor . Deve essere uno dei seguenti tipi: float32 , float64 , int64 , int32 , uint8 , uint16 , int16 , int8 , complex64 , complex128 , qint8 , quint8 , qint32 , half .
  • asse: un Tensor di tipo int32 (impostazione predefinita: 0). Deve essere compreso nell'intervallo [-rank(x), rank(x)) .

Attributi facoltativi (vedi Attrs ):

  • esclusivo: Se True , esegue cumprod esclusivo.
  • reverse: A bool (default: False).

Ritorna:

Costruttori e distruttori

Cumprod (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input axis)
Cumprod (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input axis, const Cumprod::Attrs & attrs)

Attributi pubblici

operation
out

Funzioni pubbliche

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

Funzioni pubbliche statiche

Exclusive (bool x)
Reverse (bool x)

Strutture

tensorflow:: ops:: Cumprod:: Attrs

Setter di attributi facoltativi per Cumprod .

Attributi pubblici

operazione

Operation operation

fuori

::tensorflow::Output out

Funzioni pubbliche

Cumprod

 Cumprod(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input x,
  ::tensorflow::Input axis
)

Cumprod

 Cumprod(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input x,
  ::tensorflow::Input axis,
  const Cumprod::Attrs & attrs
)

nodo

::tensorflow::Node * node() const 

operatore::tensorflow::Input

 operator::tensorflow::Input() const 

operatore::tensorflow::Output

 operator::tensorflow::Output() const 

Funzioni pubbliche statiche

Esclusivo

Attrs Exclusive(
  bool x
)

Inversione

Attrs Reverse(
  bool x
)