thuml / Time-Series-Library
- суббота, 21 октября 2023 г. в 00:00:14
A Library for Advanced Deep Time Series Models.
TSlib is an open-source library for deep learning researchers, especially deep time series analysis.
We provide a neat code base to evaluate advanced deep time series models or develop your own model, which covers five mainstream tasks: long- and short-term forecasting, imputation, anomaly detection, and classification.
🚩News (2023.10) We add an official implementation to iTransformer, which is the state-of-the-art model in long-term forecasting.
🚩News (2023.09) We add a detailed tutorial for TimesNet and this library, which is quite friendly to beginners of deep time series analysis.
Till October 2023, the top three models for five different tasks are:
Model Ranking |
Long-term Forecasting |
Short-term Forecasting |
Imputation | Anomaly Detection |
Classification |
---|---|---|---|---|---|
🥇 1st | iTransformer | TimesNet | TimesNet | TimesNet | TimesNet |
🥈 2nd | PatchTST | Non-stationary Transformer |
Non-stationary Transformer |
Non-stationary Transformer |
FEDformer |
🥉 3rd | TimesNet | FEDformer | Autoformer | Informer | Autoformer |
Note: We will keep updating this leaderborad. If you have proposed advanced and awesome models, welcome to send your paper/code link to us or raise a pull request. We will add them to this repo and update the leaderborad as soon as possible.
Compared models of this leaderboard. ☑ means that their codes have already been included in this repo.
See our latest paper [TimesNet] for the comprehensive benchmark. We will release a real-time updated online version soon.
Newly added baselines. We will add them into the leaderboard after a comprehensive evaluation.
pip install -r requirements.txt
./dataset
. Here is a summary of supported datasets../scripts/
. You can reproduce the experiment results as the following examples:# long-term forecast
bash ./scripts/long_term_forecast/ETT_script/TimesNet_ETTh1.sh
# short-term forecast
bash ./scripts/short_term_forecast/TimesNet_M4.sh
# imputation
bash ./scripts/imputation/ETT_script/TimesNet_ETTh1.sh
# anomaly detection
bash ./scripts/anomaly_detection/PSM/TimesNet.sh
# classification
bash ./scripts/classification/TimesNet.sh
./models
. You can follow the ./models/Transformer.py
.Exp_Basic.model_dict
of ./exp/exp_basic.py
../scripts
.If you find this repo useful, please cite our paper.
@inproceedings{wu2023timesnet,
title={TimesNet: Temporal 2D-Variation Modeling for General Time Series Analysis},
author={Haixu Wu and Tengge Hu and Yong Liu and Hang Zhou and Jianmin Wang and Mingsheng Long},
booktitle={International Conference on Learning Representations},
year={2023},
}
If you have any questions or suggestions, feel free to contact:
or describe it in Issues. Recently, Jiawei Guo is the main maintainer to this library 😊.
This project is supported by the National Key R&D Program of China (2021YFB1715200).
This library is constructed based on the following repos:
Forecasting: https://github.com/thuml/Autoformer
Anomaly Detection: https://github.com/thuml/Anomaly-Transformer
Classification: https://github.com/thuml/Flowformer
All the experiment datasets are public and we obtain them from the following links:
Long-term Forecasting and Imputation: https://github.com/thuml/Autoformer
Short-term Forecasting: https://github.com/ServiceNow/N-BEATS
Anomaly Detection: https://github.com/thuml/Anomaly-Transformer
Classification: https://www.timeseriesclassification.com/