جریان تنسور:: عملیات:: StringToNumber
#include <parsing_ops.h>
هر رشته در تانسور ورودی را به نوع عددی مشخص شده تبدیل می کند.
خلاصه
(توجه داشته باشید که سرریز int32 منجر به خطا می شود در حالی که سرریز float منجر به یک مقدار گرد می شود.)
مثال:
strings = ["5.0"، "3.0"، "7.0"] tf.strings.to_number(strings)
استدلال ها:
- scope: یک شی Scope
ویژگی های اختیاری (به Attrs
مراجعه کنید):
- out_type: نوع عددی برای تفسیر هر رشته در
string_tensor
به صورت.
برمیگرداند:
سازندگان و ویرانگرها | |
---|---|
StringToNumber (const :: tensorflow::Scope & scope, :: tensorflow::Input string_tensor) | |
StringToNumber (const :: tensorflow::Scope & scope, :: tensorflow::Input string_tensor, const StringToNumber::Attrs & attrs) |
توابع عمومی | |
---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const |
سازه ها | |
---|---|
tensorflow:: ops:: StringToNumber:: Attrs | تنظیم کننده های ویژگی اختیاری برای StringToNumber . |
صفات عمومی
عملیات
Operation operation
خروجی
::tensorflow::Output output
توابع عمومی
StringToNumber
StringToNumber( const ::tensorflow::Scope & scope, ::tensorflow::Input string_tensor )
StringToNumber
StringToNumber( const ::tensorflow::Scope & scope, ::tensorflow::Input string_tensor, const StringToNumber::Attrs & attrs )
گره
::tensorflow::Node * node() const
عملگر::tensorflow::ورودی
operator::tensorflow::Input() const
عملگر::tensorflow::خروجی
operator::tensorflow::Output() const
توابع استاتیک عمومی
OutType
Attrs OutType( DataType x )