جریان تنسور:: عملیات:: StringFormat
#include <string_ops.h>
قالب رشته ای را با استفاده از لیستی از تانسورها قالب بندی می کند.
خلاصه
قالب رشته ای را با استفاده از فهرستی از تانسورها، خلاصه های تانسور زیبا، قالب بندی می کند.
استدلال ها:
- scope: یک شی Scope
- ورودی ها: لیستی از تانسورها برای قالب بندی در رشته محل نگهدار.
ویژگی های اختیاری (به Attrs
مراجعه کنید):
- template_: رشته ای، قالبی که خلاصه های تانسور را در آن قالب بندی می کند.
- placeholder: یک رشته، در هر مکان نگهدار در الگو، یک خلاصه تانسور بعدی درج خواهد شد.
- خلاصه کردن: هنگام قالببندی خلاصههای تانسور، اولین و آخرین ورودیهای خلاصه هر بعد تانسور را چاپ کنید.
برمیگرداند:
-
Output
: = اسکالر رشته حاصل.
سازندگان و ویرانگرها | |
---|---|
StringFormat (const :: tensorflow::Scope & scope, :: tensorflow::InputList inputs) | |
StringFormat (const :: tensorflow::Scope & scope, :: tensorflow::InputList inputs, const StringFormat::Attrs & attrs) |
صفات عمومی | |
---|---|
operation | |
output |
توابع عمومی | |
---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const |
توابع استاتیک عمومی | |
---|---|
Placeholder (StringPiece x) | |
Summarize (int64 x) | |
Template (StringPiece x) |
سازه ها | |
---|---|
tensorflow:: ops:: StringFormat:: Attrs | تنظیم کننده های ویژگی اختیاری برای StringFormat . |
صفات عمومی
عملیات
Operation operation
خروجی
::tensorflow::Output output
توابع عمومی
StringFormat
StringFormat( const ::tensorflow::Scope & scope, ::tensorflow::InputList inputs )
StringFormat
StringFormat( const ::tensorflow::Scope & scope, ::tensorflow::InputList inputs, const StringFormat::Attrs & attrs )
گره
::tensorflow::Node * node() const
عملگر::tensorflow::ورودی
operator::tensorflow::Input() const
عملگر::tensorflow::خروجی
operator::tensorflow::Output() const
توابع استاتیک عمومی
مکان نگهدار
Attrs Placeholder( StringPiece x )
خلاصه کنید
Attrs Summarize( int64 x )
الگو
Attrs Template( StringPiece x )
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-07-25 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-07-25 بهوقت ساعت هماهنگ جهانی."],[],[],null,["# tensorflow::ops::StringFormat Class Reference\n\ntensorflow::ops::StringFormat\n=============================\n\n`#include \u003cstring_ops.h\u003e`\n\nFormats a string template using a list of tensors.\n\nSummary\n-------\n\nFormats a string template using a list of tensors, pretty-printing tensor summaries.\n\nArguments:\n\n- scope: A [Scope](/versions/r2.1/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope) object\n- inputs: The list of tensors to format into the placeholder string.\n\n\u003cbr /\u003e\n\nOptional attributes (see [Attrs](/versions/r2.1/api_docs/cc/struct/tensorflow/ops/string-format/attrs#structtensorflow_1_1ops_1_1_string_format_1_1_attrs)):\n\n- template_: A string, the template to format tensor summaries into.\n- placeholder: A string, at each placeholder in the template a subsequent tensor summary will be inserted.\n- summarize: When formatting the tensor summaries print the first and last summarize entries of each tensor dimension.\n\n\u003cbr /\u003e\n\nReturns:\n\n- [Output](/versions/r2.1/api_docs/cc/class/tensorflow/output#classtensorflow_1_1_output): = The resulting string scalar.\n\n\u003cbr /\u003e\n\n| ### Constructors and Destructors ||\n|---|---|\n| [StringFormat](#classtensorflow_1_1ops_1_1_string_format_1a2a49e6e78ef8bc53f1c131f57472c80f)`(const ::`[tensorflow::Scope](/versions/r2.1/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope)` & scope, ::`[tensorflow::InputList](/versions/r2.1/api_docs/cc/class/tensorflow/input-list#classtensorflow_1_1_input_list)` inputs)` ||\n| [StringFormat](#classtensorflow_1_1ops_1_1_string_format_1aa206a8f6062c185cd4054ea9c3eae135)`(const ::`[tensorflow::Scope](/versions/r2.1/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope)` & scope, ::`[tensorflow::InputList](/versions/r2.1/api_docs/cc/class/tensorflow/input-list#classtensorflow_1_1_input_list)` inputs, const `[StringFormat::Attrs](/versions/r2.1/api_docs/cc/struct/tensorflow/ops/string-format/attrs#structtensorflow_1_1ops_1_1_string_format_1_1_attrs)` & attrs)` ||\n\n| ### Public attributes ||\n|-------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------|\n| [operation](#classtensorflow_1_1ops_1_1_string_format_1a79b84b00b14555109e9d022ed1d18247) | [Operation](/versions/r2.1/api_docs/cc/class/tensorflow/operation#classtensorflow_1_1_operation) |\n| [output](#classtensorflow_1_1ops_1_1_string_format_1ad804e61daa8ee29a7589034620bc6957) | `::`[tensorflow::Output](/versions/r2.1/api_docs/cc/class/tensorflow/output#classtensorflow_1_1_output) |\n\n| ### Public functions ||\n|-------------------------------------------------------------------------------------------------------------------------|------------------------|\n| [node](#classtensorflow_1_1ops_1_1_string_format_1a17f33c98eb82880a699b4fd280414866)`() const ` | `::tensorflow::Node *` |\n| [operator::tensorflow::Input](#classtensorflow_1_1ops_1_1_string_format_1a18c365d68dd132b199860fd218352055)`() const ` | ` ` ` ` |\n| [operator::tensorflow::Output](#classtensorflow_1_1ops_1_1_string_format_1a09f95b504d354326ed3bf116fefce058)`() const ` | ` ` ` ` |\n\n| ### Public static functions ||\n|--------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------|\n| [Placeholder](#classtensorflow_1_1ops_1_1_string_format_1a5bbe893329638ba81c31a259ff88b059)`(StringPiece x)` | [Attrs](/versions/r2.1/api_docs/cc/struct/tensorflow/ops/string-format/attrs#structtensorflow_1_1ops_1_1_string_format_1_1_attrs) |\n| [Summarize](#classtensorflow_1_1ops_1_1_string_format_1af1d26efd4527e1af585402a951364b86)`(int64 x)` | [Attrs](/versions/r2.1/api_docs/cc/struct/tensorflow/ops/string-format/attrs#structtensorflow_1_1ops_1_1_string_format_1_1_attrs) |\n| [Template](#classtensorflow_1_1ops_1_1_string_format_1ac90801110cd85e5c9cdee2b025a7284b)`(StringPiece x)` | [Attrs](/versions/r2.1/api_docs/cc/struct/tensorflow/ops/string-format/attrs#structtensorflow_1_1ops_1_1_string_format_1_1_attrs) |\n\n| ### Structs ||\n|--------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------|\n| [tensorflow::ops::StringFormat::Attrs](/versions/r2.1/api_docs/cc/struct/tensorflow/ops/string-format/attrs) | Optional attribute setters for [StringFormat](/versions/r2.1/api_docs/cc/class/tensorflow/ops/string-format#classtensorflow_1_1ops_1_1_string_format). |\n\nPublic attributes\n-----------------\n\n### operation\n\n```text\nOperation operation\n``` \n\n### output\n\n```text\n::tensorflow::Output output\n``` \n\nPublic functions\n----------------\n\n### StringFormat\n\n```gdscript\n StringFormat(\n const ::tensorflow::Scope & scope,\n ::tensorflow::InputList inputs\n)\n``` \n\n### StringFormat\n\n```gdscript\n StringFormat(\n const ::tensorflow::Scope & scope,\n ::tensorflow::InputList inputs,\n const StringFormat::Attrs & attrs\n)\n``` \n\n### node\n\n```gdscript\n::tensorflow::Node * node() const \n``` \n\n### operator::tensorflow::Input\n\n```gdscript\n operator::tensorflow::Input() const \n``` \n\n### operator::tensorflow::Output\n\n```gdscript\n operator::tensorflow::Output() const \n``` \n\nPublic static functions\n-----------------------\n\n### Placeholder\n\n```text\nAttrs Placeholder(\n StringPiece x\n)\n``` \n\n### Summarize\n\n```text\nAttrs Summarize(\n int64 x\n)\n``` \n\n### Template\n\n```text\nAttrs Template(\n StringPiece x\n)\n```"]]