.. image:: https://img.shields.io/pypi/v/hdbscan.svg
:target: https://pypi.python.org/pypi/hdbscan/
:alt: PyPI Version
.. image:: https://anaconda.org/conda-forge/hdbscan/badges/version.svg
:target: https://anaconda.org/conda-forge/hdbscan
:alt: Conda-forge Version
.. image:: https://anaconda.org/conda-forge/hdbscan/badges/downloads.svg
:target: https://anaconda.org/conda-forge/hdbscan
:alt: Conda-forge downloads
.. image:: https://img.shields.io/pypi/l/hdbscan.svg
:target: https://github.com/scikit-learn-contrib/hdbscan/blob/master/LICENSE
:alt: License
.. image:: https://travis-ci.org/scikit-learn-contrib/hdbscan.svg
:target: https://travis-ci.org/scikit-learn-contrib/hdbscan
:alt: Travis Build Status
.. image:: https://codecov.io/gh/scikit-learn-contrib/hdbscan/branch/master/graph/badge.svg
:target: https://codecov.io/gh/scikit-learn-contrib/hdbscan
:alt: Test Coverage
.. image:: https://readthedocs.org/projects/hdbscan/badge/?version=latest
:target: https://hdbscan.readthedocs.org
:alt: Docs
.. image:: http://joss.theoj.org/papers/10.21105/joss.00205/status.svg
:target: http://joss.theoj.org/papers/10.21105/joss.00205
:alt: JOSS article
.. image:: https://mybinder.org/badge.svg
:target: https://mybinder.org/v2/gh/scikit-learn-contrib/hdbscan
:alt: Launch example notebooks in Binder
=======
HDBSCAN
=======
HDBSCAN - Hierarchical Density-Based Spatial Clustering of Applications
with Noise. Performs DBSCAN over varying epsilon values and integrates
the result to find a clustering that gives the best stability over epsilon.
This allows HDBSCAN to find clusters of varying densities (unlike DBSCAN),
and be more robust to parameter selection.
In practice this means that HDBSCAN returns a good clustering straight
away with little or no parameter tuning -- and the primary parameter,
minimum cluster size, is intuitive and easy to select.
HDBSCAN is ideal for exploratory data analysis; it's a fast and robust
algorithm that you can trust to return meaningful clusters (if there
are any).
Based on the papers:
McInnes L, Healy J. *Accelerated Hierarchical Density Based Clustering*
In: 2017 IEEE International Conference on Data Mining Workshops (ICDMW), IEEE, pp 33-42.
2017 `[pdf] <http://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=8215642>`_
R. Campello, D. Moulavi, and J. Sander, *Density-Based Clustering Based on
Hierarchical Density Estimates*
In: Advances in Knowledge Discovery and Data Mining, Springer, pp 160-172.
2013
Documentation, including tutorials, are available on ReadTheDocs at http://hdbscan.readthedocs.io/en/latest/ .
Notebooks `comparing HDBSCAN to other clustering algorithms <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Comparing%20Clustering%20Algorithms.ipynb>`_, explaining `how HDBSCAN works <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/How%20HDBSCAN%20Works.ipynb>`_ and `comparing performance with other python clustering implementations <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Benchmarking%20scalability%20of%20clustering%20implementations-v0.7.ipynb>`_ are available.
------------------
How to use HDBSCAN
------------------
The hdbscan package inherits from sklearn classes, and thus drops in neatly
next to other sklearn clusterers with an identical calling API. Similarly it
supports input in a variety of formats: an array (or pandas dataframe, or
sparse matrix) of shape ``(num_samples x num_features)``; an array (or sparse matrix)
giving a distance matrix between samples.
.. code:: python
import hdbscan
from sklearn.datasets import make_blobs
data, _ = make_blobs(1000)
clusterer = hdbscan.HDBSCAN(min_cluster_size=10)
cluster_labels = clusterer.fit_predict(data)
-----------
Performance
-----------
Significant effort has been put into making the hdbscan implementation as fast as
possible. It is `orders of magnitude faster than the reference implementation <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Python%20vs%20Java.ipynb>`_ in Java,
and is currently faster than highly optimized single linkage implementations in C and C++.
`version 0.7 performance can be seen in this notebook <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Benchmarking%20scalability%20of%20clustering%20implementations-v0.7.ipynb>`_ .
In particular `performance on low dimensional data is better than sklearn's DBSCAN <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Benchmarking%20scalability%20of%20clustering%20implementations%202D%20v0.7.ipynb>`_ ,
and via support for caching with joblib, re-clustering with different parameters
can be almost free.
------------------------
Additional functionality
------------------------
The hdbscan package comes equipped with visualization tools to help you
understand your clustering results. After fitting data the clusterer
object has attributes for:
* The condensed cluster hierarchy
* The robust single linkage cluster hierarchy
* The reachability distance minimal spanning tree
All of which come equipped with methods for plotting and converting
to Pandas or NetworkX for further analysis. See the notebook on
`how HDBSCAN works <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/How%20HDBSCAN%20Works.ipynb>`_ for examples and further details.
The clusterer objects also have an attribute providing cluster membership
strengths, resulting in optional soft clustering (and no further compute
expense). Finally each cluster also receives a persistence score giving
the stability of the cluster over the range of distance scales present
in the data. This provides a measure of the relative strength of clusters.
-----------------
Outlier Detection
-----------------
The HDBSCAN clusterer objects also support the GLOSH outlier detection algorithm.
After fitting the clusterer to data the outlier scores can be accessed via the
``outlier_scores_`` attribute. The result is a vector of score values, one for
each data point that was fit. Higher scores represent more outlier like objects.
Selecting outliers via upper quantiles is often a good approach.
Based on the paper:
R.J.G.B. Campello, D. Moulavi, A. Zimek and J. Sander
*Hierarchical Density Estimates for Data Clustering, Visualization, and Outlier Detection*,
ACM Trans. on Knowledge Discovery from Data, Vol 10, 1 (July 2015), 1-51.
---------------------
Robust single linkage
---------------------
The hdbscan package also provides support for the *robust single linkage*
clustering algorithm of Chaudhuri and Dasgupta. As with the HDBSCAN
implementation this is a high performance version of the algorithm
outperforming scipy's standard single linkage implementation. The
robust single linkage hierarchy is available as an attribute of
the robust single linkage clusterer, again with the ability to plot
or export the hierarchy, and to extract flat clusterings at a given
cut level and gamma value.
Example usage:
.. code:: python
import hdbscan
from sklearn.datasets import make_blobs
data, _ = make_blobs(1000)
clusterer = hdbscan.RobustSingleLinkage(cut=0.125, k=7)
cluster_labels = clusterer.fit_predict(data)
hierarchy = clusterer.cluster_hierarchy_
alt_labels = hierarchy.get_clusters(0.100, 5)
hierarchy.plot()
Based on the paper:
K. Chaudhuri and S. Dasgupta.
*"Rates of convergence for the cluster tree."*
In Advances in Neural Information Processing Systems, 2010.
----------------
Branch detection
----------------
The hdbscan package supports a branch-detection post-processing step
by `Bot et al. <https://arxiv.org/abs/2311.15887>`_. Cluster shapes,
such as branching structures, can reveal interesting patterns
that are not expressed in density-based cluster hierarchies. The
BranchDetector class mimics the HDBSCAN API and can be used to
detect branching hierarchies in clusters. It provides condensed
branch hierarchies, branch persistences, and branch memberships and
supports joblib's caching functionality. A notebook
`demonstrating the BranchDetector is available <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/How%20to%20detect%20branches.ipynb>`_.
Example usage:
.. code:: python
import hdbscan
from sklearn.datasets import make_blobs
data, _ = make_blobs(1000)
clusterer = hdbscan.HDBSCAN(branch_detection_data=True).fit(data)
branch_detector = hdbscan.BranchDetector().fit(clusterer)
branch_detector.cluster_approximation_graph_.plot(edge_width=0.1)
Based on the paper:
D. M. Bot, J. Peeters, J. Liesenborgs and J. Aerts
*"FLASC: A Flare-Sensitive Clustering Algorithm: Extending HDBSCAN\* for Detecting Branches in Clusters"*
Arxiv 2311.15887, 2023.
----------
Installing
----------
Easiest install, if you have Anaconda (thanks to conda-forge which is awesome!):
.. code:: bash
conda install -c conda-forge hdbscan
PyPI install, presuming you have an up to date pip:
.. code:: bash
pip install hdbscan
Binary wheels for a number of platforms are available thanks to the work of
Ryan Helinski <rlhelinski@gmail.com>.
If pip is having difficulties pulling the dependencies then we'd suggest to first upgrade
pip to at least version 10 and try again:
.. code:: bash
pip install --upgrade pip
pip install hdbscan
Otherwise install the dependencies manually using anaconda followed by pulling hdbscan from pip:
.. code:: bash
conda install cython
conda install numpy scipy
conda install scikit-learn
pip install hdbscan
For a manual install of the latest code directly from GitHub:
.. code:: bash
pip install --upgrade git+https://github.com/scikit-learn-contrib/hdbscan.git#egg=hdbscan
Alternatively download the package, install requirements, and manually run the installer:
.. code:: bash
wget https://github.com/scikit-learn-contrib/hdbscan/archive/master.zip
unzip master.zip
rm master.zip
cd hdbscan-master
pip install -r requirements.txt
python setup.py install
-----------------
Running the Tests
-----------------
The package tests can be run after installation using the command:
.. code:: bash
nosetests -s hdbscan
or, if ``nose`` is installed but ``nosetests`` is not in your ``PATH`` variable:
.. code:: bash
python -m nose -s hdbscan
If one or more of the tests fail, please report a bug at https://github.com/scikit-learn-contrib/hdbscan/issues/new
--------------
Python Version
--------------
The hdbscan library supports both Python 2 and Python 3. However we recommend Python 3 as the better option if it is available to you.
----------------
Help and Support
----------------
For simple issues you can consult the `FAQ <https://hdbscan.readthedocs.io/en/latest/faq.html>`_ in the documentation.
If your issue is not suitably resolved there, please check the `issues <https://github.com/scikit-learn-contrib/hdbscan/issues>`_ on github. Finally, if no solution is available there feel free to `open an issue <https://github.com/scikit-learn-contrib/hdbscan/issues/new>`_ ; the authors will attempt to respond in a reasonably timely fashion.
------------
Contributing
------------
We welcome contributions in any form! Assistance with documentation, particularly expanding tutorials,
is always welcome. To contribute please `fork the project <https://github.com/scikit-learn-contrib/hdbscan/issues#fork-destination-box>`_ make your changes and submit a pull request. We will do our best to work through any issues with
you and get your code merged into the main branch.
------
Citing
------
If you have used this codebase in a scientific publication and wish to cite it, please use the `Journal of Open Source Software article <http://joss.theoj.org/papers/10.21105/joss.00205>`_.
L. McInnes, J. Healy, S. Astels, *hdbscan: Hierarchical density based clustering*
In: Journal of Open Source Software, The Open Journal, volume 2, number 11.
2017
.. code:: bibtex
@article{mcinnes2017hdbscan,
title={hdbscan: Hierarchical density based clustering},
author={McInnes, Leland and Healy, John and Astels, Steve},
journal={The Journal of Open Source Software},
volume={2},
number={11},
pages={205},
year={2017}
}
To reference the high performance algorithm developed in this library please cite our paper in ICDMW 2017 proceedings.
McInnes L, Healy J. *Accelerated Hierarchical Density Based Clustering*
In: 2017 IEEE International Conference on Data Mining Workshops (ICDMW), IEEE, pp 33-42.
2017
.. code:: bibtex
@inproceedings{mcinnes2017accelerated,
title={Accelerated Hierarchical Density Based Clustering},
author={McInnes, Leland and Healy, John},
booktitle={Data Mining Workshops (ICDMW), 2017 IEEE International Conference on},
pages={33--42},
year={2017},
organization={IEEE}
}
If you used the branch-detection functionality in this codebase in a scientific publication and which to cite it, please use the `Arxiv preprint <https://arxiv.org/abs/2311.15887>`_:
D. M. Bot, J. Peeters, J. Liesenborgs and J. Aerts
*"FLASC: A Flare-Sensitive Clustering Algorithm: Extending HDBSCAN\* for Detecting Branches in Clusters"*
Arxiv 2311.15887, 2023.
.. code:: bibtex
@misc{bot2023flasc,
title={FLASC: A Flare-Sensitive Clustering Algorithm: Extending HDBSCAN* for Detecting Branches in Clusters},
author={D. M. Bot and J. Peeters and J. Liesenborgs and J. Aerts},
year={2023},
eprint={2311.15887},
archivePrefix={arXiv},
primaryClass={cs.LG},
url={https://arxiv.org/abs/2311.15887},
}
---------
Licensing
---------
The hdbscan package is 3-clause BSD licensed. Enjoy.
Raw data
{
"_id": null,
"home_page": "http://github.com/scikit-learn-contrib/hdbscan",
"name": "hdbscan",
"maintainer": "Leland McInnes",
"docs_url": null,
"requires_python": null,
"maintainer_email": "leland.mcinnes@gmail.com",
"keywords": "cluster clustering density hierarchical",
"author": null,
"author_email": null,
"download_url": "https://files.pythonhosted.org/packages/f4/a1/a8f1d60a44ae9f720e5c77a30c2d01962f3ff1d2de81f0eb640354c400b2/hdbscan-0.8.39.tar.gz",
"platform": null,
"description": ".. image:: https://img.shields.io/pypi/v/hdbscan.svg\n :target: https://pypi.python.org/pypi/hdbscan/\n :alt: PyPI Version\n.. image:: https://anaconda.org/conda-forge/hdbscan/badges/version.svg\n :target: https://anaconda.org/conda-forge/hdbscan\n :alt: Conda-forge Version\n.. image:: https://anaconda.org/conda-forge/hdbscan/badges/downloads.svg\n :target: https://anaconda.org/conda-forge/hdbscan\n :alt: Conda-forge downloads\n.. image:: https://img.shields.io/pypi/l/hdbscan.svg\n :target: https://github.com/scikit-learn-contrib/hdbscan/blob/master/LICENSE\n :alt: License\n.. image:: https://travis-ci.org/scikit-learn-contrib/hdbscan.svg\n :target: https://travis-ci.org/scikit-learn-contrib/hdbscan\n :alt: Travis Build Status\n.. image:: https://codecov.io/gh/scikit-learn-contrib/hdbscan/branch/master/graph/badge.svg\n :target: https://codecov.io/gh/scikit-learn-contrib/hdbscan\n :alt: Test Coverage\n.. image:: https://readthedocs.org/projects/hdbscan/badge/?version=latest\n :target: https://hdbscan.readthedocs.org\n :alt: Docs\n.. image:: http://joss.theoj.org/papers/10.21105/joss.00205/status.svg\n :target: http://joss.theoj.org/papers/10.21105/joss.00205\n :alt: JOSS article\n.. image:: https://mybinder.org/badge.svg \n :target: https://mybinder.org/v2/gh/scikit-learn-contrib/hdbscan\n :alt: Launch example notebooks in Binder\n\n\n=======\nHDBSCAN\n=======\n\nHDBSCAN - Hierarchical Density-Based Spatial Clustering of Applications\nwith Noise. Performs DBSCAN over varying epsilon values and integrates \nthe result to find a clustering that gives the best stability over epsilon.\nThis allows HDBSCAN to find clusters of varying densities (unlike DBSCAN),\nand be more robust to parameter selection.\n\nIn practice this means that HDBSCAN returns a good clustering straight\naway with little or no parameter tuning -- and the primary parameter,\nminimum cluster size, is intuitive and easy to select.\n\nHDBSCAN is ideal for exploratory data analysis; it's a fast and robust\nalgorithm that you can trust to return meaningful clusters (if there\nare any).\n\nBased on the papers:\n\n McInnes L, Healy J. *Accelerated Hierarchical Density Based Clustering* \n In: 2017 IEEE International Conference on Data Mining Workshops (ICDMW), IEEE, pp 33-42.\n 2017 `[pdf] <http://ieeexplore.ieee.org/stamp/stamp.jsp?tp=&arnumber=8215642>`_\n\n R. Campello, D. Moulavi, and J. Sander, *Density-Based Clustering Based on\n Hierarchical Density Estimates*\n In: Advances in Knowledge Discovery and Data Mining, Springer, pp 160-172.\n 2013\n \nDocumentation, including tutorials, are available on ReadTheDocs at http://hdbscan.readthedocs.io/en/latest/ . \n \nNotebooks `comparing HDBSCAN to other clustering algorithms <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Comparing%20Clustering%20Algorithms.ipynb>`_, explaining `how HDBSCAN works <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/How%20HDBSCAN%20Works.ipynb>`_ and `comparing performance with other python clustering implementations <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Benchmarking%20scalability%20of%20clustering%20implementations-v0.7.ipynb>`_ are available.\n\n------------------\nHow to use HDBSCAN\n------------------\n\nThe hdbscan package inherits from sklearn classes, and thus drops in neatly\nnext to other sklearn clusterers with an identical calling API. Similarly it\nsupports input in a variety of formats: an array (or pandas dataframe, or\nsparse matrix) of shape ``(num_samples x num_features)``; an array (or sparse matrix)\ngiving a distance matrix between samples.\n\n.. code:: python\n\n import hdbscan\n from sklearn.datasets import make_blobs\n \n data, _ = make_blobs(1000)\n \n clusterer = hdbscan.HDBSCAN(min_cluster_size=10)\n cluster_labels = clusterer.fit_predict(data)\n\n-----------\nPerformance\n-----------\n\nSignificant effort has been put into making the hdbscan implementation as fast as \npossible. It is `orders of magnitude faster than the reference implementation <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Python%20vs%20Java.ipynb>`_ in Java,\nand is currently faster than highly optimized single linkage implementations in C and C++.\n`version 0.7 performance can be seen in this notebook <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Benchmarking%20scalability%20of%20clustering%20implementations-v0.7.ipynb>`_ .\nIn particular `performance on low dimensional data is better than sklearn's DBSCAN <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/Benchmarking%20scalability%20of%20clustering%20implementations%202D%20v0.7.ipynb>`_ ,\nand via support for caching with joblib, re-clustering with different parameters\ncan be almost free.\n\n------------------------\nAdditional functionality\n------------------------\n\nThe hdbscan package comes equipped with visualization tools to help you\nunderstand your clustering results. After fitting data the clusterer\nobject has attributes for:\n\n* The condensed cluster hierarchy\n* The robust single linkage cluster hierarchy\n* The reachability distance minimal spanning tree\n\nAll of which come equipped with methods for plotting and converting\nto Pandas or NetworkX for further analysis. See the notebook on\n`how HDBSCAN works <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/How%20HDBSCAN%20Works.ipynb>`_ for examples and further details.\n\nThe clusterer objects also have an attribute providing cluster membership\nstrengths, resulting in optional soft clustering (and no further compute \nexpense). Finally each cluster also receives a persistence score giving\nthe stability of the cluster over the range of distance scales present\nin the data. This provides a measure of the relative strength of clusters.\n\n-----------------\nOutlier Detection\n-----------------\n\nThe HDBSCAN clusterer objects also support the GLOSH outlier detection algorithm. \nAfter fitting the clusterer to data the outlier scores can be accessed via the\n``outlier_scores_`` attribute. The result is a vector of score values, one for\neach data point that was fit. Higher scores represent more outlier like objects.\nSelecting outliers via upper quantiles is often a good approach.\n\nBased on the paper:\n R.J.G.B. Campello, D. Moulavi, A. Zimek and J. Sander \n *Hierarchical Density Estimates for Data Clustering, Visualization, and Outlier Detection*, \n ACM Trans. on Knowledge Discovery from Data, Vol 10, 1 (July 2015), 1-51.\n\n---------------------\nRobust single linkage\n---------------------\n\nThe hdbscan package also provides support for the *robust single linkage*\nclustering algorithm of Chaudhuri and Dasgupta. As with the HDBSCAN \nimplementation this is a high performance version of the algorithm \noutperforming scipy's standard single linkage implementation. The\nrobust single linkage hierarchy is available as an attribute of\nthe robust single linkage clusterer, again with the ability to plot\nor export the hierarchy, and to extract flat clusterings at a given\ncut level and gamma value.\n\nExample usage:\n\n.. code:: python\n\n import hdbscan\n from sklearn.datasets import make_blobs\n \n data, _ = make_blobs(1000)\n \n clusterer = hdbscan.RobustSingleLinkage(cut=0.125, k=7)\n cluster_labels = clusterer.fit_predict(data)\n hierarchy = clusterer.cluster_hierarchy_\n alt_labels = hierarchy.get_clusters(0.100, 5)\n hierarchy.plot()\n\n\nBased on the paper:\n K. Chaudhuri and S. Dasgupta.\n *\"Rates of convergence for the cluster tree.\"*\n In Advances in Neural Information Processing Systems, 2010.\n\n----------------\nBranch detection\n----------------\n\nThe hdbscan package supports a branch-detection post-processing step \nby `Bot et al. <https://arxiv.org/abs/2311.15887>`_. Cluster shapes,\nsuch as branching structures, can reveal interesting patterns \nthat are not expressed in density-based cluster hierarchies. The \nBranchDetector class mimics the HDBSCAN API and can be used to\ndetect branching hierarchies in clusters. It provides condensed \nbranch hierarchies, branch persistences, and branch memberships and \nsupports joblib's caching functionality. A notebook \n`demonstrating the BranchDetector is available <http://nbviewer.jupyter.org/github/scikit-learn-contrib/hdbscan/blob/master/notebooks/How%20to%20detect%20branches.ipynb>`_.\n\nExample usage:\n\n.. code:: python\n\n import hdbscan\n from sklearn.datasets import make_blobs\n\n data, _ = make_blobs(1000)\n\n clusterer = hdbscan.HDBSCAN(branch_detection_data=True).fit(data)\n branch_detector = hdbscan.BranchDetector().fit(clusterer)\n branch_detector.cluster_approximation_graph_.plot(edge_width=0.1)\n\n\nBased on the paper:\n D. M. Bot, J. Peeters, J. Liesenborgs and J. Aerts\n *\"FLASC: A Flare-Sensitive Clustering Algorithm: Extending HDBSCAN\\* for Detecting Branches in Clusters\"*\n Arxiv 2311.15887, 2023.\n\n\n----------\nInstalling\n----------\n\nEasiest install, if you have Anaconda (thanks to conda-forge which is awesome!):\n\n.. code:: bash\n\n conda install -c conda-forge hdbscan\n\nPyPI install, presuming you have an up to date pip:\n\n.. code:: bash\n\n pip install hdbscan\n\nBinary wheels for a number of platforms are available thanks to the work of\nRyan Helinski <rlhelinski@gmail.com>.\n\nIf pip is having difficulties pulling the dependencies then we'd suggest to first upgrade\npip to at least version 10 and try again:\n\n.. code:: bash\n\n pip install --upgrade pip\n pip install hdbscan\n\nOtherwise install the dependencies manually using anaconda followed by pulling hdbscan from pip:\n\n.. code:: bash\n\n conda install cython\n conda install numpy scipy\n conda install scikit-learn\n pip install hdbscan\n\n\nFor a manual install of the latest code directly from GitHub:\n\n.. code:: bash\n\n pip install --upgrade git+https://github.com/scikit-learn-contrib/hdbscan.git#egg=hdbscan\n\n\nAlternatively download the package, install requirements, and manually run the installer:\n\n\n.. code:: bash\n\n wget https://github.com/scikit-learn-contrib/hdbscan/archive/master.zip\n unzip master.zip\n rm master.zip\n cd hdbscan-master\n \n pip install -r requirements.txt\n \n python setup.py install\n\n-----------------\nRunning the Tests\n-----------------\n\nThe package tests can be run after installation using the command:\n\n.. code:: bash\n\n nosetests -s hdbscan\n\nor, if ``nose`` is installed but ``nosetests`` is not in your ``PATH`` variable:\n\n.. code:: bash\n\n python -m nose -s hdbscan\n\nIf one or more of the tests fail, please report a bug at https://github.com/scikit-learn-contrib/hdbscan/issues/new\n\n--------------\nPython Version\n--------------\n\nThe hdbscan library supports both Python 2 and Python 3. However we recommend Python 3 as the better option if it is available to you.\n \n----------------\nHelp and Support\n----------------\n\nFor simple issues you can consult the `FAQ <https://hdbscan.readthedocs.io/en/latest/faq.html>`_ in the documentation.\nIf your issue is not suitably resolved there, please check the `issues <https://github.com/scikit-learn-contrib/hdbscan/issues>`_ on github. Finally, if no solution is available there feel free to `open an issue <https://github.com/scikit-learn-contrib/hdbscan/issues/new>`_ ; the authors will attempt to respond in a reasonably timely fashion.\n\n------------\nContributing\n------------\n\nWe welcome contributions in any form! Assistance with documentation, particularly expanding tutorials,\nis always welcome. To contribute please `fork the project <https://github.com/scikit-learn-contrib/hdbscan/issues#fork-destination-box>`_ make your changes and submit a pull request. We will do our best to work through any issues with\nyou and get your code merged into the main branch.\n\n------\nCiting\n------\n\nIf you have used this codebase in a scientific publication and wish to cite it, please use the `Journal of Open Source Software article <http://joss.theoj.org/papers/10.21105/joss.00205>`_.\n\n L. McInnes, J. Healy, S. Astels, *hdbscan: Hierarchical density based clustering*\n In: Journal of Open Source Software, The Open Journal, volume 2, number 11.\n 2017\n \n.. code:: bibtex\n\n @article{mcinnes2017hdbscan,\n title={hdbscan: Hierarchical density based clustering},\n author={McInnes, Leland and Healy, John and Astels, Steve},\n journal={The Journal of Open Source Software},\n volume={2},\n number={11},\n pages={205},\n year={2017}\n }\n \nTo reference the high performance algorithm developed in this library please cite our paper in ICDMW 2017 proceedings.\n\n McInnes L, Healy J. *Accelerated Hierarchical Density Based Clustering* \n In: 2017 IEEE International Conference on Data Mining Workshops (ICDMW), IEEE, pp 33-42.\n 2017\n\n\n.. code:: bibtex\n\n @inproceedings{mcinnes2017accelerated,\n title={Accelerated Hierarchical Density Based Clustering},\n author={McInnes, Leland and Healy, John},\n booktitle={Data Mining Workshops (ICDMW), 2017 IEEE International Conference on},\n pages={33--42},\n year={2017},\n organization={IEEE}\n }\n\nIf you used the branch-detection functionality in this codebase in a scientific publication and which to cite it, please use the `Arxiv preprint <https://arxiv.org/abs/2311.15887>`_: \n\n D. M. Bot, J. Peeters, J. Liesenborgs and J. Aerts\n *\"FLASC: A Flare-Sensitive Clustering Algorithm: Extending HDBSCAN\\* for Detecting Branches in Clusters\"*\n Arxiv 2311.15887, 2023.\n\n.. code:: bibtex\n\n @misc{bot2023flasc,\n title={FLASC: A Flare-Sensitive Clustering Algorithm: Extending HDBSCAN* for Detecting Branches in Clusters}, \n author={D. M. Bot and J. Peeters and J. Liesenborgs and J. Aerts},\n year={2023},\n eprint={2311.15887},\n archivePrefix={arXiv},\n primaryClass={cs.LG},\n url={https://arxiv.org/abs/2311.15887}, \n }\n\n---------\nLicensing\n---------\n\nThe hdbscan package is 3-clause BSD licensed. Enjoy.\n",
"bugtrack_url": null,
"license": "BSD",
"summary": "Clustering based on density with variable density clusters",
"version": "0.8.39",
"project_urls": {
"Homepage": "http://github.com/scikit-learn-contrib/hdbscan"
},
"split_keywords": [
"cluster",
"clustering",
"density",
"hierarchical"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "b903096b083b106559277998fe4f0e6bb9db4c6323d91122e34c73cfc0009e1e",
"md5": "8b65e8e9ae068223cba065d3ffa61235",
"sha256": "9ea1f9867f54501f99f8323df1086881a13e5ad135216e23cf8cb170f3f159a9"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp310-cp310-macosx_12_0_x86_64.whl",
"has_sig": false,
"md5_digest": "8b65e8e9ae068223cba065d3ffa61235",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": null,
"size": 808809,
"upload_time": "2024-10-12T02:04:35",
"upload_time_iso_8601": "2024-10-12T02:04:35.630176Z",
"url": "https://files.pythonhosted.org/packages/b9/03/096b083b106559277998fe4f0e6bb9db4c6323d91122e34c73cfc0009e1e/hdbscan-0.8.39-cp310-cp310-macosx_12_0_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "53f019fccde88302e2ba8bbf66b89b09d5fe0d94bc1c6760b3b9731d2c0573e5",
"md5": "36dae74da46e83e608225332a5b45a3e",
"sha256": "17092f3dc50e4da19010b61b7ecf87aca2980e76d83a4826614bba2b5c45f89e"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "36dae74da46e83e608225332a5b45a3e",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": null,
"size": 4222134,
"upload_time": "2024-10-12T02:05:23",
"upload_time_iso_8601": "2024-10-12T02:05:23.545272Z",
"url": "https://files.pythonhosted.org/packages/53/f0/19fccde88302e2ba8bbf66b89b09d5fe0d94bc1c6760b3b9731d2c0573e5/hdbscan-0.8.39-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "372cc8807834821e4537c6a0a54eb927729e5b1a1054d1940af862991b1bcb2c",
"md5": "778b048026b97b4d84a70944464146c9",
"sha256": "f2e6bfb9e03b3689d93fd966d1037781339da5352653d8cf109ad2c9229be9f2"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp310-cp310-win_amd64.whl",
"has_sig": false,
"md5_digest": "778b048026b97b4d84a70944464146c9",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": null,
"size": 727342,
"upload_time": "2024-10-12T02:06:22",
"upload_time_iso_8601": "2024-10-12T02:06:22.863542Z",
"url": "https://files.pythonhosted.org/packages/37/2c/c8807834821e4537c6a0a54eb927729e5b1a1054d1940af862991b1bcb2c/hdbscan-0.8.39-cp310-cp310-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "f9425a092661e98682fd2dd7b7afde1e5264f56b0882e0893334bf5f3eb01f32",
"md5": "a5e721793d46cdcf1da85b1f0d064ca5",
"sha256": "68880e33f8dc2a12b07f267dcb657932737e6863f9be8c13299c9ad7c50b9c41"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp311-cp311-macosx_10_9_universal2.whl",
"has_sig": false,
"md5_digest": "a5e721793d46cdcf1da85b1f0d064ca5",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": null,
"size": 1482837,
"upload_time": "2024-10-12T02:07:28",
"upload_time_iso_8601": "2024-10-12T02:07:28.778409Z",
"url": "https://files.pythonhosted.org/packages/f9/42/5a092661e98682fd2dd7b7afde1e5264f56b0882e0893334bf5f3eb01f32/hdbscan-0.8.39-cp311-cp311-macosx_10_9_universal2.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "15aed74752edea5ca8fbbe0058411b092e2c872bf74cb4a94f35ba05946ff464",
"md5": "a384186449e346d812d6333c41aa7ae9",
"sha256": "a1ce6cfe384b637b9451d003d0ddad75cfb4851ef743f29d794249721c2f1158"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "a384186449e346d812d6333c41aa7ae9",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": null,
"size": 4554051,
"upload_time": "2024-10-12T02:04:17",
"upload_time_iso_8601": "2024-10-12T02:04:17.438917Z",
"url": "https://files.pythonhosted.org/packages/15/ae/d74752edea5ca8fbbe0058411b092e2c872bf74cb4a94f35ba05946ff464/hdbscan-0.8.39-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "9bb2736f502dc447e52aa51d3e8991d7d342ce3a4f4d09226015eb14e4a1dcad",
"md5": "cb2e684efb86b1ca2e32ef58c0cf6698",
"sha256": "d7809a21842f9524a5160176181079380ba47f54f438ec6c48101801e0a84712"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp311-cp311-win_amd64.whl",
"has_sig": false,
"md5_digest": "cb2e684efb86b1ca2e32ef58c0cf6698",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": null,
"size": 728849,
"upload_time": "2024-10-12T02:08:26",
"upload_time_iso_8601": "2024-10-12T02:08:26.542464Z",
"url": "https://files.pythonhosted.org/packages/9b/b2/736f502dc447e52aa51d3e8991d7d342ce3a4f4d09226015eb14e4a1dcad/hdbscan-0.8.39-cp311-cp311-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "66f75be1c9351a70166054910163e990f737dbe376d422b5811b45e958b1c680",
"md5": "97a50ee23e64ec98bba053e0d005abea",
"sha256": "36afdbdef30ad4cbccc730ca0f0d76837b533746db24c17cd661a8f01ff9c849"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "97a50ee23e64ec98bba053e0d005abea",
"packagetype": "bdist_wheel",
"python_version": "cp312",
"requires_python": null,
"size": 4447417,
"upload_time": "2024-10-12T02:04:20",
"upload_time_iso_8601": "2024-10-12T02:04:20.068812Z",
"url": "https://files.pythonhosted.org/packages/66/f7/5be1c9351a70166054910163e990f737dbe376d422b5811b45e958b1c680/hdbscan-0.8.39-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "4b03b6898c54b57f313db1b60be066bfd7b93235853f9d0aeba203c30ad2126e",
"md5": "963231b47b7bc826db9706a310334edf",
"sha256": "34595a7e77799dbc768f6e35691657d3c375a4f262d74515f46c7cc15294ea60"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp38-cp38-macosx_12_0_x86_64.whl",
"has_sig": false,
"md5_digest": "963231b47b7bc826db9706a310334edf",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": null,
"size": 815350,
"upload_time": "2024-10-12T02:04:59",
"upload_time_iso_8601": "2024-10-12T02:04:59.317077Z",
"url": "https://files.pythonhosted.org/packages/4b/03/b6898c54b57f313db1b60be066bfd7b93235853f9d0aeba203c30ad2126e/hdbscan-0.8.39-cp38-cp38-macosx_12_0_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "1eec0ca014e87131af4cf7293f3915f131764ec6ededf49a90ef304cb78ed0ac",
"md5": "bc0b02b2c77ac203bf2c98753fa37220",
"sha256": "7815a842008fcf224807f6cc79c48cda4f85f31a9a9918bb2cf5f8ecdb7bfe5b"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "bc0b02b2c77ac203bf2c98753fa37220",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": null,
"size": 4326949,
"upload_time": "2024-10-12T02:04:22",
"upload_time_iso_8601": "2024-10-12T02:04:22.577597Z",
"url": "https://files.pythonhosted.org/packages/1e/ec/0ca014e87131af4cf7293f3915f131764ec6ededf49a90ef304cb78ed0ac/hdbscan-0.8.39-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "e99aead67b029b3bca1732cc3a75ee17471a7130b9f7a28ccc5ccc93b810da7e",
"md5": "07c65f502c823b528e1a5e262abb7144",
"sha256": "fdef592010599503d6197e8420e6ad4bccfdaaf49f46722da34a1b62026455db"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp38-cp38-win_amd64.whl",
"has_sig": false,
"md5_digest": "07c65f502c823b528e1a5e262abb7144",
"packagetype": "bdist_wheel",
"python_version": "cp38",
"requires_python": null,
"size": 810576,
"upload_time": "2024-10-12T02:07:47",
"upload_time_iso_8601": "2024-10-12T02:07:47.265381Z",
"url": "https://files.pythonhosted.org/packages/e9/9a/ead67b029b3bca1732cc3a75ee17471a7130b9f7a28ccc5ccc93b810da7e/hdbscan-0.8.39-cp38-cp38-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "3835d070cda55331dbd52b8bdd471f3e88530a591387f1930a17ae653dc735ce",
"md5": "bd93d3fba52e25ab5b69dfadebafaef0",
"sha256": "127cd877bf0a816d3ea75478d9774f4205fdfe60d84bc7639be501f071d4c558"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp39-cp39-macosx_12_0_x86_64.whl",
"has_sig": false,
"md5_digest": "bd93d3fba52e25ab5b69dfadebafaef0",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": null,
"size": 810103,
"upload_time": "2024-10-12T02:07:40",
"upload_time_iso_8601": "2024-10-12T02:07:40.956399Z",
"url": "https://files.pythonhosted.org/packages/38/35/d070cda55331dbd52b8bdd471f3e88530a591387f1930a17ae653dc735ce/hdbscan-0.8.39-cp39-cp39-macosx_12_0_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "2fbe4be54b641246faf8fa28e9c37739ab3947c29f6bd81c95e93d7d0bb179d9",
"md5": "7997c674ae93c489b15820f2a8de1d05",
"sha256": "5ec50875227d31995de80a2bdee98e541177856862897cb60357410c3f6a9ed9"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "7997c674ae93c489b15820f2a8de1d05",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": null,
"size": 4227691,
"upload_time": "2024-10-12T02:04:13",
"upload_time_iso_8601": "2024-10-12T02:04:13.826770Z",
"url": "https://files.pythonhosted.org/packages/2f/be/4be54b641246faf8fa28e9c37739ab3947c29f6bd81c95e93d7d0bb179d9/hdbscan-0.8.39-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "0a494881cc990ec74a691d1617eb5d1f41359489d9e4ee6bc7992162e30c2ce3",
"md5": "17e60ac5a683d1177ecf29f1ae72ed66",
"sha256": "f782c749e1040f737e94c8c2f711135146b2d00753858acd13452dafb6add0b6"
},
"downloads": -1,
"filename": "hdbscan-0.8.39-cp39-cp39-win_amd64.whl",
"has_sig": false,
"md5_digest": "17e60ac5a683d1177ecf29f1ae72ed66",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": null,
"size": 807820,
"upload_time": "2024-10-12T02:08:28",
"upload_time_iso_8601": "2024-10-12T02:08:28.632855Z",
"url": "https://files.pythonhosted.org/packages/0a/49/4881cc990ec74a691d1617eb5d1f41359489d9e4ee6bc7992162e30c2ce3/hdbscan-0.8.39-cp39-cp39-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "f4a1a8f1d60a44ae9f720e5c77a30c2d01962f3ff1d2de81f0eb640354c400b2",
"md5": "0aa242cda861b101864c0850ca100233",
"sha256": "2aa1351f42fa79efdc47d53695381aa9a2efef6d1855b96c42d030646fee74f7"
},
"downloads": -1,
"filename": "hdbscan-0.8.39.tar.gz",
"has_sig": false,
"md5_digest": "0aa242cda861b101864c0850ca100233",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 5771399,
"upload_time": "2024-10-12T02:04:17",
"upload_time_iso_8601": "2024-10-12T02:04:17.476102Z",
"url": "https://files.pythonhosted.org/packages/f4/a1/a8f1d60a44ae9f720e5c77a30c2d01962f3ff1d2de81f0eb640354c400b2/hdbscan-0.8.39.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-10-12 02:04:17",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "scikit-learn-contrib",
"github_project": "hdbscan",
"travis_ci": true,
"coveralls": false,
"github_actions": true,
"circle": true,
"requirements": [
{
"name": "numpy",
"specs": [
[
">=",
"1.20"
],
[
"<",
"3"
]
]
},
{
"name": "scipy",
"specs": [
[
">=",
"1.0"
]
]
},
{
"name": "scikit-learn",
"specs": [
[
">=",
"0.20"
]
]
},
{
"name": "joblib",
"specs": [
[
">=",
"1.0"
]
]
}
],
"lcname": "hdbscan"
}