Add HorizontalSMAModel

- the model applies a simple moving average on horizontal time series
- refactor `db.Forecast.from_dataframe()` to correctly convert
  `float('NaN')` values into `None`; otherwise, SQLAlchemy complains
This commit is contained in:
Alexander Hess 2021-02-02 12:40:53 +01:00
commit 015d304306
Signed by: alexander
GPG key ID: 344EA5AB10D868E0
5 changed files with 116 additions and 14 deletions

View file

@ -153,6 +153,9 @@ per-file-ignores =
src/urban_meal_delivery/forecasts/methods/extrapolate_season.py:
# The module is not too complex.
WPS232,
src/urban_meal_delivery/forecasts/models/tactical/horizontal.py:
# The many noqa's are ok.
WPS403,
src/urban_meal_delivery/forecasts/timify.py:
# No SQL injection as the inputs come from a safe source.
S608,