Skip to main content

Flare-Sensitive Clustering based on HDBSCAN*.

Project description

PyPI version Tests DOI

FLASC: Flare-Sensitive Clustering

FLASC - Flare-Sensitive Clustering, adds an efficient post-processing step to the HDBSCAN* density-based clustering algorithm to detect branching structures within clusters.

The algorithm adds two parameters that may need tuning with respect to HDBSCAN*, but both are intuitive to tune: minimum branch size and branch selection strategy.

How to use FLASC

The FLASC package is closely based on the HDBSCAN* package and supports the same API, except sparse inputs, which are not supported yet.

from flasc import FLASC
import numpy as np
import seaborn as sns
import matplotlib.pyplot as plt

data = np.load('./notebooks/data/flared/flared_clusterable_data.npy')
clusterer = FLASC(min_cluster_size=15)
clusterer.fit(data)
colors = sns.color_palette('tab10', 10)
point_colors = [
  sns.desaturate(colors[l], p)
  for l, p in zip(clusterer.labels_, clusterer.probabilities_)
]
plt.scatter(data[:, 0], data[:, 1], 2, point_colors, alpha=0.5)
plt.axis('off')
plt.show()

Example point cloud

Example Notebooks

A notebook demonstrating how the algorithm works is available at How FLASC Works. The other notebooks demonstrate the algorithm on several data sets and contain the analyses presented in our paper.

Installing

Binary wheels are available on PyPI. Presuming you have an up-to-date pip:

pip install pyflasc

For a manual install of the latest code directly from GitHub:

pip install --upgrade git+https://github.com/vda-lab/pyflasc.git#egg=pyflasc

Alternatively download the package, install requirements, and manually run the installer:

wget https://github.com/vda-lab/pyflasc/archive/main.zip
unzip main.zip
rm main.zip
cd flasc-main

pip install -t .

Citing

Please cite our publication when using the algorithm:

Bot DM, Peeters J, Liesenborgs J, Aerts J. 2025. FLASC: a flare-sensitive
clustering algorithm. PeerJ Computer Science 11:e2792
https://doi.org/10.7717/peerj-cs.2792 

in bibtex:

