A Neural Network based Time-Series model, inspired by Facebook Prophet and AR-Net, built on PyTorch.
For a visual introduction to NeuralProphet, view the presentation given at the 40th International Symposium on Forecasting (Oct 26, 2020).
A proper documentation page is in the works.
After downloading the code repository (via git clone
), change to the repository directory (cd neural_prophet
) and install neuralprophet as python package with
pip install .
Note: If you plan to use the package in a Jupyter notebook, it is recommended to install the 'live' package version with pip install .[live]
.
This will allow you to enable plot_live_loss
in the train
function to get a live plot of train (and validation) loss.
Now you can use NeuralProphet in your code:
from neuralprophet import NeuralProphet
model = NeuralProphet()
- Autocorrelation modelling through AR-Net
- Piecewise linear trend
- Fourier term Seasonality at different periods such as yearly, daily, weekly, hourly.
- Lagged regressors
- Future regressors
- Holidays & special events
- Sparsity of coefficients through regularization
- Plotting for forecast components, model coefficients as well as final forecasts
After downloading the code repository (via git clone
), change to the repository directory (cd neural_prophet
), activate your virtual environment, and install neuralprophet as python package with
pip install -e .[dev]
(Including the optional -e
flag will install neuralprophet in "editable" mode, meaning that instead of copying the files into your virtual environment, a symlink will be created to the files where they are.)
Additionally you must run $ neuralprophet_dev_setup
in your console to run the dev-setup script which installs appropriate git hooks for testing etc.
We deploy Black, the uncompromising code formatter, so there is no need to worry about style. Beyond that, where reasonable, for example for doicstrings, we follow the Google Python Style Guide
As for Git practices, please follow the steps described at Swiss Cheese for how to git-rebase-squash when working on a forked repo.
The next versions of NeuralProphet are expected to cover a set of new exciting features:
- Robustify training for different datasets
- Logistic growth for trend component.
- Uncertainty estimation of individual forecast components as well as the final forecasts.
- Support for panel data by building global forecasting models.
- Incorporate time series featurization for improved forecast accuracy.
- soft-start regularization
- documentation pages added
- 1cycle policy
- learning rate range test
- tutorial notebooks: trend, events
- fixes to plotting, changepoints
For details, please view the Development Timeline.
The alpha-stage NeuralProphet was developed by Oskar Triebe, advised by Ram Rajagopal (Stanford University) and Nikolay Laptev (Facebook, Inc), and was funded by Total S.A. We are now further developing the beta-stage package in collaboration with Hansika Hewamalage, who is advised by Christoph Bergmeir (Monash University). If you are interested in joining the project, please feel free to reach out to me (Oskar) - you can find my email on the AR-Net Paper.