src.model.deeplearn.regularizer.regularizer
Classes
|
- class src.model.deeplearn.regularizer.regularizer.Regularizer(**kwargs)
- Author:
Alberto M. Esmoris Pena
A regularizer can be seen as a map \(f\) from an input tensor \(\mathcal{X}\) to an output scalar \(y\) that can be added to the loss function.
The Regularizer class provides an interface that must be realized by any class that must assume the role of a regularizer inside a neural network.
- __init__(**kwargs)
Initialize the member attributes of the regularizer.
- Parameters:
kwargs – The key-word specification to parametrize the regularizer.
- __call__(x)
The regularizer’s computation logic.
- Parameters:
x – The input tensor.
- Returns:
The output scalar.
- get_config()
The dictionary specifying how to serialize the regularizer.
- Returns:
The dictionary with the necessary data to serialize the regularizer.
- Return type:
dict