جریان تنسور:: عملیات:: ResourceCountUpTo
#include <state_ops.h>
متغیری که توسط "منبع" به آن اشاره شده است را افزایش می دهد تا زمانی که به "حد" برسد.
خلاصه
استدلال ها:
- scope: یک شی Scope
- منبع: باید از یک گره
Variable
اسکالر باشد. - limit: اگر افزایش ref آن را به بالاتر از حد برساند، در عوض یک خطای "OutOfRange" ایجاد می کند.
برمی گرداند:
-
Output
: یک کپی از ورودی قبل از افزایش. اگر هیچ چیز دیگری ورودی را تغییر ندهد، مقادیر تولید شده همگی متمایز خواهند بود.
سازندگان و تخریب کنندگان | |
---|---|
ResourceCountUpTo (const :: tensorflow::Scope & scope, :: tensorflow::Input resource, int64 limit, DataType T) |
صفات عمومی | |
---|---|
operation | |
output |
توابع عمومی | |
---|---|
node () const | ::tensorflow::Node * |
operator::tensorflow::Input () const | |
operator::tensorflow::Output () const |
صفات عمومی
عملیات
Operation operation
خروجی
::tensorflow::Output output
توابع عمومی
ResourceCountUpTo
ResourceCountUpTo( const ::tensorflow::Scope & scope, ::tensorflow::Input resource, int64 limit, DataType T )
گره
::tensorflow::Node * node() const
عملگر::tensorflow::ورودی
operator::tensorflow::Input() const
عملگر::tensorflow::خروجی
operator::tensorflow::Output() const
جز در مواردی که غیر از این ذکر شده باشد،محتوای این صفحه تحت مجوز Creative Commons Attribution 4.0 License است. نمونه کدها نیز دارای مجوز Apache 2.0 License است. برای اطلاع از جزئیات، به خطمشیهای سایت Google Developers مراجعه کنید. جاوا علامت تجاری ثبتشده Oracle و/یا شرکتهای وابسته به آن است.
تاریخ آخرین بهروزرسانی 2025-07-27 بهوقت ساعت هماهنگ جهانی.
[null,null,["تاریخ آخرین بهروزرسانی 2025-07-27 بهوقت ساعت هماهنگ جهانی."],[],[],null,["# tensorflow::ops::ResourceCountUpTo Class Reference\n\ntensorflow::ops::ResourceCountUpTo\n==================================\n\n`#include \u003cstate_ops.h\u003e`\n\nIncrements variable pointed to by 'resource' until it reaches 'limit'.\n\nSummary\n-------\n\nArguments:\n\n- scope: A [Scope](/versions/r2.3/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope) object\n- resource: Should be from a scalar [Variable](/versions/r2.3/api_docs/cc/class/tensorflow/ops/variable#classtensorflow_1_1ops_1_1_variable) node.\n- limit: If incrementing ref would bring it above limit, instead generates an 'OutOfRange' error.\n\n\u003cbr /\u003e\n\nReturns:\n\n- [Output](/versions/r2.3/api_docs/cc/class/tensorflow/output#classtensorflow_1_1_output): A copy of the input before increment. If nothing else modifies the input, the values produced will all be distinct.\n\n\u003cbr /\u003e\n\n| ### Constructors and Destructors ||\n|---|---|\n| [ResourceCountUpTo](#classtensorflow_1_1ops_1_1_resource_count_up_to_1a3f5cc785cdb1c38e13b4985cce71d3dc)`(const ::`[tensorflow::Scope](/versions/r2.3/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope)` & scope, ::`[tensorflow::Input](/versions/r2.3/api_docs/cc/class/tensorflow/input#classtensorflow_1_1_input)` resource, int64 limit, DataType T)` ||\n\n| ### Public attributes ||\n|--------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------|\n| [operation](#classtensorflow_1_1ops_1_1_resource_count_up_to_1a8d9322d66a94c1305a62da78483e3a60) | [Operation](/versions/r2.3/api_docs/cc/class/tensorflow/operation#classtensorflow_1_1_operation) |\n| [output](#classtensorflow_1_1ops_1_1_resource_count_up_to_1a9be0b0c2483021f66711c198b258f00f) | `::`[tensorflow::Output](/versions/r2.3/api_docs/cc/class/tensorflow/output#classtensorflow_1_1_output) |\n\n| ### Public functions ||\n|--------------------------------------------------------------------------------------------------------------------------------|------------------------|\n| [node](#classtensorflow_1_1ops_1_1_resource_count_up_to_1a8c06d29483d81d8e354a58552bffb5ab)`() const ` | `::tensorflow::Node *` |\n| [operator::tensorflow::Input](#classtensorflow_1_1ops_1_1_resource_count_up_to_1a18b6c3e3062b78ee885173c5eda18122)`() const ` | ` ` ` ` |\n| [operator::tensorflow::Output](#classtensorflow_1_1ops_1_1_resource_count_up_to_1a29b3486aade8e7ad3dff23cabd39c4be)`() const ` | ` ` ` ` |\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### ResourceCountUpTo\n\n```gdscript\n ResourceCountUpTo(\n const ::tensorflow::Scope & scope,\n ::tensorflow::Input resource,\n int64 limit,\n DataType T\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```"]]