Tetap teratur dengan koleksi
Simpan dan kategorikan konten berdasarkan preferensi Anda.
aliran tensor:: operasi:: HancurkanVariabel Sementara
#include <state_ops.h>
Menghancurkan variabel sementara dan mengembalikan nilai akhirnya.
Ringkasan
Menetapkan output ke nilai Tensor yang ditunjuk oleh 'ref', lalu menghancurkan variabel sementara yang disebut 'var_name'. Semua penggunaan 'ref' lainnya harus sudah dijalankan sebelum operasi ini. Hal ini biasanya dicapai dengan merangkai referensi melalui setiap operasi penetapan, atau dengan menggunakan dependensi kontrol.
Menghasilkan nilai akhir tensor yang ditunjuk oleh 'ref'.
Argumen:
- ruang lingkup: Objek Lingkup
- ref: Referensi ke tensor variabel sementara.
- var_name: Nama variabel sementara, biasanya nama operasi ' TemporaryVariable ' yang cocok.
Pengembalian:
Atribut publik
Fungsi publik
simpul
::tensorflow::Node * node() const
operator::tensorflow::Input() const
operator::tensorflow::Keluaran
operator::tensorflow::Output() const
Kecuali dinyatakan lain, konten di halaman ini dilisensikan berdasarkan Lisensi Creative Commons Attribution 4.0, sedangkan contoh kode dilisensikan berdasarkan Lisensi Apache 2.0. Untuk mengetahui informasi selengkapnya, lihat Kebijakan Situs Google Developers. Java adalah merek dagang terdaftar dari Oracle dan/atau afiliasinya.
Terakhir diperbarui pada 2025-07-27 UTC.
[null,null,["Terakhir diperbarui pada 2025-07-27 UTC."],[],[],null,["# tensorflow::ops::DestroyTemporaryVariable Class Reference\n\ntensorflow::ops::DestroyTemporaryVariable\n=========================================\n\n`#include \u003cstate_ops.h\u003e`\n\nDestroys the temporary variable and returns its final value.\n\nSummary\n-------\n\nSets output to the value of the [Tensor](/versions/r2.3/api_docs/cc/class/tensorflow/tensor#classtensorflow_1_1_tensor) pointed to by 'ref', then destroys the temporary variable called 'var_name'. [All](/versions/r2.3/api_docs/cc/class/tensorflow/ops/all#classtensorflow_1_1ops_1_1_all) other uses of 'ref' *must* have executed before this op. This is typically achieved by chaining the ref through each assign op, or by using control dependencies.\n\nOutputs the final value of the tensor pointed to by 'ref'.\n\nArguments:\n\n- scope: A [Scope](/versions/r2.3/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope) object\n- ref: A reference to the temporary variable tensor.\n- var_name: Name of the temporary variable, usually the name of the matching '[TemporaryVariable](/versions/r2.3/api_docs/cc/class/tensorflow/ops/temporary-variable#classtensorflow_1_1ops_1_1_temporary_variable)' op.\n\n\u003cbr /\u003e\n\nReturns:\n\n- [Output](/versions/r2.3/api_docs/cc/class/tensorflow/output#classtensorflow_1_1_output): The value tensor.\n\n\u003cbr /\u003e\n\n| ### Constructors and Destructors ||\n|---|---|\n| [DestroyTemporaryVariable](#classtensorflow_1_1ops_1_1_destroy_temporary_variable_1a01f12d953d9078e0133345ecad76f629)`(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)` ref, StringPiece var_name)` ||\n\n| ### Public attributes ||\n|--------------------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------|\n| [operation](#classtensorflow_1_1ops_1_1_destroy_temporary_variable_1a0bfa0ecb725488b9065e4dfa42addfdc) | [Operation](/versions/r2.3/api_docs/cc/class/tensorflow/operation#classtensorflow_1_1_operation) |\n| [value](#classtensorflow_1_1ops_1_1_destroy_temporary_variable_1a2a3151dd005ff60e1fbc92d9f72c51d0) | `::`[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_destroy_temporary_variable_1ab3002dc3d20c1e4e20f1fb219714c7e8)`() const ` | `::tensorflow::Node *` |\n| [operator::tensorflow::Input](#classtensorflow_1_1ops_1_1_destroy_temporary_variable_1a36cd6c9de3fec498a9b6f32078402e1a)`() const ` | ` ` ` ` |\n| [operator::tensorflow::Output](#classtensorflow_1_1ops_1_1_destroy_temporary_variable_1a94ad142b7443111409db522488894175)`() const ` | ` ` ` ` |\n\nPublic attributes\n-----------------\n\n### operation\n\n```text\nOperation operation\n``` \n\n### value\n\n```text\n::tensorflow::Output value\n``` \n\nPublic functions\n----------------\n\n### DestroyTemporaryVariable\n\n```gdscript\n DestroyTemporaryVariable(\n const ::tensorflow::Scope & scope,\n ::tensorflow::Input ref,\n StringPiece var_name\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```"]]