টেনসরফ্লো :: অপস:: কামসুম
#include <math_ops.h> axis বরাবর টেনসর x এর ক্রমবর্ধমান সমষ্টি গণনা করুন।
সারাংশ
ডিফল্টরূপে, এই অপটি একটি অন্তর্ভুক্তিমূলক কামসাম সম্পাদন করে, যার অর্থ ইনপুটের প্রথম উপাদানটি আউটপুটের প্রথম উপাদানের সাথে অভিন্ন:
tf.cumsum([a, b, c]) # => [a, a + b, a + b + c]
exclusive কোয়ার্গকে True তে সেট করে, পরিবর্তে একটি এক্সক্লুসিভ কামসাম করা হয়:
tf.cumsum([a, b, c], exclusive=True) # => [0, a, a + b]
reverse কোয়ার্গকে True সেট করে, কামসাম বিপরীত দিকে সঞ্চালিত হয়:
tf.cumsum([a, b, c], reverse=True) # => [a + b + c, b + c, c]
এটি আলাদা tf.reverse ops ব্যবহার করার চেয়ে বেশি কার্যকর।
reverse এবং exclusive কোয়ার্গগুলিও একত্রিত করা যেতে পারে:
tf.cumsum([a, b, c], exclusive=True, reverse=True) # => [b + c, c, 0]
যুক্তি:
- স্কোপ: একটি স্কোপ অবজেক্ট
- x: একটি
Tensor। নিম্নলিখিত প্রকারগুলির মধ্যে একটি হতে হবে:float32,float64,int64,int32,uint8,uint16,int16,int8,complex64,complex128,qint8,quint8,qint32,half৷ - অক্ষ:
int32টাইপের একটিTensor(ডিফল্ট: 0)।[-rank(x), rank(x))পরিসরে হতে হবে।
ঐচ্ছিক বৈশিষ্ট্য (দেখুন Attrs ):
- একচেটিয়া:
Trueহলে, একচেটিয়া কামসাম সম্পাদন করুন। - বিপরীত: একটি
bool(ডিফল্ট: মিথ্যা)।
রিটার্ন:
-
Output: আউট টেনসর।
কনস্ট্রাক্টর এবং ডেস্ট্রাক্টর | |
|---|---|
Cumsum (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input axis) | |
Cumsum (const :: tensorflow::Scope & scope, :: tensorflow::Input x, :: tensorflow::Input axis, const Cumsum::Attrs & attrs) |
পাবলিক বৈশিষ্ট্য | |
|---|---|
operation | |
out | |
পাবলিক ফাংশন | |
|---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const | |
পাবলিক স্ট্যাটিক ফাংশন | |
|---|---|
Exclusive (bool x) | |
Reverse (bool x) | |
কাঠামো | |
|---|---|
| tensorflow:: ops:: Cumsum:: Attrs | কামসামের জন্য ঐচ্ছিক বৈশিষ্ট্য নির্ধারণকারী। |
পাবলিক বৈশিষ্ট্য
অপারেশন
Operation operation
আউট
::tensorflow::Output out
পাবলিক ফাংশন
কামসুম
Cumsum( const ::tensorflow::Scope & scope, ::tensorflow::Input x, ::tensorflow::Input axis )
কামসুম
Cumsum( const ::tensorflow::Scope & scope, ::tensorflow::Input x, ::tensorflow::Input axis, const Cumsum::Attrs & attrs )
নোড
::tensorflow::Node * node() const
অপারেটর::টেনসরফ্লো::ইনপুট
operator::tensorflow::Input() const
অপারেটর::টেনসরফ্লো::আউটপুট
operator::tensorflow::Output() const
পাবলিক স্ট্যাটিক ফাংশন
এক্সক্লুসিভ
Attrs Exclusive( bool x )
বিপরীত
Attrs Reverse( bool x )