Darts offers a modular installation system with optional dependencies. Choose the installation that fits your needs:
- Core only (without neural networks, Prophet, LightGBM, CatBoost, XGBoost, StatsForecast):
pip install darts - Core + PyTorch (for neural network models):
pip install "darts[torch]" - Core + Prophet, LightGBM, CatBoost, XGBoost, StatsForecast (no neural networks):
pip install "darts[notorch]" - All available models (except listed below):
pip install "darts[all]"
If the PyTorch installation fails on your platform, please follow the official installation guide for PyTorch, then try installing Darts again.
Some models have additional dependencies that are not included in the all installation option. To use them, you need to install the following dependencies separately from PyPI:
| Model | Dependencies |
|---|---|
NeuralForecastModel |
neuralforecast>=3.0.0 |
TiRexModel |
tirex-ts>=1.4.0 |
Create a conda environment (e.g., for Python 3.11): (after installing conda):
conda create --name <env-name> python=3.11
Activate the environment
conda activate <env-name>
As some models have relatively heavy dependencies, we provide four conda-forge packages:
- Core only (without neural networks, Prophet, LightGBM, CatBoost, XGBoost, StatsForecast):
conda install -c conda-forge u8darts - Core + PyTorch (for neural network models):
conda install -c conda-forge -c pytorch u8darts-torch - Core + Prophet, LightGBM, CatBoost, XGBoost, StatsForecast (no neural networks):
conda install -c conda-forge u8darts-notorch - All available models (except listed below):
conda install -c conda-forge -c pytorch u8darts-all
Some models have additional dependencies that are not included in the all installation option. To use them, you need to install the following dependencies separately from conda-forge:
| Model | Dependencies |
|---|---|
NeuralForecastModel |
neuralforecast>=3.0.0 |
Prophet |
prophet>=1.1.1 |
Some models have dependencies not available on conda-forge. To use them, you need to install the following dependencies separately from PyPI:
| Model | Dependencies |
|---|---|
TiRexModel |
tirex-ts>=1.4.0 |
Darts relies on PyTorch for the neural network models. For GPU support, please follow the instructions to install CUDA in the PyTorch installation guide.
We also provide a Docker image with everything set up for you. For this setup to work you need to have a Docker service installed. You can get it at Docker website.
Pull the latest Darts image.
docker pull unit8/darts:latestTo run it in interactive mode:
docker run -it -p 8888:8888 unit8/darts:latest bashAfter that, you can also launch a Jupyter lab / notebook session:
jupyter lab --ip 0.0.0.0 --no-browser --allow-rootThen copy and paste the URL provided by the docker container into your browser to access Jupyter notebook.
As of Darts version 0.41.0, we have made changes to our PyPI packages:
darts:dartsnow replacesu8dartswith all of its installation options (see section above).u8darts: we will stop maintaining theu8dartspackage in favor ofdarts. Version 0.41.0 will be the last released version.
We made these changes to simplify the installation and maintenance of Darts.
No code changes are required - only package installations changes.
For darts users:
# the original `pip install darts` becomes:
pip install "darts[torch]>=0.41.0"
For u8darts users:
# the original `pip install u8darts[option]` becomes:
pip install "darts[option]>=0.41.0" # or appropriate extras (e.g. darts[all])