@article{bot2025flasc,
  title   = {{FLASC: a flare-sensitive clustering algorithm}},
  author  = {Bot, Dani{\"{e}}l M. and Peeters, Jannes and Liesenborgs, Jori and Aerts, Jan},
  year    = {2025},
  month   = {apr},
  journal = {PeerJ Comput. Sci.},
  volume  = {11},
  pages   = {e2792},
  issn    = {2376-5992},
  doi     = {10.7717/peerj-cs.2792},
  url     = {https://peerj.com/articles/cs-2792},
}

The FLASC algorithm and software package is closely related to McInnes et al.'s HDBSCAN* software package. We refer to their Journal of Open Source Software article and paper in the ICDMW 2017 proceedings for information on how to cite their software package and high-performance algorithm.

Licensing

The FLASC package has a 3-Clause BSD license.

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

pyflasc-0.1.4.tar.gz (43.9 kB view details)

Uploaded Source

Built Distributions

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

pyflasc-0.1.4-cp314-cp314-win_amd64.whl (116.2 kB view details)

Uploaded CPython 3.14Windows x86-64

pyflasc-0.1.4-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (490.9 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.17+ x86-64

pyflasc-0.1.4-cp314-cp314-macosx_11_0_arm64.whl (120.9 kB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

pyflasc-0.1.4-cp313-cp313-win_amd64.whl (114.0 kB view details)

Uploaded CPython 3.13Windows x86-64

pyflasc-0.1.4-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (494.7 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

pyflasc-0.1.4-cp313-cp313-macosx_11_0_arm64.whl (120.5 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

pyflasc-0.1.4-cp312-cp312-win_amd64.whl (114.1 kB view details)

Uploaded CPython 3.12Windows x86-64

pyflasc-0.1.4-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (503.8 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

pyflasc-0.1.4-cp312-cp312-macosx_11_0_arm64.whl (120.9 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

pyflasc-0.1.4-cp311-cp311-win_amd64.whl (113.3 kB view details)

Uploaded CPython 3.11Windows x86-64

pyflasc-0.1.4-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (483.7 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

pyflasc-0.1.4-cp311-cp311-macosx_11_0_arm64.whl (120.1 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

pyflasc-0.1.4-cp310-cp310-win_amd64.whl (113.3 kB view details)

Uploaded CPython 3.10Windows x86-64

pyflasc-0.1.4-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl (463.3 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

pyflasc-0.1.4-cp310-cp310-macosx_11_0_arm64.whl (120.4 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file pyflasc-0.1.4.tar.gz.

File metadata

  • Download URL: pyflasc-0.1.4.tar.gz
  • Upload date:
  • Size: 43.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyflasc-0.1.4.tar.gz
Algorithm Hash digest
SHA256 5eb290382e78df4b13f48f25a07b4adf4e59057c4a8e7aed8a5db9f51fb0c9be
MD5 890fb5e83b7b3e66418c1e0d970356bc
BLAKE2b-256 1b3e324e8bddb8772ae0c619e76160499e4b253675e3cae22f4588fdd10b8c79

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4.tar.gz:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: pyflasc-0.1.4-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 116.2 kB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyflasc-0.1.4-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 24ba0e90bd38f125d30b46f34d8281f00c5c4aa4f65d347174c1f8c8e0dde8de
MD5 cf5099d2a56f6b028e6727ca7426cd56
BLAKE2b-256 dee3a1e716f1458ccc234a82726f7c5e28984fb76ab92e3613a8889a39f66121

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp314-cp314-win_amd64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 861d685bf4e0f986d8992b594e7f79660a234be8654a02d8465fec5ae71c6a09
MD5 c68117b4bcafd40e9bf51c099c64dde4
BLAKE2b-256 f6d6b8f28bbd5507560c21aaa0481692f7dcfa2a92997362869f567ae9d0a20c

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp314-cp314-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 1ff42d6efc2b2f7e357a37cc3e8f39a58137320123bee016c721a9d332cab938
MD5 2c484037a4bd9e8272e3011673f839ce
BLAKE2b-256 6730f2ab537cd7c9000e389cfca21af867609eabc08ea05ec3f6c4f28975ce87

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp314-cp314-macosx_11_0_arm64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: pyflasc-0.1.4-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 114.0 kB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyflasc-0.1.4-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 8dfb2af6ef617b7fed97aaa92a71650955bc317f2f16cb65fa529c049735a665
MD5 13aafd291ec724d6a04f39e2073d084c
BLAKE2b-256 7c2966105cb64e7c861c208c2d5dc7ef732bdd139b1a9e94d9559f52f411bb0e

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp313-cp313-win_amd64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 d8e8e4091bd11a0143c6de5d6ce0fcd4ede45d5007dbb9d6f7c0e697bbf373da
MD5 857fe63e63df222218b1417e1d63a639
BLAKE2b-256 d2fab8d8db82a8d11d4bcc9b2c2e6ef21986e51d47efb225a1e3168d991527b3

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp313-cp313-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 cf04f264a3c07457daac334b3ff8f3c1448b7f8ede2af3d7a31d7fdc3059c7db
MD5 0ce4e6553d7f283e68bf5e0f63cd1c58
BLAKE2b-256 d3896af6b477833c8831b7bd7f5b8586668f5253423c092c518a0b21d29383ce

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp313-cp313-macosx_11_0_arm64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: pyflasc-0.1.4-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 114.1 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyflasc-0.1.4-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 3effe81c2f1cc5e534d20d79a31f96e66a60065230cbddb39eba9d4af3887475
MD5 9b850889018b085b11f5335806a3d7da
BLAKE2b-256 72bdfbeed7b89d92b61fc60da7a1790ec8dd4cff0a10af179041cfcad952b09d

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp312-cp312-win_amd64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 d03050398ffc19407cd24949f2b8fcaef60dcc5143e453f83205dab8b5f90ecd
MD5 887d854980ecc09e0a7c7950846d5b22
BLAKE2b-256 82b7dec302f6102458fb82e2772f30b1c774f14ab1837bc4d5a983c47286c5f6

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 e9b626330f603c41652d3929be33b1a98270371bdc66b6d9993674bb62a7681b
MD5 863c5285549e7fab6b87b2c04a71dd0e
BLAKE2b-256 94e4b99bfd258a33fa3363bacdd02aaa521a373d53991e8d8fd89ca240f63bc0

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp312-cp312-macosx_11_0_arm64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: pyflasc-0.1.4-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 113.3 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyflasc-0.1.4-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 3ab40979518e3d7ae2fd96ac5ea55b31da0aa0326425bd4815aa4d371e7ad957
MD5 94b5e5837aa7ae36b4503b159b41f105
BLAKE2b-256 2217f8156b6ab63b4dbc0349395dcd196c865f4631045eabd85bd0f85e39de6c

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp311-cp311-win_amd64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 d5a798aa7fadc745fc159059fb196bebe9785f836b1dbef6c5d1d4c4bcf1ec27
MD5 6a85d5ff00f132fa3e1f174d0b78fad6
BLAKE2b-256 09a8741e874072ce111b1d1c015526632dc31adb1d2065348c2083525be04b67

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 38346fa999fe2da75cac08d42616aa98c6d35b821da30edf106deb91f5edbf80
MD5 a7c5bc809abad04807825d13559bee0d
BLAKE2b-256 07d4789f87ff810a9d9a346a1ea2cc40956f0b12bd4cc6894712472f68a136a0

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp311-cp311-macosx_11_0_arm64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: pyflasc-0.1.4-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 113.3 kB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyflasc-0.1.4-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 3cc64cc445326220a41ca5c285eb1c26d72833372e96dbbea723714eab3972b4
MD5 5acc5a289e8e03bb5b327fdc160db08c
BLAKE2b-256 c269fc7f86b54f5d8a97f1b6942c43446e8428eba928a8487940c369c156b329

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp310-cp310-win_amd64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Algorithm Hash digest
SHA256 1cd25f6fbe17af77664e39c3642d51ee8db8babcad9201607c019ce22938a30f
MD5 05360a94b5f0f1c7584e6d9f26d4e8b2
BLAKE2b-256 dea09cf59ff586178823639eac69ae797eb792f104131b47a890eb11df543167

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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

File details

Details for the file pyflasc-0.1.4-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for pyflasc-0.1.4-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 5483a6ed66bc95a3ce7fb20b46009c8d3ecf4ab50f8ccc9e348bc10dd0ff1fae
MD5 f280dee1d7fd94a9b68a9facc3fbff4b
BLAKE2b-256 45b569b1076f86a25858ca583df25788fbce86fb98ca2e5291cfbcbc005470af

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyflasc-0.1.4-cp310-cp310-macosx_11_0_arm64.whl:

Publisher: Publish.yml on vda-lab/pyflasc

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