Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix STL inverse transform bug #4328

Merged
merged 3 commits into from
Oct 4, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions docs/source/release_notes.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ Release Notes
* Extended TimeSeriesRegularizer to support multiseries :pr:`4303`
* Fixes
* Fixed forecast period generation function for multiseries :pr:`4320`
* Fixed bug in ``STLDecomposer.inverse_transform`` causing incorrect seasonality projections :pr:`4328`
* Changes
* Updated ``split_data`` to call ``split_multiseries_data`` when passed stacked multiseries data :pr:`4312`
* Pinned pandas version under 2.1.0 :pr:`4315`
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -380,10 +380,12 @@
if len(y_t.columns) > 1:
old_trend = self.trends[id]
old_seasonal = self.seasonals[id]
old_seasonality = self.seasonalities[id]

Check warning on line 383 in evalml/pipelines/components/transformers/preprocessing/stl_decomposer.py

View check run for this annotation

Codecov / codecov/patch

evalml/pipelines/components/transformers/preprocessing/stl_decomposer.py#L383

Added line #L383 was not covered by tests
period = self.periods[id]
else:
old_trend = list(self.trends.values())[0]
old_seasonal = list(self.seasonals.values())[0]
old_seasonality = list(self.seasonalities.values())[0]

Check warning on line 388 in evalml/pipelines/components/transformers/preprocessing/stl_decomposer.py

View check run for this annotation

Codecov / codecov/patch

evalml/pipelines/components/transformers/preprocessing/stl_decomposer.py#L388

Added line #L388 was not covered by tests
period = list(self.periods.values())[0]
# For partially and wholly in-sample data, retrieve stored results.
if index[0] <= series_y.index[0] <= index[-1]:
Expand Down Expand Up @@ -423,7 +425,7 @@
) = self._project_trend_and_seasonality(
truncated_y_t,
old_trend,
old_seasonal,
old_seasonality,
period,
)

Expand Down
Loading