(weights)
| 100 | return lambda _: None |
| 101 | |
| 102 | def l2(weights): |
| 103 | with tf.name_scope(scope, 'l2_regularizer', [weights]) as name: |
| 104 | my_scale = tf.convert_to_tensor(scale, dtype=weights.dtype.base_dtype, name='scale') |
| 105 | return tf.math.multiply(my_scale, tf.nn.l2_loss(weights), name=name) |
| 106 | |
| 107 | return l2 |
| 108 |
nothing calls this directly
no test coverage detected