tensorflow:: ops:: BroadcastTo

#include <array_ops.h>

قم ببث مصفوفة لشكل متوافق.

ملخص

البث هو عملية إنشاء مصفوفات ذات أشكال متوافقة لإجراء العمليات الحسابية. يكون شكلان متوافقين إذا كان كل زوج من أبعادهما متساويًا أو كان أحدهما يساوي واحدًا. عند محاولة بث موتر إلى شكل، يبدأ البث بالأبعاد الأخيرة، ثم ينتقل تدريجيًا إلى الأمام.

على سبيل المثال،

>>> x = tf.constant([1, 2, 3])
>>> y = tf.broadcast_to(x, [3, 3])
>>> sess.run(y)
array([[1, 2, 3],
       [1, 2, 3],
       [1, 2, 3]], dtype=int32)

في المثال أعلاه، يتم بث موتر الإدخال ذو الشكل [1, 3] إلى موتر الإخراج ذو الشكل [3, 3] .

الحجج:

المرتجعات:

البناة والمدمرون

BroadcastTo (const :: tensorflow::Scope & scope, :: tensorflow::Input input, :: tensorflow::Input shape)

السمات العامة

operation
output

الوظائف العامة

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

السمات العامة

عملية

Operation operation

المخرجات

::tensorflow::Output output

الوظائف العامة

بث إلى

 BroadcastTo(
  const ::tensorflow::Scope & scope,
  ::tensorflow::Input input,
  ::tensorflow::Input shape
)

العقدة

::tensorflow::Node * node() const 

operator::tensorflow::Input

 operator::tensorflow::Input() const 

operator::tensorflow::Output

 operator::tensorflow::Output() const