tensorflow:: ops:: איסוף
#include <array_ops.h> איסוף פרוסות params לפי indices .
תַקצִיר
indices חייבים להיות טנזור שלם מכל ממד (בדרך כלל 0-D או 1-D). מייצר טנזור פלט עם צורה indices.shape + params.shape[1:] כאשר:
# Scalar indices
output[:, ..., :] = params[indices, :, ... :]# Vector indices output[i, :, ..., :] = params[indices[i], :, ... :]
# Higher rank indices
output[i, ..., j, :, ... :] = params[indices[i, ..., j], :, ..., :] אם indices הוא תמורה ו- len(indices) == params.shape[0] אז פעולה זו תשנה params בהתאם.
validate_indices : הוצא משימוש. אם פעולה זו מוקצית למעבד, ערכים indices תמיד מאומתים כנמצאים בטווח. אם מוקצים למעבד הגרפי, אינדקסים מחוץ לטווח גורמים להתנהגות בטוחה אך לא מוגדרת, שעשויה לכלול שגיאה.

טיעונים:
- היקף: אובייקט היקף
החזרות:
-
Output: טנזור הפלט.
בנאים והורסים | |
|---|---|
Gather (const :: tensorflow::Scope & scope, :: tensorflow::Input params, :: tensorflow::Input indices) | |
Gather (const :: tensorflow::Scope & scope, :: tensorflow::Input params, :: tensorflow::Input indices, const Gather::Attrs & attrs) |
מאפיינים ציבוריים | |
|---|---|
operation | |
output | |
תפקידים ציבוריים | |
|---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const | |
פונקציות סטטיות ציבוריות | |
|---|---|
ValidateIndices (bool x) | |
מבנים | |
|---|---|
| tensorflow:: ops:: Gather:: Attrs | קובעי מאפיינים אופציונליים עבור Gather . |
מאפיינים ציבוריים
מִבצָע
Operation operation
תְפוּקָה
::tensorflow::Output output
תפקידים ציבוריים
לֶאֱסוֹף
Gather( const ::tensorflow::Scope & scope, ::tensorflow::Input params, ::tensorflow::Input indices )
לֶאֱסוֹף
Gather( const ::tensorflow::Scope & scope, ::tensorflow::Input params, ::tensorflow::Input indices, const Gather::Attrs & attrs )
צוֹמֶת
::tensorflow::Node * node() const
אופרטור::tensorflow::קלט
operator::tensorflow::Input() const
אופרטור::tensorflow::פלט
operator::tensorflow::Output() const
פונקציות סטטיות ציבוריות
אימות מדדים
Attrs ValidateIndices( bool x )
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2026-11-05 (שעון UTC).