Welcome to PyPOTS docs!#

PyPOTS logo

A Python Toolbox for Machine Learning on Partially-Observed Time Series

Python version powered by Pytorch the latest release version BSD-3 license Community GitHub Contributors GitHub Repo stars GitHub Repo forks Code Climate maintainability Coveralls coverage GitHub Testing Docs building Conda downloads PyPI downloads arXiv DOI README in Chinese Visiting number

โฆฟ Motivation: Due to all kinds of reasons like failure of collection sensors, communication error, and unexpected malfunction, missing values are common to see in time series from the real-world environment. This makes partially-observed time series (POTS) a pervasive problem in open-world modeling and prevents advanced data analysis. Although this problem is important, the area of data mining on POTS still lacks a dedicated toolkit. PyPOTS is created to fill in this blank.

โฆฟ Mission: PyPOTS is born to become a handy toolbox that is going to make data mining on POTS easy rather than tedious, to help engineers and researchers focus more on the core problems in their hands rather than on how to deal with the missing parts in their data. PyPOTS will keep integrating classical and the latest state-of-the-art data mining algorithms for partially-observed multivariate time series. For sure, besides various algorithms, PyPOTS is going to have unified APIs together with detailed documentation and interactive examples across algorithms as tutorials.

๐Ÿค— Please star this repo to help others notice PyPOTS if you think it is a useful toolkit. Please properly cite PyPOTS in your publications if it helps with your research. This really means a lot to our open-source research. Thank you!

The rest of this readme file is organized as follows: โ– Available Algorithms, โ– PyPOTS Ecosystem, โ– Installation, โ– Usage, โ– Citing PyPOTS, โ– Contribution, โ– Community.

โ– Available Algorithms#

PyPOTS supports imputation, classification, clustering, forecasting, and anomaly detection tasks on multivariate partially-observed time series with missing values. The table below shows the availability of each algorithm in PyPOTS for different tasks. The symbol โœ… indicates the algorithm is available for the corresponding task (note that models will be continuously updated in the future to handle tasks that are not currently supported. Stay tunedโ—๏ธ).

๐ŸŒŸ Since v0.2, all neural-network models in PyPOTS has got hyperparameter-optimization support. This functionality is implemented with the Microsoft NNI framework. You may want to refer to our time-series imputation survey repo Awesome_Imputation to see how to config and tune the hyperparameters.

๐Ÿ”ฅ Note that all models whose name with ๐Ÿง‘โ€๐Ÿ”ง in the table (e.g. Transformer, iTransformer, Informer etc.) are not originally proposed as algorithms for POTS data in their papers, and they cannot directly accept time series with missing values as input, let alone imputation. To make them applicable to POTS data, we specifically apply the embedding strategy and training approach (ORT+MIT) the same as we did in SAITS paper.

The task types are abbreviated as follows: IMPU: Imputation; FORE: Forecasting; CLAS: Classification; CLUS: Clustering; ANOD: Anomaly Detection. The paper references are all listed at the bottom of this readme file.

Type

Algorithm

IMPU

FORE

CLAS

CLUS

ANOD

Year - Venue

Neural Net

iTransformer [1]

โœ…

2024 - ICLR

Neural Net

SAITS [2]

โœ…

2023 - ESWA

Neural Net

FreTS [3]

โœ…

2023 - NeurIPS

Neural Net

Koopa [4]

โœ…

2023 - NeurIPS

Neural Net

Crossformer [5]

โœ…

2023 - ICLR

Neural Net

TimesNet [6]

โœ…

2023 - ICLR

Neural Net

PatchTST [5]

โœ…

2023 - ICLR

Neural Net

ETSformer [7]

โœ…

2023 - ICLR

Neural Net

MICN [8]

โœ…

2023 - ICLR

Neural Net

DLinear [9]

โœ…

2023 - AAAI

Neural Net

TiDE [10]

โœ…

2023 - TMLR

Neural Net

SCINet [11]

โœ…

2022 - NeurIPS

Neural Net

Nonstationary Tran. [12]

โœ…

2022 - NeurIPS

Neural Net

FiLM [13]

โœ…

2022 - NeurIPS

Neural Net

RevIN_SCInet [14]

โœ…

2022 - ICLR

Neural Net

Pyraformer [15]

โœ…

2022 - ICLR

Neural Net

Raindrop [16]

โœ…

2022 - ICLR

Neural Net

FEDformer [17]

โœ…

2022 - ICML

Neural Net

Autoformer [18]

โœ…

2021 - NeurIPS

Neural Net

CSDI [19]

โœ…

โœ…

2021 - NeurIPS

Neural Net

Informer [20]

โœ…

2021 - AAAI

Neural Net

US-GAN [21]

โœ…

2021 - AAAI

Neural Net

CRLI [22]

โœ…

2021 - AAAI

Probabilistic

BTTF [23]

โœ…

2021 - TPAMI

Neural Net

GP-VAE [24]

โœ…

2020 - AISTATS

