autogluon.timeseries 1.1.2b20240819__py3-none-any.whl → 1.1.2b20240820__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -222,18 +222,22 @@ def seasonal_naive_forecast(
222
222
  ) -> pd.DataFrame:
223
223
  """Generate seasonal naive forecast, predicting the last observed value from the same period."""
224
224
 
225
- def numpy_ffill(arr: np.ndarray) -> np.ndarray:
226
- """Fast implementation of forward fill in numpy."""
225
+ def numpy_fillna(arr: np.ndarray) -> np.ndarray:
226
+ """Fast implementation of forward fill + avg fill in numpy."""
227
+ # First apply forward fill
227
228
  idx = np.arange(len(arr))
228
229
  mask = np.isnan(arr)
229
230
  idx[mask] = 0
230
- return arr[np.maximum.accumulate(idx)]
231
+ arr_filled = arr[np.maximum.accumulate(idx)]
232
+ # Leading NaNs are filled with the mean
233
+ arr_filled[np.isnan(arr_filled)] = np.nanmean(arr_filled)
234
+ return arr_filled
231
235
 
232
236
  forecast = {}
233
237
  # At least seasonal_period + 2 values are required to compute sigma for seasonal naive
234
238
  if len(target) > seasonal_period + 1 and seasonal_period > 1:
235
239
  if np.isnan(target[-(seasonal_period + 2) :]).any():
236
- target = numpy_ffill(target)
240
+ target = numpy_fillna(target)
237
241
 
238
242
  indices = [len(target) - seasonal_period + k % seasonal_period for k in range(prediction_length)]
239
243
  forecast["mean"] = target[indices]
@@ -1,3 +1,3 @@
1
1
  """This is the autogluon version file."""
2
- __version__ = '1.1.2b20240819'
2
+ __version__ = '1.1.2b20240820'
3
3
  __lite__ = False
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: autogluon.timeseries
3
- Version: 1.1.2b20240819
3
+ Version: 1.1.2b20240820
4
4
  Summary: Fast and Accurate ML in 3 Lines of Code
5
5
  Home-page: https://github.com/autogluon/autogluon
6
6
  Author: AutoGluon Community
@@ -52,9 +52,9 @@ Requires-Dist: fugue>=0.9.0
52
52
  Requires-Dist: tqdm<5,>=4.38
53
53
  Requires-Dist: orjson~=3.9
54
54
  Requires-Dist: tensorboard<3,>=2.9
55
- Requires-Dist: autogluon.core[raytune]==1.1.2b20240819
56
- Requires-Dist: autogluon.common==1.1.2b20240819
57
- Requires-Dist: autogluon.tabular[catboost,lightgbm,xgboost]==1.1.2b20240819
55
+ Requires-Dist: autogluon.core[raytune]==1.1.2b20240820
56
+ Requires-Dist: autogluon.common==1.1.2b20240820
57
+ Requires-Dist: autogluon.tabular[catboost,lightgbm,xgboost]==1.1.2b20240820
58
58
  Provides-Extra: all
59
59
  Requires-Dist: optimum[onnxruntime]<1.19,>=1.17; extra == "all"
60
60
  Provides-Extra: chronos-onnx
@@ -1,10 +1,10 @@
1
- autogluon.timeseries-1.1.2b20240819-py3.8-nspkg.pth,sha256=cQGwpuGPqg1GXscIwt-7PmME1OnSpD-7ixkikJ31WAY,554
1
+ autogluon.timeseries-1.1.2b20240820-py3.8-nspkg.pth,sha256=cQGwpuGPqg1GXscIwt-7PmME1OnSpD-7ixkikJ31WAY,554
2
2
  autogluon/timeseries/__init__.py,sha256=_CrLLc1fkjen7UzWoO0Os8WZoHOgvZbHKy46I8v_4k4,304
3
3
  autogluon/timeseries/evaluator.py,sha256=l642tYfTHsl8WVIq_vV6qhgAFVFr9UuZD7gLra3A_Kc,250
4
4
  autogluon/timeseries/learner.py,sha256=IYXpJSDyTzjZXjKL_SrTujt5Uke83mSJFA0sMj25_sM,13828
5
5
  autogluon/timeseries/predictor.py,sha256=IaooHyVzNTjYn6uVEVKvqecIdMTH9oEa4f3YMJbHdXM,83216
6
6
  autogluon/timeseries/splitter.py,sha256=eghGwAAN2_cxGk5aJBILgjGWtLzjxJcytMy49gg_q18,3061
7
- autogluon/timeseries/version.py,sha256=w_Hi_Ourowp-fTYym9GwA4zcFGdzHUee9WJisThJxDs,90
7
+ autogluon/timeseries/version.py,sha256=6uGWU7Ekhlz8f0HczuOvxX_zFi6HIXNWWyEJ1CbNr-c,90
8
8
  autogluon/timeseries/configs/__init__.py,sha256=BTtHIPCYeGjqgOcvqb8qPD4VNX-ICKOg6wnkew1cPOE,98
