tensorflow::ops::ScatterDiv

#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 หลังจากการอัปเดตเสร็จสิ้น ซึ่งจะช่วยให้การเชื่อมโยงการดำเนินการที่ต้องใช้ค่ารีเซ็ตทำได้ง่ายขึ้น

ระบบจะจัดการกับรายการที่ซ้ำกันอย่างถูกต้อง: หาก indices หลายรายการอ้างอิงถึงตำแหน่งเดียวกัน การมีส่วนร่วมของดัชนีเหล่านั้นจะถูกแบ่งออก

ต้องใช้ updates.shape = indices.shape + ref.shape[1:] หรือ updates.shape = []

ข้อโต้แย้ง:

  • ขอบเขต: วัตถุ ขอบเขต
  • อ้างอิง: ควรมาจากโหนด Variable
  • ดัชนี: เทนเซอร์ของดัชนีในมิติแรกของ ref
  • อัปเดต: เทนเซอร์ของค่าที่ใช้หาร ref

คุณลักษณะเสริม (ดูที่ Attrs ):

  • use_locking: หากเป็น True การดำเนินการจะได้รับการปกป้องด้วยการล็อก มิเช่นนั้นพฤติกรรมจะไม่แน่นอน แต่การแย่งชิงทรัพยากรอาจน้อยลง

การส่งคืนสินค้า:

  • Output : = เหมือนกับ ref ส่งคืนเพื่อความสะดวกในการดำเนินการที่ต้องการใช้ค่าที่อัปเดตแล้วหลังจากทำการอัปเดตเสร็จสิ้น

ตัวสร้างและตัวทำลาย

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

คุณลักษณะสาธารณะ

operation
output_ref

หน้าที่สาธารณะ

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

ฟังก์ชันคงที่สาธารณะ

UseLocking (bool x)

โครงสร้าง

tensorflow::ops::ScatterDiv::Attrs

ตัวเลือกในการตั้งค่าแอตทริบิวต์สำหรับ ScatterDiv

คุณลักษณะสาธารณะ

การดำเนินการ

Operation operation

เอาต์พุต_อ้างอิง

::tensorflow::Output output_ref

หน้าที่สาธารณะ

กระจายดิวิชั่น

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

กระจายดิวิชั่น

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

โหนด

::tensorflow::Node * node() const 

ตัวดำเนินการ::เทนเซอร์โฟลว์::อินพุต

 operator::tensorflow::Input() const 

ตัวดำเนินการ::เทนเซอร์โฟลว์::เอาต์พุต

 operator::tensorflow::Output() const 

ฟังก์ชันคงที่สาธารณะ

ใช้การล็อก

Attrs UseLocking(
  bool x
)