Join us at TensorFlow World, Oct 28-31. Use code TF20 for 20% off select passes. Register now

tf.keras.backend.flatten

TensorFlow 2.0 version View source on GitHub

Flatten a tensor.

Aliases:

  • tf.compat.v1.keras.backend.flatten
  • tf.compat.v2.keras.backend.flatten
tf.keras.backend.flatten(x)

Arguments:

  • x: A tensor or variable.

Returns:

A tensor, reshaped into 1-D