TensorFlow 2.0 Beta is available Learn more

tf.keras.backend.l2_normalize

TensorFlow 2.0 version View source on GitHub

Normalizes a tensor wrt the L2 norm alongside the specified axis.

Aliases:

  • tf.compat.v1.keras.backend.l2_normalize
  • tf.compat.v2.keras.backend.l2_normalize
tf.keras.backend.l2_normalize(
    x,
    axis=None
)

Arguments:

  • x: Tensor or variable.
  • axis: axis along which to perform normalization.

Returns:

A tensor.