tensorflow:: ops:: MatrixBandPart
#include <array_ops.h>প্রতিটি সবচেয়ে ভেতরের ম্যাট্রিক্সের কেন্দ্রীয় ব্যান্ডের বাইরের সবকিছু একটি টেনসর সেটিং হিসেবে কপি করুন।
সারসংক্ষেপ
শূন্যে।
band অংশটি নিম্নরূপে গণনা করা হয়: ধরা যাক input k মাত্রা [I, J, K, ..., M, N] , তাহলে আউটপুটটি একই আকৃতির একটি টেনসর হবে যেখানে
band[i, j, k, ..., m, n] = in_band(m, n) * input[i, j, k, ..., m, n] .
সূচক ফাংশন
in_band(m, n) = (num_lower < 0 || (mn) <= num_lower)) && (num_upper < 0 || (nm) <= num_upper) .
উদাহরণস্বরূপ:
# if 'input' is [[ 0, 1, 2, 3]
[-1, 0, 1, 2]
[-2, -1, 0, 1]
[-3, -2, -1, 0]],tf.matrix_band_part(input, 1, -1) ==> [[ 0, 1, 2, 3]
[-1, 0, 1, 2]
[ 0, -1, 0, 1]
[ 0, 0, -1, 0]],tf.matrix_band_part(input, 2, 1) ==> [[ 0, 1, 0, 0]
[-1, 0, 1, 0]
[-2, -1, 0, 1]
[ 0, -2, -1, 0]]দরকারি বিশেষ ক্ষেত্রসমূহ:
tf.matrix_band_part(input, 0, -1) ==> Upper triangular part. tf.matrix_band_part(input, -1, 0) ==> Lower triangular part. tf.matrix_band_part(input, 0, 0) ==> Diagonal.
যুক্তি:
- স্কোপ: একটি স্কোপ অবজেক্ট
- ইনপুট: র্যাঙ্ক
kটেনসর। - num_lower: ০-মাত্রিক টেনসর। কতগুলো উপ-কর্ণ রাখা হবে। ঋণাত্মক হলে, সম্পূর্ণ নিম্ন ত্রিভুজটি রাখা হবে।
- num_upper: ০-মাত্রিক টেনসর। কতগুলো সুপারডায়াগোনাল রাখা হবে। ঋণাত্মক হলে, সম্পূর্ণ উপরের ত্রিভুজটি রাখা হবে।
ফেরত:
-
Output: ইনপুটের অনুরূপ আকৃতির র্যাঙ্কkটেনসর। নিষ্কাশিত ব্যান্ডেড টেনসর।
নির্মাতা এবং ধ্বংসকারী | |
|---|---|
MatrixBandPart (const :: tensorflow::Scope & scope, :: tensorflow::Input input, :: tensorflow::Input num_lower, :: tensorflow::Input num_upper) |
জনসাধারণের বৈশিষ্ট্য | |
|---|---|
band | |
operation | |
জনসাধারণের কার্যাবলী | |
|---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const | |
জনসাধারণের বৈশিষ্ট্য
ব্যান্ড
::tensorflow::Output band
অপারেশন
Operation operation
জনসাধারণের কার্যাবলী
ম্যাট্রিক্সব্যান্ডপার্ট
MatrixBandPart( const ::tensorflow::Scope & scope, ::tensorflow::Input input, ::tensorflow::Input num_lower, ::tensorflow::Input num_upper )
নোড
::tensorflow::Node * node() const
অপারেটর::টেনসরফ্লো::ইনপুট
operator::tensorflow::Input() const
অপারেটর::টেনসরফ্লো::আউটপুট
operator::tensorflow::Output() const