tf_agents.utils.nest_utils.assert_tensors_matching_dtypes_and_shapes
Checks if tensors have matching dtypes and shapes.
tf_agents.utils.nest_utils.assert_tensors_matching_dtypes_and_shapes(
tensors_1, tensors_2, caller, tensors_1_name, tensors_2_name
)
Args |
tensors_1
|
A nest of tensor objects.
|
tensors_2
|
A nest of tensor objects.
|
caller
|
The object calling assert... .
|
tensors_1_name
|
(str) Name to use for tensors_1 in case of an error.
|
tensors_2_name
|
(str) Name to use for tensors_2 in case of an error.
|
Raises |
ValueError
|
If the tensors do not match dtypes or shapes.
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-04-26 UTC.
[null,null,["Last updated 2024-04-26 UTC."],[],[]]