9
9
  autogluon/timeseries/configs/presets_configs.py,sha256=94-yL9teDHKs2irWjP3kpewI7FE1ChYCgEgz9XHJ6gc,1965
10
10
  autogluon/timeseries/dataset/__init__.py,sha256=UvnhAN5tjgxXTHoZMQDy64YMDj4Xxa68yY7NP4vAw0o,81
@@ -34,7 +34,7 @@ autogluon/timeseries/models/gluonts/abstract_gluonts.py,sha256=X4KChuSVSoxLOcrto
34
34
  autogluon/timeseries/models/gluonts/torch/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
35
35
  autogluon/timeseries/models/gluonts/torch/models.py,sha256=5fp2yEyTvMVDm-jQEUYB4ugLkVDcd364NBUjmePltO8,24058
36
36
  autogluon/timeseries/models/local/__init__.py,sha256=JyckWWgMG1BTIWJqFTW6e1O-eb0LPPOwtXwmb1ErohQ,756
37
- autogluon/timeseries/models/local/abstract_local_model.py,sha256=JfjDXOSBgD_10JrIq5nWS038-4moRNI0001BLta8nRs,11723
37
+ autogluon/timeseries/models/local/abstract_local_model.py,sha256=Ge4X4FgyYHsFU5h9q7mSVlEXKKJtyGqckjPJ4PXx3A0,11917
38
38
  autogluon/timeseries/models/local/naive.py,sha256=iwRcFMFmJKPWPbD9TWaIUS51oav69F_VAp6-jb_5SUE,7249
39
39
  autogluon/timeseries/models/local/npts.py,sha256=Bp74doKnfpGE8ywP4FWOCI_RwRMsmgocYDfGtq764DA,4143
40
40
  autogluon/timeseries/models/local/statsforecast.py,sha256=79swW7g7bn1CmuGY79i7r0uj0QZr6WLIfH_x3p1FTDA,32742
@@ -52,11 +52,11 @@ autogluon/timeseries/utils/datetime/base.py,sha256=3NdsH3NDq4cVAOSoy3XpaNixyNlbj
52
52
  autogluon/timeseries/utils/datetime/lags.py,sha256=GoLtvcZ8oKb3QkoBJ9E59LSPLOP7Qjxrr2UmMSZgjyw,5909
53
53
  autogluon/timeseries/utils/datetime/seasonality.py,sha256=h_4w00iEytAz_N_EpCENQ8RCXy7KQITczrYjBgVqWkQ,764
54
54
  autogluon/timeseries/utils/datetime/time_features.py,sha256=PAXbYbQ0z_5GFbkxSNi41zLY_2-U3x0Ynm1m_WhdtGc,2572
55
- autogluon.timeseries-1.1.2b20240819.dist-info/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142
56
- autogluon.timeseries-1.1.2b20240819.dist-info/METADATA,sha256=oo7CaGnfZl47Xt40EkZFp0aV7XMBK7qrGZhWC_GlCQI,12460
57
- autogluon.timeseries-1.1.2b20240819.dist-info/NOTICE,sha256=7nPQuj8Kp-uXsU0S5so3-2dNU5EctS5hDXvvzzehd7E,114
58
- autogluon.timeseries-1.1.2b20240819.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
59
- autogluon.timeseries-1.1.2b20240819.dist-info/namespace_packages.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
60
- autogluon.timeseries-1.1.2b20240819.dist-info/top_level.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
61
- autogluon.timeseries-1.1.2b20240819.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
62
- autogluon.timeseries-1.1.2b20240819.dist-info/RECORD,,
55
+ autogluon.timeseries-1.1.2b20240820.dist-info/LICENSE,sha256=CeipvOyAZxBGUsFoaFqwkx54aPnIKEtm9a5u2uXxEws,10142
56
+ autogluon.timeseries-1.1.2b20240820.dist-info/METADATA,sha256=rLu6rDkur8guSIqTm851-t2gpon-tgYK_6hDPkMBdV0,12460
57
+ autogluon.timeseries-1.1.2b20240820.dist-info/NOTICE,sha256=7nPQuj8Kp-uXsU0S5so3-2dNU5EctS5hDXvvzzehd7E,114
58
+ autogluon.timeseries-1.1.2b20240820.dist-info/WHEEL,sha256=eOLhNAGa2EW3wWl_TU484h7q1UNgy0JXjjoqKoxAAQc,92
59
+ autogluon.timeseries-1.1.2b20240820.dist-info/namespace_packages.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
60
+ autogluon.timeseries-1.1.2b20240820.dist-info/top_level.txt,sha256=giERA4R78OkJf2ijn5slgjURlhRPzfLr7waIcGkzYAo,10
61
+ autogluon.timeseries-1.1.2b20240820.dist-info/zip-safe,sha256=AbpHGcgLb-kRsJGnwFEktk7uzpZOCcBY74-YBdrKVGs,1
62
+ autogluon.timeseries-1.1.2b20240820.dist-info/RECORD,,