Skip to content

Commit

Permalink
Make in-sample predictions of SARIMAXModel non-dynamic in all cases (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
Mr-Geekman authored Jul 26, 2022
1 parent 4d5adee commit 36dec78
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
-
-
-
-
- Make in-sample predictions of SARIMAXModel non-dynamic in all cases ([#812](https://github.com/tinkoff-ai/etna/pull/812))
-
-
-
Expand Down
2 changes: 1 addition & 1 deletion etna/models/sarimax.py
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ def predict(self, df: pd.DataFrame, prediction_interval: bool, quantiles: Sequen
y_pred[f"mean_{quantile:.4g}"] = series
else:
forecast = self._result.get_prediction(
start=df["timestamp"].min(), end=df["timestamp"].max(), dynamic=True, exog=exog_future
start=df["timestamp"].min(), end=df["timestamp"].max(), dynamic=False, exog=exog_future
)
y_pred = forecast.predicted_mean
y_pred.name = "mean"
Expand Down
2 changes: 1 addition & 1 deletion tests/test_models/test_inference.py
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,7 @@ def test_forecast_out_sample_suffix_failed(model, transforms, example_tsds):
(ElasticPerSegmentModel(), [LagTransform(in_column="target", lags=[5, 6])]),
(ElasticMultiSegmentModel(), [LagTransform(in_column="target", lags=[5, 6])]),
(ProphetModel(), []),
(SARIMAXModel(), []),
(HoltModel(), []),
(HoltWintersModel(), []),
(SimpleExpSmoothingModel(), []),
Expand All @@ -427,7 +428,6 @@ def test_forecast_mixed_in_out_sample(model, transforms, example_tsds):
@pytest.mark.parametrize(
"model, transforms",
[
(SARIMAXModel(), []),
(AutoARIMAModel(), []),
],
)
Expand Down

1 comment on commit 36dec78

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.