tensorflow:: אופס:: ApplyFtrl

#include <training_ops.h>

עדכן את '*var' לפי סכימת Ftrl-proximal.

סיכום

accum_new = accum + grad * grad linear += grad - (accum_new^(-lr_power) - accum^(-lr_power)) / lr * var quadratic = 1.0 / (accum_new^(lr_power) * lr) + 2 * l2 var = (סימן(ליניארי) * l1 - ליניארי) / ריבועי אם |ליניארי| > l1 אחר 0.0 accum = accum_new

טיעונים:

  • scope: אובייקט Scope
  • var: צריך להיות מ-Variable().
  • acum: צריך להיות מ-Variable().
  • ליניארי: צריך להיות ממשתנה().
  • grad: השיפוע.
  • lr: גורם קנה מידה. חייב להיות סקלר.
  • l1: הסדרת L1. חייב להיות סקלר.
  • l2: הסדרת L2. חייב להיות סקלר.
  • lr_power: גורם קנה מידה. חייב להיות סקלר.

מאפיינים אופציונליים (ראה Attrs ):

  • use_locking: אם True , עדכון של טנסור ה-var ו-acum יהיה מוגן על ידי מנעול; אחרת ההתנהגות אינה מוגדרת, אך עלולה להפגין פחות מחלוקת.

החזרות:

בנאים והורסים

ApplyFtrl (const :: tensorflow::Scope & scope, :: tensorflow::Input var, :: tensorflow::Input accum, :: tensorflow::Input linear, :: tensorflow::Input grad, :: tensorflow::Input lr, :: tensorflow::Input l1, :: tensorflow::Input l2, :: tensorflow::Input lr_power)
ApplyFtrl (const :: tensorflow::Scope & scope, :: tensorflow::Input var, :: tensorflow::Input accum, :: tensorflow::Input linear, :: tensorflow::Input grad, :: tensorflow::Input lr, :: tensorflow::Input l1, :: tensorflow::Input l2, :: tensorflow::Input lr_power, const ApplyFtrl::Attrs & attrs)

תכונות ציבוריות

operation
out

תפקידים ציבוריים

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

פונקציות סטטיות ציבוריות

MultiplyLinearByLr (bool x)
UseLocking (bool x)

מבנים

tensorflow:: ops:: ApplyFtrl:: Attrs

קובעי תכונות אופציונליים עבור ApplyFtrl .

תכונות ציבוריות

מבצע

Operation operation

הַחוּצָה

::tensorflow::Output out

תפקידים ציבוריים

ApplyFtrl

 ApplyFtrl(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input var,
  ::tensorflow::Input accum,
  ::tensorflow::Input linear,
  ::tensorflow::Input grad,
  ::tensorflow::Input lr,
  ::tensorflow::Input l1,
  ::tensorflow::Input l2,
  ::tensorflow::Input lr_power
)

ApplyFtrl

 ApplyFtrl(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input var,
  ::tensorflow::Input accum,
  ::tensorflow::Input linear,
  ::tensorflow::Input grad,
  ::tensorflow::Input lr,
  ::tensorflow::Input l1,
  ::tensorflow::Input l2,
  ::tensorflow::Input lr_power,
  const ApplyFtrl::Attrs & attrs
)

צוֹמֶת

::tensorflow::Node * node() const 

מפעיל::tensorflow::קלט

 operator::tensorflow::Input() const 

אופרטור::tensorflow::פלט

 operator::tensorflow::Output() const 

פונקציות סטטיות ציבוריות

MultiplyLinearByLr

Attrs MultiplyLinearByLr(
  bool x
)

השתמש בנעילה

Attrs UseLocking(
  bool x
)