Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
dòng chảy căng:: ôi:: Khẳng định
#include <logging_ops.h>
Khẳng định rằng điều kiện đã cho là đúng.
Bản tóm tắt
Nếu condition
đánh giá là sai, hãy in danh sách các tensor trong data
. summarize
xác định có bao nhiêu mục của tensor cần in.
Lập luận:
- phạm vi: Một đối tượng Phạm vi
- condition: Điều kiện để đánh giá.
- dữ liệu: Các tensor để in ra khi điều kiện sai.
Thuộc tính tùy chọn (xem Attrs
):
- tóm tắt: In nhiều mục này của mỗi tensor.
Trả về:
Thuộc tính công khai
Chức năng công cộng
toán tử::tenorflow::Hoạt động
operator::tensorflow::Operation() const
Các hàm tĩnh công khai
Tóm tắt
Attrs Summarize(
int64 x
)
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0. Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers. Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-07-26 UTC.
[null,null,["Cập nhật lần gần đây nhất: 2025-07-26 UTC."],[],[],null,["# tensorflow::ops::Assert Class Reference\n\ntensorflow::ops::Assert\n=======================\n\n`#include \u003clogging_ops.h\u003e`\n\nAsserts that the given condition is true.\n\nSummary\n-------\n\nIf `condition` evaluates to false, print the list of tensors in `data`. `summarize` determines how many entries of the tensors to print.\n\nArguments:\n\n- scope: A [Scope](/versions/r2.2/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope) object\n- condition: The condition to evaluate.\n- data: The tensors to print out when condition is false.\n\n\u003cbr /\u003e\n\nOptional attributes (see [Attrs](/versions/r2.2/api_docs/cc/struct/tensorflow/ops/assert/attrs#structtensorflow_1_1ops_1_1_assert_1_1_attrs)):\n\n- summarize: [Print](/versions/r2.2/api_docs/cc/class/tensorflow/ops/print#classtensorflow_1_1ops_1_1_print) this many entries of each tensor.\n\n\u003cbr /\u003e\n\nReturns:\n\n- the created [Operation](/versions/r2.2/api_docs/cc/class/tensorflow/operation#classtensorflow_1_1_operation)\n\n\u003cbr /\u003e\n\n| ### Constructors and Destructors ||\n|---|---|\n| [Assert](#classtensorflow_1_1ops_1_1_assert_1af81dc219d43af5f1f57633edd6869d35)`(const ::`[tensorflow::Scope](/versions/r2.2/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope)` & scope, ::`[tensorflow::Input](/versions/r2.2/api_docs/cc/class/tensorflow/input#classtensorflow_1_1_input)` condition, ::`[tensorflow::InputList](/versions/r2.2/api_docs/cc/class/tensorflow/input-list#classtensorflow_1_1_input_list)` data)` ||\n| [Assert](#classtensorflow_1_1ops_1_1_assert_1a0dc850b92e0420af7e04c28133d91328)`(const ::`[tensorflow::Scope](/versions/r2.2/api_docs/cc/class/tensorflow/scope#classtensorflow_1_1_scope)` & scope, ::`[tensorflow::Input](/versions/r2.2/api_docs/cc/class/tensorflow/input#classtensorflow_1_1_input)` condition, ::`[tensorflow::InputList](/versions/r2.2/api_docs/cc/class/tensorflow/input-list#classtensorflow_1_1_input_list)` data, const `[Assert::Attrs](/versions/r2.2/api_docs/cc/struct/tensorflow/ops/assert/attrs#structtensorflow_1_1ops_1_1_assert_1_1_attrs)` & attrs)` ||\n\n| ### Public attributes ||\n|------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------|\n| [operation](#classtensorflow_1_1ops_1_1_assert_1ac87c4c74ab1959fb429df106cd771128) | [Operation](/versions/r2.2/api_docs/cc/class/tensorflow/operation#classtensorflow_1_1_operation) |\n\n| ### Public functions ||\n|---------------------------------------------------------------------------------------------------------------------|---------|\n| [operator::tensorflow::Operation](#classtensorflow_1_1ops_1_1_assert_1a715a4538d968886307e951aaeb975e3a)`() const ` | ` ` ` ` |\n\n| ### Public static functions ||\n|-----------------------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------|\n| [Summarize](#classtensorflow_1_1ops_1_1_assert_1adba119f0fab568f3e6f338108ab2277f)`(int64 x)` | [Attrs](/versions/r2.2/api_docs/cc/struct/tensorflow/ops/assert/attrs#structtensorflow_1_1ops_1_1_assert_1_1_attrs) |\n\n| ### Structs ||\n|-------------------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------|\n| [tensorflow::ops::Assert::Attrs](/versions/r2.2/api_docs/cc/struct/tensorflow/ops/assert/attrs) | Optional attribute setters for [Assert](/versions/r2.2/api_docs/cc/class/tensorflow/ops/assert#classtensorflow_1_1ops_1_1_assert). |\n\nPublic attributes\n-----------------\n\n### operation\n\n```text\nOperation operation\n``` \n\nPublic functions\n----------------\n\n### Assert\n\n```gdscript\n Assert(\n const ::tensorflow::Scope & scope,\n ::tensorflow::Input condition,\n ::tensorflow::InputList data\n)\n``` \n\n### Assert\n\n```gdscript\n Assert(\n const ::tensorflow::Scope & scope,\n ::tensorflow::Input condition,\n ::tensorflow::InputList data,\n const Assert::Attrs & attrs\n)\n``` \n\n### operator::tensorflow::Operation\n\n```gdscript\n operator::tensorflow::Operation() const \n``` \n\nPublic static functions\n-----------------------\n\n### Summarize\n\n```text\nAttrs Summarize(\n int64 x\n)\n```"]]