MinMax#
- class reservoirflow.scalers.MinMax(output_range: tuple, input_range: tuple | None = None)#
Bases:
Scaler
MinMax scaler class.
This scaler is used to scale input data based on
output_range=(min,max)
. Ifinput_range
is set toNone
instead ofinput_range=(min,max)
, theninput_range
is inferred based on input data.Hint
Using
input_range=(min,max)
is useful in some cases to match the scaling with other solutions wheninput_range
can’t be inferred from input data (e.g. unstable solution).Note
Note that if the input array has multiple feature each with its own range (not unified), then using
input_range=None
is required to inferinput_range
for each feature.- Returns:
Scaler object.
- Return type:
Construct scaler object.
- Parameters:
output_range (tuple, optional) – output range used in the transformation.
input_range (tuple, optional) – input range used in the transformation.
Attributes
Class name.
Methods
fit
(v[, axis])Fit scaler with input values.
fit_transform
(v[, axis])Fit scaler and transform input based on output range.
inverse_transform
(vbar)Transform input back to the original (input) range.
set_output_range
(output_range)Set output range for the scaler.
transform
(v)Transform input based on output range.
Comments 💬#
Feel free to make a comment, ask a question, or share your opinion about this specific content. Please keep in mind the Commenting Guidelines ⚖.