pytorch_forecasting.data.encoders.
MultiNormalizer
Bases: pytorch_forecasting.data.encoders.TorchNormalizer
pytorch_forecasting.data.encoders.TorchNormalizer
Normalizer for multiple targets.
This normalizers wraps multiple other normalizers.
normalizers (List[TorchNormalizer]) – list of normalizers to apply to targets
Methods
fit(y[, X])
fit
Fit transformer, i.e. determine center and scale of data.
fit_transform(X[, y])
fit_transform
Fit to data, then transform it.
get_parameters(*args, **kwargs)
get_parameters
Returns parameters that were used for encoding.
get_params([deep])
get_params
Get parameters for this estimator.
inverse_preprocess(y)
inverse_preprocess
Inverse preprocess re-scaled data (e.g.
inverse_transform(y)
inverse_transform
Inverse scale.
preprocess(y)
preprocess
Preprocess input data (e.g.
set_params(**params)
set_params
Set the parameters of this estimator.
transform(y[, X, return_norm, target_scale])
transform
Scale input data.
Attributes
TRANSFORMATIONS
Fit transformer, i.e. determine center and scale of data
y (Union[pd.Series, np.ndarray, torch.Tensor]) – input data
self
First element is center of data and second is scale
List[torch.Tensor]
y (Union[pd.DataFrame, np.ndarray, torch.Tensor]) – data to scale
X (pd.DataFrame) – dataframe with groups columns. Only necessary if GroupNormalizer is among normalizers
groups
GroupNormalizer
return_norm (bool, optional) – If to return . Defaults to False.
target_scale (List[torch.Tensor]) – target scale to use instead of fitted center and scale
List of scaled data, if return_norm=True, returns also scales as second element
return_norm=True
Union[List[Tuple[Union[np.ndarray, torch.Tensor], np.ndarray]], List[Union[np.ndarray, torch.Tensor]]]