Skip to main content

Welcome to Roerich

PyPI version Documentation Downloads License

Roerich is a python library for online and offline change point detection for time series analysis, signal processing, and segmentation. It was named after the painter Nicholas Roerich, known as the Master of the Mountains. Read more at: https://www.roerich.org.

Fragment of "Himalayas", 1933

Currently, the library contains official implementations of change point detection algorithms based on direct density ratio estimation from the following articles:

  • Mikhail Hushchyn and Andrey Ustyuzhanin. “Generalization of Change-Point Detection in Time Series Data Based on Direct Density Ratio Estimation.” J. Comput. Sci. 53 (2021): 101385. [journal] [arxiv]
  • Mikhail Hushchyn, Kenenbek Arzymatov and Denis Derkach. “Online Neural Networks for Change-Point Detection.” ArXiv abs/2010.01388 (2020). [arxiv]

Dependencies and install

pip install roerich

or

git clone https://github.com/HSE-LAMBDA/roerich.git
cd roerich
pip install -e .

Basic usage

(See more examples in the documentation.)

The following code snippet generates a noisy synthetic data, performs change point detection, and displays the results. If you use own dataset, make sure that it has a shape (seq_len, n_dims).

import roerich
from roerich.change_point import ChangePointDetectionClassifier

# generate time series
X, cps_true = roerich.generate_dataset(period=200, N_tot=2000)

# detection
# base_classifier = 'logreg', 'qda', 'dt', 'rf', 'mlp', 'knn', 'nb'
# metric = 'klsym', 'pesym', 'jsd', 'mmd', 'fd'
cpd = ChangePointDetectionClassifier(base_classifier='mlp', metric='klsym', window_size=100)
score, cps_pred = cpd.predict(X)

# visualization
roerich.display(X, cps_true, score, cps_pred)

Support

Generic badge Generic badge Generic badge Generic badge

Thanks to all our contributors

Metadata

Release files for roerich 0.6.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for roerich 0.6.0
File Size Uploaded Provenance Actions
roerich-0.6.0.tar.gz 22.8 kB Without provenance Details for roerich-0.6.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for roerich 0.6.0
File Interpreter ABI Platform Actions
roerich-0.6.0-py3-none-any.whl Python 3 none any Details for roerich-0.6.0-py3-none-any.whl

Total release size: 59.1 kB

Release files / roerich-0.6.0.tar.gz

Download URL roerich-0.6.0.tar.gz
Size 22.8 kB
Tags Source
SHA-256 checksum
How to use checksums
10ae9791adfb4fa0d6f83261b7895c1fd45745342c14d5fef7b3d5bcbf40569c
BLAKE2b-256 checksum
How to use checksums
24473937b28ea505a13e813260803544bcc404497bcaac4be3e1b74c447cc361
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Release files / roerich-0.6.0-py3-none-any.whl

Download URL roerich-0.6.0-py3-none-any.whl
Size 36.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
5e28671f200b2d095e9b01be51bb00217c6ecfb877d42437e7e8bf0a60808280
BLAKE2b-256 checksum
How to use checksums
10d96f2b634558bc3d2bbab7cfc3fec76f1819cf21ddcc1c794f50d7734e112b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.9.16

Security for roerich 0.6.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page