min_max_scaler module¶
Scaling a variable with a geometrical linear transformation.
The MinMaxScaler
class implements the MinMax scaling method
applying to some parameter \(z\):
where \(\text{offset}=-\text{min}(z)/(\text{max}(z)-\text{min}(z))\) and \(\text{coefficient}=1/(\text{max}(z)-\text{min}(z))\).
In the MinMax scaling method, the scaling operation linearly transforms the original variable \(z\) such that the minimum of the original data corresponds to 0 and the maximum to 1.
- class gemseo.mlearning.transform.scaler.min_max_scaler.MinMaxScaler(name='MinMaxScaler', offset=0.0, coefficient=1.0)[source]¶
Bases:
gemseo.mlearning.transform.scaler.scaler.Scaler
Min-max scaler.
- Parameters
- Return type
None
- compute_jacobian(data)¶
Compute Jacobian of transformer.transform().
- Parameters
data (numpy.ndarray) – The data where the Jacobian is to be computed.
- Returns
The Jacobian matrix.
- Return type
- compute_jacobian_inverse(data)¶
Compute Jacobian of the transformer.inverse_transform().
- Parameters
data (numpy.ndarray) – The data where the Jacobian is to be computed.
- Returns
The Jacobian matrix.
- Return type
- duplicate()¶
Duplicate the current object.
- Returns
A deepcopy of the current instance.
- Return type
- fit(data, *args)¶
Fit the transformer to the data.
- Parameters
data (numpy.ndarray) – The data to be fitted.
- Return type
NoReturn
- fit_transform(data, *args)¶
Fit the transformer to the data and transform the data.
- Parameters
data (numpy.ndarray) – The data to be transformed.
- Returns
The transformed data.
- Return type
- inverse_transform(data)¶
Perform an inverse transform on the data.
- Parameters
data (numpy.ndarray) – The data to be inverse transformed.
- Returns
The inverse transformed data.
- Return type
- transform(data)¶
Transform the data.
- Parameters
data (numpy.ndarray) – The data to be transformed.
- Returns
The transformed data.
- Return type
- CROSSED = False¶