Open fkiraly opened 1 year ago
Just directly calling inverse_transform
would not work; this would cause an error on line 150 in base.py when calling X = X.combine_first(X_update)
with the error message ValueError: cannot join with no overlapping index names
The reason is that in the probabilistic case X looks as:
Coverage
0.9
lower upper
1959 -488.285569 1953.243863
1960 -22.106610 2460.082626
1961 -561.797409 1921.745799
1962 1419.392842 3902.981509
and X_update
as
TOTEMP
1958 66513.0
Thereby X
are the values after the probabilistic forecast that should be inverse transformed X_update
is a cutout from self._X
. The combine_first
fails in that case since the column names differ. An Optionsmight be
to create a df from X_update
with the correct column names, however this might cause problems with multivariate forecasting.
As @benHeid pointed out, there may be some redundant code in
TransformedTargetForecaster._get_inverse_transform
, which seems to duplicate column broadcasting for transformers.Possibly it is needed to deal with column multi-index (which transformers cannot necessarily), but that may be something to revisit as a part of
BaseTransformer
.This issue is for investigating whether there is duplication to be resolved.