Algorithms based on Maximum Mean Discrepancy to detect changes in time series.
This repository contains the implementation of the HKCUSUM algorithm and experiments described in the paper MMD-based Sequential Change Detection with Reduced False Alarm Rate, Thanh Lam Dang, Christophe Dousson, Sandrine Vaton, Thierry Chonavel. Citation incoming.
- Through the package
online_cdprovide the implementation of different CUSUM-based algorithms for sequential change detection in time series. - Present a performance comparison between the algorithm HKCUSUM proposed in the article and other CUSUM algorithms.
- Allow the simulation results presented in the paper to be reproducible for further research.
The project is organised as follows:
| Directory | Contents |
|---|---|
simulation/ |
Notebooks used to run experiments on synthetic data |
src/main.py |
Example that shows the usage of online-cd package on synthetic data |
src/online_cd |
Package for online change detection in time series |
src/online_cd/detectors |
Detectors that verify whether an observation is abnormal |
src/online_cd/models |
Models that compute anomaly scores for detectors |
src/online_cd/processors |
Data preprocessing before running detectors |
src/online_cd/utils |
Utils classes for different tasks |
The online_cd package is written in Python3. The simulation notebooks are written in Julia.
To build the online_cd package or reproduce experiments on real-world data, please install the Python modules required by running pip install -r requirements.txt inside the folder.
A complete detection process (data preparation, model initialisation, execution, analysis of results) can then be executed from a command line using the main.py executable.
To reproduce the simulation results, specifically Table I, Figure 1 and Table II, run the notebooks in the simulation folder.