Skip to main content

SCAMPI - Fast Pattern Discovery in Massive Time Series

This repository provides the reference implementation and experimental material for the paper “SCAMPI - Fast Pattern Discovery in Massive Time Series”.

Repository Structure

This repository contains the full framework, benchmark datasets, and reproducible experiments used in the evaluation.

  • scampi/
    Core implementation of SCAMPI and the k-Motiflets algorithm.

  • benchmarks/
    Benchmark scripts and helpers. Command-line benchmark callers live in benchmarks/cli/, conversion scripts in benchmarks/converters/, reusable benchmark runners in benchmarks/runners/, and plotting scripts in benchmarks/plots/.

  • notebooks/
    Jupyter notebooks demonstrating typical use cases and reproducing paper figures.

  • datasets/momp/
    large-Scale Benchmark time series datasets used throughout the paper.
    Please see https://sites.google.com/view/momp2024, too

  • tests/
    Unit tests for the implementation.

  • tests/results/
    Benchmark output CSVs and converted result files.

SCAMPI (SCalable Anytime Mining of Patterns In time series)

This paper introduces SCAMPI.

Installation

The easiest is to use pip to install motiflets.

a) Install using pip

BLINDED

You can also install the project from source.

b) Build from Source

Clone the repository:

git clone https://github.com/patrickzib/scampi.git
cd scampi

Install the package:

pip install .

Usage Example

from scampi.scampi import *

ml = SCAMPI(
    ds_name,  # dataset name
    series,   # time series data
    n_jobs,    # number of CPU cores
    scampi_max_memory = "1 GB",  # max-memory to use for SCAMPI
    scampi_delta = "0.1" 
)

k_max = 20  # maximum motif set size to consider
motif_length = 100  # length of the motifs to search for
top_N = 10  # number of top motif sets to return

dists, candidates, elbow_points = ml.fit_k_elbow(
    k_max,
    motif_length,
    top_N=top_N
)

ml.plot_motifset()

Benchmark Scripts

The MOMP benchmark entry points are:

python benchmarks/cli/run_momp_benchmarks.py --list-methods
python benchmarks/cli/run_momp_benchmarks.py --methods faiss-hnsw

Metadata

Release files for scampi 0.2.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 scampi 0.2.0
File Size Uploaded
scampi-0.2.0.tar.gz 105.8 kB Details

Release files / scampi-0.2.0.tar.gz

Download URL scampi-0.2.0.tar.gz
Size 105.8 kB
Tags Source
SHA-256 checksum
How to use checksums
aa5edd12b0c0a0a40f73a7ee5142af5b06776ed43e71c2784b704d4c91d1bb55
BLAKE2b-256 checksum
How to use checksums
0bd75284817bebdd33657789be663b78bca8e7fd5aea7957b51149d457bfb57e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.12.8

Release history Release notifications | RSS feed

This release

0.2.0 This release

1 release file

0.1.1

1 release file

0.1.0

1 release file

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