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

breaking: allowmean and allowdrift True by default in AutoARIMA #918

Merged
merged 5 commits into from
Sep 20, 2024
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
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ repos:
hooks:
- id: mypy
args: [--ignore-missing-imports]
exclude: 'setup.py'
exclude: (experiments|setup.py)
1 change: 0 additions & 1 deletion experiments/m3/src/data.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import fire
import pandas as pd
from datasetsforecast.m3 import M3, M3Info

dict_datasets = {
Expand Down
5 changes: 2 additions & 3 deletions experiments/m3/src/evaluation.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
from itertools import product

import fire
import numpy as np
import pandas as pd
from datasetsforecast.losses import mape, smape

Expand Down Expand Up @@ -50,11 +49,11 @@ def main(test: bool = False):
time = evaluation.query('metric=="time"').T
if test:
expected_results = {
'AutoARIMA': 4.57,
'AutoARIMA': 4.46,
'CES': 4.85,
'AutoETS': 4.35,
'DynamicOptimizedTheta': 4.54,
'StatisticalEnsemble': 4.23,
'StatisticalEnsemble': 4.3,
}
expected_results = pd.Series(expected_results)
pd.testing.assert_series_equal(
Expand Down
4 changes: 1 addition & 3 deletions experiments/m3/src/experiment.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
import os
import time
from functools import partial
from multiprocessing import cpu_count
os.environ['NIXTLA_NUMBA_RELEASE_GIL'] = '1'
os.environ['NIXTLA_NUMBA_CACHE'] = '1'
Expand All @@ -11,8 +10,7 @@
from statsforecast import StatsForecast
from statsforecast.models import (
AutoTheta, AutoETS, AutoCES,AutoARIMA,
Theta, OptimizedTheta,
DynamicTheta, DynamicOptimizedTheta
DynamicOptimizedTheta
)
from statsforecast.utils import AirPassengers as ap

Expand Down
4 changes: 2 additions & 2 deletions nbs/src/core/models.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -500,8 +500,8 @@
" test_kwargs: Optional[str] = None,\n",
" seasonal_test: str = 'seas',\n",
" seasonal_test_kwargs: Optional[Dict] = None,\n",
" allowdrift: bool = False,\n",
" allowmean: bool = False,\n",
" allowdrift: bool = True,\n",
" allowmean: bool = True,\n",
" blambda: Optional[float] = None,\n",
" biasadj: bool = False,\n",
" season_length: int = 1,\n",
Expand Down
4 changes: 2 additions & 2 deletions python/statsforecast/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -289,8 +289,8 @@ def __init__(
test_kwargs: Optional[str] = None,
seasonal_test: str = "seas",
seasonal_test_kwargs: Optional[Dict] = None,
allowdrift: bool = False,
allowmean: bool = False,
allowdrift: bool = True,
allowmean: bool = True,
blambda: Optional[float] = None,
biasadj: bool = False,
season_length: int = 1,
Expand Down
2 changes: 1 addition & 1 deletion settings.ini
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ ray_requirements = fugue[ray]>=0.8.1 protobuf>=3.15.3,<4.0.0 numpy<2 pandas<2.2
dask_requirements = fugue[dask]>=0.8.1
spark_requirements = fugue[spark]>=0.8.1
plotly_requirements = plotly plotly-resampler
dev_requirements = black datasetsforecast fire nbdev nbformat nbdev_plotly pandas[plot] pmdarima polars[numpy] pre-commit prophet pyarrow pybind11 pytest scikit-learn setuptools<70 supersmoother
dev_requirements = black datasetsforecast fire nbdev==2.3.25 nbformat nbdev_plotly pandas[plot] pmdarima polars[numpy] pre-commit prophet pyarrow pybind11 pytest scikit-learn setuptools<70 supersmoother
nbs_path = nbs
doc_path = _docs
recursive = True
Expand Down
Loading