tf.keras.backend.print_tensor  |  TensorFlow v2.0.0 (original) (raw)

tf.keras.backend.print_tensor

Stay organized with collections Save and categorize content based on your preferences.

Prints message and the tensor value when evaluated.

View aliases

Compat aliases for migration

SeeMigration guide for more details.

tf.compat.v1.keras.backend.print_tensor

tf.keras.backend.print_tensor(
    x, message=''
)

Note that print_tensor returns a new tensor identical to xwhich should be used in the following code. Otherwise the print operation is not taken into account during evaluation.

Example:

x = K.print_tensor(x, message="x is: ")

Arguments
x Tensor to print.
message Message to print jointly with the tensor.
Returns
The same tensor x, unchanged.

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 2020-10-01 UTC.