Google I/O returns May 18-20! Reserve space and build your schedule Register now

tf.keras.regularizers.l2

TensorFlow 1 version View source on GitHub

Create a regularizer that applies an L2 regularization penalty.

The L2 regularization penalty is computed as:

$$\ell_2\,\,penalty =\ell_2\sum_{i=0}^nx_i^2$$

l Float; L2 regularization factor.

An L2 Regularizer with the given regularization factor.