Neural Net

VaDER [25]

โœ…

2019 - GigaSci.

Neural Net

M-RNN [26]

โœ…

2019 - TBME

Neural Net

BRITS [27]

โœ…

โœ…

2018 - NeurIPS

Neural Net

GRU-D [28]

โœ…

2018 - Sci. Rep.

Neural Net

Transformer [29]

โœ…

2017 - NeurIPS

Naive

LOCF/NOCB

โœ…

Naive

Median

โœ…

Naive

Mean

โœ…

โ– PyPOTS Ecosystem#

At PyPOTS, things are related to coffee, which weโ€™re familiar with. Yes, this is a coffee universe! As you can see, there is a coffee pot in the PyPOTS logo. And what else? Please read on ;-)

TSDB logo

๐Ÿ‘ˆ Time series datasets are taken as coffee beans at PyPOTS, and POTS datasets are incomplete coffee beans with missing parts that have their own meanings. To make various public time-series datasets readily available to users, Time Series Data Beans (TSDB) is created to make loading time-series datasets super easy! Visit TSDB right now to know more about this handy tool ๐Ÿ› , and it now supports a total of 168 open-source datasets!

PyGrinder logo

๐Ÿ‘‰ To simulate the real-world data beans with missingness, the ecosystem library PyGrinder, a toolkit helping grind your coffee beans into incomplete ones, is created. Missing patterns fall into three categories according to Robinโ€™s theory [30]: MCAR (missing completely at random), MAR (missing at random), and MNAR (missing not at random). PyGrinder supports all of them and additional functionalities related to missingness. With PyGrinder, you can introduce synthetic missing values into your datasets with a single line of code.

BrewPOTS logo

๐Ÿ‘ˆ Now we have the beans, the grinder, and the pot, how to brew us a cup of coffee? Tutorials are necessary! Considering the future workload, PyPOTS tutorials is released in a single repo, and you can find them in BrewPOTS. Take a look at it now, and learn how to brew your POTS datasets!

โ˜•๏ธ Welcome to the universe of PyPOTS. Enjoy it and have fun!

BrewPOTS logo

โ– Installation#

PyPOTS is available on both PyPI and Anaconda.

Refer to the page Installation to see different ways of installing PyPOTS.

โ– Usage#

Besides BrewPOTS, you can also find a simple and quick-start tutorial notebook on Google Colab with this link. You can also raise an issue or ask in our community.

Additionally, we present you a usage example of imputing missing values in time series with PyPOTS in Section Quick-start Examples, you can click it to view.

โ– Citing PyPOTS#

[Updates in Jun 2023] ๐ŸŽ‰A short version of the PyPOTS paper is accepted by the 9th SIGKDD international workshop on Mining and Learning from Time Series (MiLeTSโ€™23). Besides, PyPOTS has been included as a PyTorch Ecosystem project.

The paper introducing PyPOTS is available on arXiv at this URL., and we are pursuing to publish it in prestigious academic venues, e.g. JMLR (track for Machine Learning Open Source Software). If you use PyPOTS in your work, please cite it as below and ๐ŸŒŸstar PyPOTS repository to make others notice this library. ๐Ÿค—

 1@article{du2023pypots,
 2title={{PyPOTS: a Python toolbox for data mining on Partially-Observed Time Series}},
 3author={Wenjie Du},
 4year={2023},
 5eprint={2305.18811},
 6archivePrefix={arXiv},
 7primaryClass={cs.LG},
 8url={https://arxiv.org/abs/2305.18811},
 9doi={10.48550/arXiv.2305.18811},
10}

or

Wenjie Du. (2023). PyPOTS: a Python toolbox for data mining on Partially-Observed Time Series. arXiv, abs/2305.18811. https://doi.org/10.48550/arXiv.2305.18811

โ– Contribution#

Youโ€™re very welcome to contribute to this exciting project!

By committing your code, youโ€™ll

  1. make your well-established model out-of-the-box for PyPOTS users to run, and help your work obtain more exposure and impact. Take a look at our inclusion criteria. You can utilize the template folder in each task package (e.g. pypots/imputation/template) to quickly start;

  2. become one of PyPOTS contributors and be listed as a volunteer developer on the PyPOTS website;

  3. get mentioned in our release notes;

You can also contribute to PyPOTS by simply staring๐ŸŒŸ this repo to help more people notice it. Your star is your recognition to PyPOTS, and it matters!

The lists of PyPOTS stargazers and forkers are shown below, and weโ€™re so proud to have more and more awesome users, as well as more bright โœจstars:

PyPOTS stargazers PyPOTS forkers

๐Ÿ‘€ Check out a full list of our usersโ€™ affiliations on PyPOTS website here !

โ– Community#

We care about the feedback from our users, so weโ€™re building PyPOTS community on

If you have any suggestions or want to contribute ideas or share time-series related papers, join us and tell. PyPOTS community is open, transparent, and surely friendly. Letโ€™s work together to build and improve PyPOTS!