Zadbaj o dobrą organizację dzięki kolekcji Zapisuj i kategoryzuj treści zgodnie ze swoimi preferencjami.

tensorflow :: ops :: SparseApplyProximalGradientDescent

#include <training_ops.h>

Rzadka aktualizacja „* var” jako algorytm FOBOS ze stałą szybkością uczenia się.

streszczenie

To jest dla wierszy, dla których mamy grad, aktualizujemy var w następujący sposób: $$prox_v = var - alpha * grad$$ $$var = sign(prox_v)/(1+alpha*l2) * max{|prox_v|-alpha*l1,0}$$

Argumenty:

  • zakres: obiekt Scope
  • zmienna: powinna pochodzić ze zmiennej ().
  • alpha: współczynnik skalowania. Musi być skalarem.
  • l1: regularyzacja L1. Musi być skalarem.
  • l2: regularyzacja L2. Musi być skalarem.
  • grad: gradient.
  • indeksy: wektor indeksów do pierwszego wymiaru var i accum.

Atrybuty opcjonalne (patrz Attrs ):

  • use_locking: Jeśli True, odejmowanie będzie chronione blokadą; w przeciwnym razie zachowanie jest niezdefiniowane, ale może wykazywać mniej rywalizacji.

Zwroty:

  • Output : to samo, co „var”.

Konstruktorzy i niszczyciele

SparseApplyProximalGradientDescent (const :: tensorflow::Scope & scope, :: tensorflow::Input var, :: tensorflow::Input alpha, :: tensorflow::Input l1, :: tensorflow::Input l2, :: tensorflow::Input grad, :: tensorflow::Input indices)
SparseApplyProximalGradientDescent (const :: tensorflow::Scope & scope, :: tensorflow::Input var, :: tensorflow::Input alpha, :: tensorflow::Input l1, :: tensorflow::Input l2, :: tensorflow::Input grad, :: tensorflow::Input indices, const SparseApplyProximalGradientDescent::Attrs & attrs)

Atrybuty publiczne

operation
out

Funkcje publiczne

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

Publiczne funkcje statyczne

UseLocking (bool x)

Struktury

tensorflow :: ops :: SparseApplyProximalGradientDescent :: Attrs

Opcjonalne metody ustawiające atrybuty dla SparseApplyProximalGradientDescent .

Atrybuty publiczne

operacja

Operation operation

na zewnątrz

::tensorflow::Output out

Funkcje publiczne

SparseApplyProximalGradientDescent

 SparseApplyProximalGradientDescent(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input var,
  ::tensorflow::Input alpha,
  ::tensorflow::Input l1,
  ::tensorflow::Input l2,
  ::tensorflow::Input grad,
  ::tensorflow::Input indices
)

SparseApplyProximalGradientDescent

 SparseApplyProximalGradientDescent(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input var,
  ::tensorflow::Input alpha,
  ::tensorflow::Input l1,
  ::tensorflow::Input l2,
  ::tensorflow::Input grad,
  ::tensorflow::Input indices,
  const SparseApplyProximalGradientDescent::Attrs & attrs
)

węzeł

::tensorflow::Node * node() const 

operator :: tensorflow :: Input

 operator::tensorflow::Input() const 

operator :: tensorflow :: Output

 operator::tensorflow::Output() const 

Publiczne funkcje statyczne

UseLocking

Attrs UseLocking(
  bool x
)