tensorflow:: אופס:: פיזור עדכון

#include <state_ops.h>

מחיל עדכונים דלילים על הפניה למשתנה.

סיכום

פעולה זו מחשבת

    # Scalar indices
    ref[indices, ...] = updates[...]

    # Vector indices (for each i)
    ref[indices[i], ...] = updates[i, ...]

    # High rank indices (for each i, ..., j)
    ref[indices[i, ..., j], ...] = updates[i, ..., j, ...]

פעולה זו מוציאה ref לאחר ביצוע העדכון. זה מקל על שרשרת פעולות שצריכות להשתמש בערך האיפוס.

אם יש לעדכן ערכים ב- ref יותר מפעם אחת, מכיוון שישנן ערכים כפולים indices , הסדר שבו העדכונים מתרחשים עבור כל ערך אינו מוגדר.

דורש updates.shape = indices.shape + ref.shape[1:] או updates.shape = [] .

ראה גם tf.batch_scatter_update ו- tf.scatter_nd_update .

טיעונים:

  • scope: אובייקט Scope
  • ref: צריך להיות מצומת Variable .
  • מדדים: טנסור של מדדים לממד הראשון של ref .
  • עדכונים: טנסור של ערכים מעודכנים לאחסון ב- ref .

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

  • use_locking: אם נכון, ההקצאה תהיה מוגנת על ידי מנעול; אחרת ההתנהגות אינה מוגדרת, אך עלולה להפגין פחות מחלוקת.

החזרות:

  • Output : = זהה ל- ref . הוחזר כנוחות עבור פעולות שרוצות להשתמש בערכים המעודכנים לאחר ביצוע העדכון.

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

ScatterUpdate (const :: tensorflow::Scope & scope, :: tensorflow::Input ref, :: tensorflow::Input indices, :: tensorflow::Input updates)
ScatterUpdate (const :: tensorflow::Scope & scope, :: tensorflow::Input ref, :: tensorflow::Input indices, :: tensorflow::Input updates, const ScatterUpdate::Attrs & attrs)

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

operation
output_ref

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

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

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

UseLocking (bool x)

מבנים

tensorflow:: ops:: ScatterUpdate:: Attrs

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

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

מבצע

Operation operation

פלט_ref

::tensorflow::Output output_ref

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

פיזור עדכון

 ScatterUpdate(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input ref,
  ::tensorflow::Input indices,
  ::tensorflow::Input updates
)

פיזור עדכון

 ScatterUpdate(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input ref,
  ::tensorflow::Input indices,
  ::tensorflow::Input updates,
  const ScatterUpdate::Attrs & attrs
)

צוֹמֶת

::tensorflow::Node * node() const 

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

 operator::tensorflow::Input() const 

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

 operator::tensorflow::Output() const 

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

השתמש בנעילה

Attrs UseLocking(
  bool x
)