A package for automatic clustering hyperparameter optmization
Project description
Hypercluster
A package for clustering optimization with sklearn.
Requirements:
pandas
numpy
scipy
matplotlib
seaborn
scikit-learn
hdbscan
Optional: snakemake
Install
With pip:
pip install hypercluster
or with conda:
conda install hypercluster
# or
conda install -c conda-forge -c bioconda hypercluster
If you are having problems installing with conda, try changing your channel priority. Priority of conda-forge > bioconda > defaults is recommended.
To check channel priority: conda config --get channels
It should look like:
--add channels 'defaults' # lowest priority
--add channels 'bioconda'
--add channels 'conda-forge' # highest priority
If it doesn't look like that, try:
conda config --add channels bioconda
conda config --add channels conda-forge
Docs
https://hypercluster.readthedocs.io/en/latest/index.html
Examples
https://github.com/liliblu/hypercluster/tree/dev/examples
Quickstart example
import pandas as pd
from sklearn.datasets import make_blobs
import hypercluster
data, labels = make_blobs()
data = pd.DataFrame(data)
labels = pd.Series(labels, index=data.index, name='labels')
# With a single clustering algorithm
clusterer = hypercluster.AutoClusterer()
clusterer.fit(data).evaluate(
methods = hypercluster.constants.need_ground_truth+hypercluster.constants.inherent_metrics,
gold_standard = labels
)
clusterer.visualize_evaluations()
# With a range of algorithms
clusterer = hypercluster.MultiAutoClusterer()
clusterer.fit(data).evaluate(
methods = hypercluster.constants.need_ground_truth+hypercluster.constants.inherent_metrics,
gold_standard = labels
)
clusterer.visualize_evaluations()
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
hypercluster-0.1.3.tar.gz
(13.4 kB
view hashes)
Built Distribution
Close
Hashes for hypercluster-0.1.3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | a423fa4ef14efff452446dc79ef568770f8cf35752dac6dcb2c8615ea268b927 |
|
MD5 | 43924b4acb6db88a81f6d18cffd2eb46 |
|
BLAKE2b-256 | 4bd892da193cd10ae3008d087c6dc73ce4f7f0cb2e1bed0fb6be0a62a99dbb6c |