Skip to main content

Unified Python package for gradual pattern mining with multiple algorithms

Project description

GPMF — Gradual Pattern Mining Framework

A Python library for gradual pattern mining with a unified scikit-learn-style API.

Installation

pip install gradual-mining

Pre-built wheels are available for Linux, macOS and Windows (x86_64 and arm64). The ParaMiner algorithm includes an optional Rust extension for multi-core acceleration — it is compiled into the wheel automatically and falls back to a pure-Python implementation if unavailable.

Quick start

from gpmf.algorithms.graank import GRAANK

model = GRAANK(min_support=0.5)
patterns = model.mine("data.csv")

for p in patterns:
    print(p.to_string(), ":", p.support)

All algorithms share the same interface:

model.fit(data)              # data can be a CSV path, DataFrame, or GradualDataset
patterns = model.get_patterns()
result   = model.get_result()  # includes execution time, metadata

ParaMiner with Rust acceleration

from gpmf.algorithms.closed.paraminer_algorithm import ParaMiner

model = ParaMiner(min_support=0.5, use_rust=True, num_threads=4)
patterns = model.mine("data.csv")

Available algorithms

Algorithm Key Authors Reference
GRAANK graank Laurent, Lesot & Rifqi (2010) paper
GRITE grite Di-Jorio, Laurent & Teisseire (2009) paper
SGrite sgrite / sgopt / sg1 / sgb1 / sgb2 Tayou Djamegni, Tabueu Fotso & Kenmogne (2021) paper
ParaMiner paraminer Négrevergne, Termier, Rousset & Méhaut (2014) paper
ACO-GRAANK ant-graank Owuor, Laurent & Orero (2019) paper
TGrad tgrad Owuor, Laurent & Orero (2019) paper
MSGP msgp Lonlac, Doniec, Lujak & Lecoeuche (2020) paper
GLCM glcm Do, Termier, Laurent et al. (2015) paper
PGLCM pglcm Do, Termier, Laurent et al. (2015) paper

Pruning criterion

Criterion Applies to Authors
Row–Column pruning (--use-rc-pruning) GRITE, SGrite, GLCM Kamga Nguifo, Lonlac, Fleury & Mephu Nguifo (2025) — paper

CLI

# List available algorithms
gradual-mine --list

# Mine patterns
gradual-mine graank data.csv --min-support 0.5

# Save results
gradual-mine graank data.csv --min-support 0.5 --output results.json --csv results.csv

# Parallel execution
gradual-mine paraminer data.csv --min-support 0.5 --n-jobs -1

Development

git clone https://github.com/your-org/gpmf
cd gpmf
uv sync --dev
uv run pytest

To build with the Rust extension locally:

pip install maturin
maturin develop --release

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gradual_mining-0.3.2.tar.gz (54.1 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

gradual_mining-0.3.2-cp39-abi3-win_amd64.whl (309.0 kB view details)

Uploaded CPython 3.9+Windows x86-64

gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (434.2 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ x86-64

gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (427.8 kB view details)

Uploaded CPython 3.9+manylinux: glibc 2.17+ ARM64

gradual_mining-0.3.2-cp39-abi3-macosx_11_0_arm64.whl (395.2 kB view details)

Uploaded CPython 3.9+macOS 11.0+ ARM64

File details

Details for the file gradual_mining-0.3.2.tar.gz.

File metadata

  • Download URL: gradual_mining-0.3.2.tar.gz
  • Upload date:
  • Size: 54.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for gradual_mining-0.3.2.tar.gz
Algorithm Hash digest
SHA256 0136888764b943ecf5784ee8fdecaeba81a9d90160e728dfc924826143094e15
MD5 d189e01a72c1494369572d20cf8fa6d7
BLAKE2b-256 5656496af0c040b81b5aa3dfa342db28c78ec6ff724fb685e1f940afcd5eeb04

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradual_mining-0.3.2.tar.gz:

Publisher: release.yml on kndbvortex/gpmf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gradual_mining-0.3.2-cp39-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for gradual_mining-0.3.2-cp39-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 9f41f213329e657ea4ae849decbecb78ecac7405db16efa85049c1e7ae987c67
MD5 0182d5effd7f25c88722e6d5095db903
BLAKE2b-256 f7eadc90d66d085062b2bce7f6cc99239a9baba609938890a5b58a83983e13d4

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradual_mining-0.3.2-cp39-abi3-win_amd64.whl:

Publisher: release.yml on kndbvortex/gpmf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e3e5f73e8c7a909e837b0d139cc58a0d897ac9bd98fdb977a5da6165d873c1b0
MD5 4dc799673826d379f62e19ee1d886544
BLAKE2b-256 cde6ec918172cbae89bcc093ce36fb996df3b19f876b86ba8fde2d3bf5bed1f5

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: release.yml on kndbvortex/gpmf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 80dff0fcae0aa62a1434711a333b41c2e8f7a30af1bf8a0dbec2425802e2485c
MD5 97d9e58782e3a8b2692fd738b0d191bd
BLAKE2b-256 a27bca50cdba6e353578e6dedee02a47c8ade2a7d01392f6c2cbb92e55d7bd3f

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradual_mining-0.3.2-cp39-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl:

Publisher: release.yml on kndbvortex/gpmf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file gradual_mining-0.3.2-cp39-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for gradual_mining-0.3.2-cp39-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 e7f89c971a0617e99a5e9d5102b4e8842c37a1b7179987201754c0eb6d95d4a0
MD5 2424fc701608a92db8d1c2098878e391
BLAKE2b-256 777596f72e8a13208eb72148d44937e340d81494728ce485b618102050134f33

See more details on using hashes here.

Provenance

The following attestation bundles were made for gradual_mining-0.3.2-cp39-abi3-macosx_11_0_arm64.whl:

Publisher: release.yml on kndbvortex/gpmf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page