├── LICENSE ├── Makefile ├── README.md ├── docs ├── Makefile ├── build │ ├── doctrees │ │ ├── code_description.doctree │ │ ├── code_usage.doctree │ │ ├── datadimension.doctree │ │ ├── environment.pickle │ │ ├── experiments.doctree │ │ ├── index.doctree │ │ └── installing.doctree │ └── html │ │ ├── _images │ │ ├── blobs1.png │ │ ├── blobs1000105.png │ │ ├── blobsnoisy.png │ │ ├── classes10.png │ │ ├── classes100500500.png │ │ ├── classes1005050.png │ │ ├── classes20.png │ │ ├── classes400.png │ │ ├── clustering_labelsblobs.png │ │ ├── noisyblobs.png │ │ ├── performance100500500.png │ │ ├── performance1005050.png │ │ ├── performance10features.png │ │ ├── performance20features.png │ │ ├── performance400.png │ │ ├── performanceblobs1.png │ │ ├── performanceexample.png │ │ ├── performancemnist.png │ │ ├── performancenoisy.png │ │ ├── performanceumap.png │ │ ├── predlab10.png │ │ ├── predlab100500500.png │ │ ├── predlab1005050.png │ │ ├── predlab20.png │ │ ├── predlab400.png │ │ ├── predlabblobs1.png │ │ ├── predlabmnist.png │ │ ├── predlabnoisy.png │ │ ├── predlabumap.png │ │ ├── revalpipeline.pdf │ │ ├── revalpipeline.png │ │ ├── test400.png │ │ ├── testmnist.png │ │ ├── testumap.png │ │ ├── toy_datasetexample.png │ │ ├── toyexample_performance.png │ │ ├── train400.png │ │ ├── trainmnist.png │ │ ├── trainumap.png │ │ ├── true_labelsblobs.png │ │ ├── umapscatter.png │ │ ├── umaptest.png │ │ ├── umaptraining.png │ │ └── useblobs.png │ │ ├── _modules │ │ ├── index.html │ │ └── reval │ │ │ ├── best_nclust_cv.html │ │ │ ├── relative_validation.html │ │ │ └── visualization.html │ │ ├── _sources │ │ ├── code_description.rst.txt │ │ ├── code_usage.rst.txt │ │ ├── datadimension.rst.txt │ │ ├── experiments.rst.txt │ │ ├── index.rst.txt │ │ └── installing.rst.txt │ │ ├── _static │ │ ├── alabaster.css │ │ ├── basic.css │ │ ├── classic.css │ │ ├── css │ │ │ ├── badge_only.css │ │ │ └── theme.css │ │ ├── custom.css │ │ ├── doctools.js │ │ ├── documentation_options.js │ │ ├── file.png │ │ ├── fonts │ │ │ ├── Inconsolata-Bold.ttf │ │ │ ├── Inconsolata-Regular.ttf │ │ │ ├── Inconsolata.ttf │ │ │ ├── Lato-Bold.ttf │ │ │ ├── Lato-Regular.ttf │ │ │ ├── Lato │ │ │ │ ├── lato-bold.eot │ │ │ │ ├── lato-bold.ttf │ │ │ │ ├── lato-bold.woff │ │ │ │ ├── lato-bold.woff2 │ │ │ │ ├── lato-bolditalic.eot │ │ │ │ ├── lato-bolditalic.ttf │ │ │ │ ├── lato-bolditalic.woff │ │ │ │ ├── lato-bolditalic.woff2 │ │ │ │ ├── lato-italic.eot │ │ │ │ ├── lato-italic.ttf │ │ │ │ ├── lato-italic.woff │ │ │ │ ├── lato-italic.woff2 │ │ │ │ ├── lato-regular.eot │ │ │ │ ├── lato-regular.ttf │ │ │ │ ├── lato-regular.woff │ │ │ │ └── lato-regular.woff2 │ │ │ ├── RobotoSlab-Bold.ttf │ │ │ ├── RobotoSlab-Regular.ttf │ │ │ ├── RobotoSlab │ │ │ │ ├── roboto-slab-v7-bold.eot │ │ │ │ ├── roboto-slab-v7-bold.ttf │ │ │ │ ├── roboto-slab-v7-bold.woff │ │ │ │ ├── roboto-slab-v7-bold.woff2 │ │ │ │ ├── roboto-slab-v7-regular.eot │ │ │ │ ├── roboto-slab-v7-regular.ttf │ │ │ │ ├── roboto-slab-v7-regular.woff │ │ │ │ └── roboto-slab-v7-regular.woff2 │ │ │ ├── fontawesome-webfont.eot │ │ │ ├── fontawesome-webfont.svg │ │ │ ├── fontawesome-webfont.ttf │ │ │ ├── fontawesome-webfont.woff │ │ │ └── fontawesome-webfont.woff2 │ │ ├── jquery-3.4.1.js │ │ ├── jquery.js │ │ ├── js │ │ │ ├── modernizr.min.js │ │ │ └── theme.js │ │ ├── language_data.js │ │ ├── minus.png │ │ ├── plus.png │ │ ├── pygments.css │ │ ├── searchtools.js │ │ ├── sidebar.js │ │ ├── underscore-1.3.1.js │ │ └── underscore.js │ │ ├── code_description.html │ │ ├── code_usage.html │ │ ├── datadimension.html │ │ ├── experiments.html │ │ ├── genindex.html │ │ ├── index.html │ │ ├── installing.html │ │ ├── objects.inv │ │ ├── py-modindex.html │ │ ├── search.html │ │ └── searchindex.js ├── make.bat └── source │ ├── code_description.rst │ ├── code_usage.rst │ ├── conf.py │ ├── datadimension.rst │ ├── experiments.rst │ ├── images │ ├── blobs1.png │ ├── blobsnoisy.png │ ├── classes10.png │ ├── classes100500500.png │ ├── classes1005050.png │ ├── classes20.png │ ├── performance100500500.png │ ├── performance1005050.png │ ├── performance10features.png │ ├── performance20features.png │ ├── performanceblobs1.png │ ├── performanceexample.png │ ├── performanceexample2.png │ ├── performancemnist.png │ ├── performancenoisy.png │ ├── performanceumap.png │ ├── predlab10.png │ ├── predlab100500500.png │ ├── predlab1005050.png │ ├── predlab20.png │ ├── predlabblobs1.png │ ├── predlabmnist.png │ ├── predlabnoisy.png │ ├── predlabumap.png │ ├── revalv0.0.2pipeline.png │ ├── test100500500.png │ ├── testmnist.png │ ├── testumap.png │ ├── trainmnist.png │ ├── trainumap.png │ └── useblobs.png │ ├── index.rst │ └── installing.rst ├── files └── revalpipeline.png ├── requirements.txt ├── reval ├── __init__.py ├── best_nclust_cv.py ├── internal_baselines.py ├── param_selection.py ├── relative_validation.py ├── utils.py └── visualization.py ├── setup.py ├── tests ├── __init__.py ├── test_best_nclust_cv.py ├── test_param_selection.py ├── test_relative_validation.py └── unit │ ├── test_internal_baselines.py │ └── test_utils.py └── working_examples ├── README.md ├── __init__.py ├── blobs.py ├── data_dimensionality.py ├── datasets ├── README.md ├── Wholesale_customers_data.csv ├── __pycache__ │ └── manuscript_builddatasets.cpython-38.pyc ├── biodeg.csv ├── breast-cancer-wisconsin.data ├── car.data ├── climate.dat ├── data_banknote_authentication.txt ├── ecoli.data ├── forest_tr.csv ├── forest_ts.csv ├── glass.data ├── ionosphere.data ├── iris.data ├── leaf.csv ├── liver.data ├── manuscript_builddatasets.py ├── movement_libras.data ├── parkinsons.data ├── seeds_dataset.txt ├── transfusion.data ├── urban_tr.csv ├── urban_ts.csv └── yeast.data ├── handwritten_digits.py ├── manexamples_notebook.ipynb ├── manuscript_examples.py ├── reval_bigocomplexity.py └── reval_timeitcomplexity.py /Makefile: -------------------------------------------------------------------------------- 1 | init: 2 | pip install -r requirements.txt 3 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # `reval`: stability-based relative clustering validation method to determine the best number of clusters 2 | 3 | Determining the number of clusters that best partitions a dataset can be a challenging task because of 1) the lack of a 4 | priori information within an unsupervised learning framework; and 2) the absence of a unique clustering validation 5 | approach to evaluate clustering solutions. Here we present `reval`: a Python package that leverages 6 | stability-based relative clustering validation methods to determine best clustering solutions, as described in [1]. 7 | 8 | Statistical software, both in R and Python, usually compute internal validation metrics that can be leveraged 9 | to select the number of clusters that best fit the data and open-source software solutions that easily implement 10 | relative clustering techniques are lacking. The advantage of a relative approach over internal validation methods 11 | lies in the fact that internal metrics exploit characteristics of the data itself to produce a result, 12 | whereas relative validation converts an unsupervised clustering algorithm into a supervised classification problem, 13 | hence enabling generalizability and replicability of the results. 14 | 15 | ## Requirements 16 | 17 | python>=3.6 18 | 19 | ## Installing 20 | 21 | From github: 22 | 23 | git clone https://github.com/IIT-LAND/reval_clustering 24 | pip install -r requirements.txt 25 | 26 | PyPI alternative (latest version v0.1.0): 27 | 28 | pip install reval 29 | 30 | ## Documentation 31 | 32 | Code documentation can be found [here](https://reval.readthedocs.io/en/latest/). Documents include Python code 33 | descriptions, `reval` usage examples, 34 | performance on benchmark datasets, and common issues that can be encountered related to a dataset number of features 35 | and samples. 36 | 37 | ## Manuscript 38 | 39 | `reval` package functionalities are presented in our recent work that, as of now, can be found as a 40 | [preprint](https://arxiv.org/abs/2009.01077). The experiments presented in the manuscript are in 41 | the Python file `./working_examples/manuscript_examples.py` of the github folder. For reproducibility, all experiments 42 | were run with `reval v0.1.0`. 43 | 44 | ## Refrences 45 | 46 | [1] Lange, T., Roth, V., Braun, M. L., & Buhmann, J. M. (2004). Stability-based validation of clustering solutions. 47 | *Neural computation*, 16(6), 1299-1323. 48 | 49 | ## Cite as 50 | 51 | Landi, I., Mandelli, V., & Lombardo, M. V. (2021). reval: A Python package to determine best clustering solutions with stability-based relative clustering validation. _Patterns_, 2(4), 100228. 52 | 53 | BibTeX alternative 54 | 55 | ``` 56 | @article{LANDI2021100228, 57 | title = {reval: A Python package to determine best clustering solutions 58 | with stability-based relative clustering validation}, 59 | journal = {Patterns}, 60 | volume = {2}, 61 | number = {4}, 62 | pages = {100228}, 63 | year = {2021}, 64 | issn = {2666-3899}, 65 | doi = {https://doi.org/10.1016/j.patter.2021.100228}, 66 | url = {https://www.sciencedirect.com/science/article/pii/S2666389921000428}, 67 | author = {Isotta Landi and Veronica Mandelli and Michael V. Lombardo}, 68 | keywords = {stability-based relative validation, 69 | clustering, 70 | unsupervised learning, 71 | clustering replicability} 72 | } 73 | ``` -------------------------------------------------------------------------------- /docs/Makefile: -------------------------------------------------------------------------------- 1 | # Minimal makefile for Sphinx documentation 2 | # 3 | 4 | # You can set these variables from the command line, and also 5 | # from the environment for the first two. 6 | SPHINXOPTS ?= 7 | SPHINXBUILD ?= sphinx-build 8 | SOURCEDIR = source 9 | BUILDDIR = build 10 | 11 | # Put it first so that "make" without argument is like "make help". 12 | help: 13 | @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) 14 | 15 | .PHONY: help Makefile 16 | 17 | # Catch-all target: route all unknown targets to Sphinx using the new 18 | # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). 19 | %: Makefile 20 | @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) 21 | -------------------------------------------------------------------------------- /docs/build/doctrees/code_description.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/doctrees/code_description.doctree -------------------------------------------------------------------------------- /docs/build/doctrees/code_usage.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/doctrees/code_usage.doctree -------------------------------------------------------------------------------- /docs/build/doctrees/datadimension.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/doctrees/datadimension.doctree -------------------------------------------------------------------------------- /docs/build/doctrees/environment.pickle: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/doctrees/environment.pickle -------------------------------------------------------------------------------- /docs/build/doctrees/experiments.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/doctrees/experiments.doctree -------------------------------------------------------------------------------- /docs/build/doctrees/index.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/doctrees/index.doctree -------------------------------------------------------------------------------- /docs/build/doctrees/installing.doctree: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/doctrees/installing.doctree -------------------------------------------------------------------------------- /docs/build/html/_images/blobs1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/blobs1.png -------------------------------------------------------------------------------- /docs/build/html/_images/blobs1000105.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/blobs1000105.png -------------------------------------------------------------------------------- /docs/build/html/_images/blobsnoisy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/blobsnoisy.png -------------------------------------------------------------------------------- /docs/build/html/_images/classes10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/classes10.png -------------------------------------------------------------------------------- /docs/build/html/_images/classes100500500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/classes100500500.png -------------------------------------------------------------------------------- /docs/build/html/_images/classes1005050.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/classes1005050.png -------------------------------------------------------------------------------- /docs/build/html/_images/classes20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/classes20.png -------------------------------------------------------------------------------- /docs/build/html/_images/classes400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/classes400.png -------------------------------------------------------------------------------- /docs/build/html/_images/clustering_labelsblobs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/clustering_labelsblobs.png -------------------------------------------------------------------------------- /docs/build/html/_images/noisyblobs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/noisyblobs.png -------------------------------------------------------------------------------- /docs/build/html/_images/performance100500500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performance100500500.png -------------------------------------------------------------------------------- /docs/build/html/_images/performance1005050.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performance1005050.png -------------------------------------------------------------------------------- /docs/build/html/_images/performance10features.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performance10features.png -------------------------------------------------------------------------------- /docs/build/html/_images/performance20features.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performance20features.png -------------------------------------------------------------------------------- /docs/build/html/_images/performance400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performance400.png -------------------------------------------------------------------------------- /docs/build/html/_images/performanceblobs1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performanceblobs1.png -------------------------------------------------------------------------------- /docs/build/html/_images/performanceexample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performanceexample.png -------------------------------------------------------------------------------- /docs/build/html/_images/performancemnist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performancemnist.png -------------------------------------------------------------------------------- /docs/build/html/_images/performancenoisy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performancenoisy.png -------------------------------------------------------------------------------- /docs/build/html/_images/performanceumap.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/performanceumap.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlab10.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlab10.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlab100500500.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlab100500500.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlab1005050.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlab1005050.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlab20.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlab20.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlab400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlab400.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlabblobs1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlabblobs1.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlabmnist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlabmnist.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlabnoisy.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlabnoisy.png -------------------------------------------------------------------------------- /docs/build/html/_images/predlabumap.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/predlabumap.png -------------------------------------------------------------------------------- /docs/build/html/_images/revalpipeline.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/revalpipeline.pdf -------------------------------------------------------------------------------- /docs/build/html/_images/revalpipeline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/revalpipeline.png -------------------------------------------------------------------------------- /docs/build/html/_images/test400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/test400.png -------------------------------------------------------------------------------- /docs/build/html/_images/testmnist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/testmnist.png -------------------------------------------------------------------------------- /docs/build/html/_images/testumap.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/testumap.png -------------------------------------------------------------------------------- /docs/build/html/_images/toy_datasetexample.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/toy_datasetexample.png -------------------------------------------------------------------------------- /docs/build/html/_images/toyexample_performance.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/toyexample_performance.png -------------------------------------------------------------------------------- /docs/build/html/_images/train400.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/train400.png -------------------------------------------------------------------------------- /docs/build/html/_images/trainmnist.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/trainmnist.png -------------------------------------------------------------------------------- /docs/build/html/_images/trainumap.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/trainumap.png -------------------------------------------------------------------------------- /docs/build/html/_images/true_labelsblobs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/true_labelsblobs.png -------------------------------------------------------------------------------- /docs/build/html/_images/umapscatter.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/umapscatter.png -------------------------------------------------------------------------------- /docs/build/html/_images/umaptest.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/umaptest.png -------------------------------------------------------------------------------- /docs/build/html/_images/umaptraining.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/umaptraining.png -------------------------------------------------------------------------------- /docs/build/html/_images/useblobs.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_images/useblobs.png -------------------------------------------------------------------------------- /docs/build/html/_modules/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | Overview: module code — Relative clustering validation 0.0.1 documentation 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 26 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 |
45 | 46 | 101 | 102 |
103 | 104 | 105 | 111 | 112 | 113 |
114 | 115 |
116 | 117 | 118 | 119 | 120 | 121 | 122 | 123 | 124 | 125 | 126 | 127 | 128 | 129 | 130 | 131 | 132 | 133 |
134 | 135 |
    136 | 137 |
  • »
  • 138 | 139 |
  • Overview: module code
  • 140 | 141 | 142 |
  • 143 | 144 |
  • 145 | 146 |
147 | 148 | 149 |
150 |
151 |
152 |
153 | 154 |

All modules for which code is available

155 | 162 | 163 |
164 | 165 |
166 | 188 | 189 |
190 |
191 | 192 |
193 | 194 |
195 | 196 | 197 | 202 | 203 | 204 | 205 | 206 | 207 | 208 | 209 | -------------------------------------------------------------------------------- /docs/build/html/_sources/code_description.rst.txt: -------------------------------------------------------------------------------- 1 | Code description 2 | ================ 3 | 4 | ``reval`` module has one superclass :class:`FindBestClustCV` and a subclass :class:`RelativeValidation`. 5 | :class:`SCParamSelection` and :class:`ParamSelection` have been added to later releases to perform 6 | hyperparameter selections. 7 | 8 | Classes 9 | ------- 10 | 11 | .. autoclass:: reval.relative_validation.RelativeValidation 12 | :members: 13 | :private-members: 14 | 15 | .. autoclass:: reval.best_nclust_cv.FindBestClustCV 16 | :members: 17 | :private-members: 18 | 19 | .. autoclass:: reval.param_selection.SCParamSelection 20 | :members: 21 | :private-members: 22 | 23 | .. autoclass:: reval.param_selection.ParamSelection 24 | :members: 25 | :private-members: 26 | 27 | Functions 28 | --------- 29 | 30 | Useful functions that can be used on their own are also available. In particular, 31 | ``reval.utils.kuhn_munkres_algorithm`` is an implementation of the Kuhn-Munkres algorithm 32 | (Kuhn, 1955; Munkres, 1957), that performs consistent permutation of predicted labels 33 | in order to minimize the misclassification error with respect to true labels. ``reval.utils.compute_metrics`` 34 | takes as input clustering and classification labels and returns classification metrics, such as F1 score, 35 | accuracy and Matthews correlation coefficient for generalization. 36 | 37 | Kuhn, H. W. (1955). The Hungarian method for the assignment problem. *Naval research logistics quarterly*, 38 | 2(1‐2), 83-97. 39 | 40 | Munkres, J. (1957). Algorithms for the assignment and transportation problems. 41 | *Journal of the society for industrial and applied mathematics*, 5(1), 32-38. 42 | 43 | .. automodule:: reval.utils 44 | :members: kuhn_munkres_algorithm, compute_metrics 45 | :private-members: _build_weight_mat 46 | 47 | The ``reval.best_nclust_cv._confint`` computes 95% confidence interval using ``scipy.stats.t.ppf()`` function. 48 | 49 | .. automodule:: reval.best_nclust_cv 50 | :members: _confint 51 | :private-members: 52 | 53 | 54 | The module ``reval.internal_baselines`` includes functions ``select_best`` and ``evaluate_best`` that allow comparisons 55 | between ``reval`` method and internal validation measures. 56 | 57 | .. automodule:: reval.internal_baselines 58 | :members: select_best, evaluate_best 59 | 60 | Visualization 61 | ------------- 62 | 63 | ``reval.visualization`` enables plotting the cross-validation performance. 64 | 65 | .. automodule:: reval.visualization 66 | :members: 67 | :private-members: 68 | -------------------------------------------------------------------------------- /docs/build/html/_sources/code_usage.rst.txt: -------------------------------------------------------------------------------- 1 | How to use ``reval`` 2 | ==================== 3 | 4 | In the following, we are going to simulate N = 1,000 sample dataset with two groups and two features 5 | (for visualization purposes), then we will show how to apply the ``reval`` package and investigate 6 | the result types. We will use hierarchical clustering and KNN classification algorithms. 7 | 8 | First, let us import a bunch of useful libraries and our class ``reval.best_nclust_cv.FindBestClustCV``: 9 | 10 | .. code:: python3 11 | 12 | from reval.best_nclust_cv import FindBestClustCV 13 | from sklearn.datasets import make_blobs 14 | from sklearn.neighbors import KNeighborsClassifier 15 | from sklearn.cluster import AgglomerativeClustering 16 | from sklearn.model_selection import train_test_split 17 | import matplotlib.pyplot as plt 18 | 19 | Then we simulate the toy dataset and visualize it: 20 | 21 | .. code:: python3 22 | 23 | data = make_blobs(1000, 2, centers=2, random_state=42) 24 | plt.scatter(data[0][:, 0], data[0][:, 1], 25 | c=data[1], cmap='rainbow_r') 26 | plt.show() 27 | 28 | .. image:: images/useblobs.png 29 | :align: center 30 | 31 | Then, we split the dataset into training and test sets: 32 | 33 | .. code:: python3 34 | 35 | X_tr, X_ts, y_tr, y_ts = train_test_split(data[0], data[1], 36 | test_size=0.30, 37 | random_state=42, 38 | stratify=data[1]) 39 | 40 | We apply the stability-based relative clustering validation approach with 10x2 repeated cross-validation, 41 | 10 iterations of random labeling, and number of clusters ranging from 2 to 10. 42 | 43 | .. code:: python3 44 | 45 | classifier = KNeighborsClassifier() 46 | clustering = AgglomerativeClustering() 47 | findbestclust = FindBestClustCV(nfold=2, 48 | nclust_range=list(range(2, 11)), 49 | s=classifier, 50 | c=clustering, 51 | nrand=100) 52 | metrics, nbest = findbestclust.best_nclust(X_tr, iter_cv=10, strat_vect=y_tr) 53 | out = findbestclust.evaluate(X_tr, X_ts, nbest) 54 | 55 | To obtain the training stability and the normalized validation stability for the 56 | selected number of clusters we need to call: 57 | 58 | .. code:: python3 59 | 60 | nbest 61 | # 2 62 | metrics['train'][nbest] 63 | # (0.0, (0.0, 0.0)) (stab, (stab, error)) 64 | metrics['val'][nbest] 65 | # (0.0, (0.0, 0.0)) (stab, (stab, error)) 66 | 67 | ``out`` returns train/test accuracies and test set clustering labels. 68 | 69 | .. code:: python3 70 | 71 | out.train_cllab 72 | # array([0, 1, 0, 1, 0, 0, 1... 73 | out.test_cllab 74 | # array([0, 0, 0, 0, 1... 75 | out.train_acc 76 | # 1.0 77 | out.test_acc 78 | # 1.0 79 | 80 | Attribute ``cv_results_`` of :class:`FindBestClustCV` returns a dataframe with training and validation 81 | misclassification errors. 82 | 83 | .. code:: python3 84 | 85 | findbestclust.cv_results_ 86 | 87 | To visualize performance metrics during cross-validation, i.e., training stability and validation normalized stability 88 | with confidence intervals: 89 | 90 | .. code:: python3 91 | 92 | from reval.visualization import plot_metrics 93 | plot_metrics(metrics, title="Reval metrics") 94 | 95 | .. image:: images/performanceexample.png 96 | :align: center 97 | 98 | The plot can be customized and also show the normalized stability of a random classifier for each number of clusters 99 | to evaluate the model performance. 100 | 101 | .. image:: images/performanceexample2.png 102 | :align: center 103 | 104 | Classifier/clustering selection 105 | ------------------------------- 106 | 107 | Let us now suppose that we are not sure which combination of clustering and classifier to use 108 | for the blobs dataset. We might want to try both hierarchical clustering and k-means and KNN and 109 | logistic regression. We import the libraries we have not imported before including the 110 | :class:`SCParamSelection` from the ``param_selection.py`` module. 111 | 112 | .. code:: python3 113 | 114 | from sklearn.linear_model import LogisticRegression 115 | from sklearn.cluster import KMeans 116 | from reval.param_selection import SCParamSelection 117 | 118 | We initialize the parameter selection class with a dictionary that includes the classification and 119 | clustering algorithms we want to run and we initialize a 10x2 repeated cross validation with 10 runs of random 120 | labeling. We set the number of parallel processes to 7 to speed up computations. 121 | 122 | .. code:: python3 123 | 124 | sc_params = {'s': [LogisticRegression(), KNeighborsClassifier()], 125 | 'c': [AgglomerativeClustering(), KMeans()]} 126 | scparsel = SCParamSelection(sc_params, cv=2, nrand=10, n_jobs=7, 127 | iter_cv=10, clust_range=list(range(2, 11)), 128 | strat=y_tr) 129 | scparsel.fit(X_tr, nclass=2) 130 | 131 | In this case we knew the true number of clusters a priori, so we passed it to the ``fit()`` method in 132 | order to prioritize the parameter combinations that select the true number of clusters, along with the 133 | combinations with global minimum stability. As a result, four different combinations are run and all of 134 | them selected two as the best number of clusters with minimum stability. 135 | 136 | Parameter selection 137 | ------------------- 138 | 139 | Let us now settle with hierarchical clustering and KNN and suppose we want to try different number of 140 | neighbors for KNN, i.e., 5 and 15, and different methods for hierarchical clustering, 141 | i.e., Ward and single-linkage. We can then use the :class:`ParamSelection` as follows: 142 | 143 | .. code:: python3 144 | 145 | from reval.param_selection import ParamSelection 146 | params = {'s': {'n_neighbors': [5, 15]}, 147 | 'c': {'linkage': ['ward', 'single']}} 148 | parsel = ParamSelection(params, cv=2, s=KNeighborsClassifier(), c=AgglomerativeClustering(), 149 | nrand=10, 150 | n_jobs=7, 151 | iter_cv=10, 152 | strat=y_tr, clust_range=list(range(2, 11))) 153 | parsel.fit(X_tr, nclass=2) 154 | 155 | Also in this case we run four different hyperparameter combinations which all report 2 as the best number 156 | of clusters with minimum stability. 157 | 158 | 159 | 160 | 161 | 162 | 163 | 164 | 165 | 166 | 167 | 168 | 169 | -------------------------------------------------------------------------------- /docs/build/html/_sources/index.rst.txt: -------------------------------------------------------------------------------- 1 | .. Relative clustering validation documentation master file, created by 2 | sphinx-quickstart on Mon May 11 18:17:16 2020. 3 | 4 | Stability-based relative clustering validation to determine the best number of cluster 5 | ====================================================================================== 6 | 7 | ``reval`` allows to determine the best clustering solution without a priori knowledge. 8 | It leverages a stability-based relative clustering validation method (Lange et al., 2004) that transforms 9 | a clustering algorithm into a supervised classification problem and selects the number of clusters 10 | that leads to the minimum expected misclassification error, i.e., stability. 11 | 12 | This library allows to: 13 | 14 | 1. Select any classification algorithm from ``sklearn`` library; 15 | 2. Select a clustering algorithm with ``n_clusters`` parameter or HDBSCAN density-based algorithm, 16 | i.e., choose among ``sklearn.cluster.KMeans``, 17 | ``sklearn.cluster.AgglomerativeClustering``, ``sklearn.cluster.SpectralClustering``, ``hdbscan.HDBSCAN``; 18 | 3. Perform (repeated) *k*-fold cross-validation to determine the best number of clusters; 19 | 4. Test the final model on an held-out dataset. 20 | 21 | Theoretical background can be found in (Lange et al., 2004), whereas code can be found on `github 22 | `__. 23 | 24 | The analysis steps performed by ``reval`` package are displayed below. 25 | 26 | .. image:: images/revalv0.0.2pipeline.png 27 | :align: center 28 | 29 | Lange, T., Roth, V., Braun, M. L., & Buhmann, J. M. (2004). 30 | Stability-based validation of clustering solutions. *Neural computation*, 16(6), 1299-1323. 31 | 32 | .. toctree:: 33 | :maxdepth: 2 34 | :caption: User guide / Tutorial 35 | 36 | installing 37 | code_usage 38 | experiments 39 | datadimension 40 | 41 | .. toctree:: 42 | :maxdepth: 2 43 | :caption: Code guide 44 | 45 | code_description 46 | 47 | Cite as 48 | ======= 49 | 50 | .. parsed-literal:: 51 | 52 | Isotta Landi, Veronica Mandelli, & Michael Vincent Lombardo. (2020, June 29). reval: stability-based relative 53 | clustering validation method to determine the best number of clusters (Version v1.0.0). Zenodo. 54 | http://doi.org/10.5281/zenodo.3922334 55 | 56 | BibTeX alternative 57 | 58 | .. parsed-literal:: 59 | 60 | @software{isotta_landi_2020_3922334, 61 | author = {Isotta Landi and 62 | Veronica Mandelli and 63 | Michael Vincent Lombardo}, 64 | title = {{reval: stability-based relative clustering 65 | validation method to determine the best number of 66 | clusters}}, 67 | month = jun, 68 | year = 2020, 69 | publisher = {Zenodo}, 70 | version = {v1.0.0}, 71 | doi = {10.5281/zenodo.3922334}, 72 | url = {https://doi.org/10.5281/zenodo.3922334} 73 | } 74 | 75 | Pre-print manuscript 76 | 77 | .. parsed-literal:: 78 | 79 | @misc{l2020reval, 80 | title={reval: a Python package to determine the best number of clusters with stability-based relative clustering validation}, 81 | author={Isotta Landi and Veronica Mandelli and Michael V. Lombardo}, 82 | year={2020}, 83 | eprint={2009.01077}, 84 | archivePrefix={arXiv}, 85 | primaryClass={cs.LG} 86 | } 87 | 88 | Indices and tables 89 | ================== 90 | * :ref:`genindex` 91 | * :ref:`modindex` 92 | * :ref:`search` 93 | -------------------------------------------------------------------------------- /docs/build/html/_sources/installing.rst.txt: -------------------------------------------------------------------------------- 1 | Installing 2 | ========== 3 | 4 | From github, navigate to the folder you want ``reval`` library in, open terminal and run: 5 | 6 | .. code:: bash 7 | 8 | git clone https://github.com/IIT-LAND/reval_clustering 9 | pip install -r requirements.txt 10 | 11 | PyPI alternative: 12 | 13 | .. code:: bash 14 | 15 | pip install reval 16 | -------------------------------------------------------------------------------- /docs/build/html/_static/classic.css: -------------------------------------------------------------------------------- 1 | /* 2 | * classic.css_t 3 | * ~~~~~~~~~~~~~ 4 | * 5 | * Sphinx stylesheet -- classic theme. 6 | * 7 | * :copyright: Copyright 2007-2020 by the Sphinx team, see AUTHORS. 8 | * :license: BSD, see LICENSE for details. 9 | * 10 | */ 11 | 12 | @import url("basic.css"); 13 | 14 | /* -- page layout ----------------------------------------------------------- */ 15 | 16 | html { 17 | /* CSS hack for macOS's scrollbar (see #1125) */ 18 | background-color: #FFFFFF; 19 | } 20 | 21 | body { 22 | font-family: sans-serif; 23 | font-size: 100%; 24 | background-color: #11303d; 25 | color: #000; 26 | margin: 0; 27 | padding: 0; 28 | } 29 | 30 | div.document { 31 | background-color: #1c4e63; 32 | } 33 | 34 | div.documentwrapper { 35 | float: left; 36 | width: 100%; 37 | } 38 | 39 | div.bodywrapper { 40 | margin: 0 0 0 230px; 41 | } 42 | 43 | div.body { 44 | background-color: #ffffff; 45 | color: #000000; 46 | padding: 0 20px 30px 20px; 47 | } 48 | 49 | div.footer { 50 | color: #ffffff; 51 | width: 100%; 52 | padding: 9px 0 9px 0; 53 | text-align: center; 54 | font-size: 75%; 55 | } 56 | 57 | div.footer a { 58 | color: #ffffff; 59 | text-decoration: underline; 60 | } 61 | 62 | div.related { 63 | background-color: #133f52; 64 | line-height: 30px; 65 | color: #ffffff; 66 | } 67 | 68 | div.related a { 69 | color: #ffffff; 70 | } 71 | 72 | div.sphinxsidebar { 73 | } 74 | 75 | div.sphinxsidebar h3 { 76 | font-family: 'Trebuchet MS', sans-serif; 77 | color: #ffffff; 78 | font-size: 1.4em; 79 | font-weight: normal; 80 | margin: 0; 81 | padding: 0; 82 | } 83 | 84 | div.sphinxsidebar h3 a { 85 | color: #ffffff; 86 | } 87 | 88 | div.sphinxsidebar h4 { 89 | font-family: 'Trebuchet MS', sans-serif; 90 | color: #ffffff; 91 | font-size: 1.3em; 92 | font-weight: normal; 93 | margin: 5px 0 0 0; 94 | padding: 0; 95 | } 96 | 97 | div.sphinxsidebar p { 98 | color: #ffffff; 99 | } 100 | 101 | div.sphinxsidebar p.topless { 102 | margin: 5px 10px 10px 10px; 103 | } 104 | 105 | div.sphinxsidebar ul { 106 | margin: 10px; 107 | padding: 0; 108 | color: #ffffff; 109 | } 110 | 111 | div.sphinxsidebar a { 112 | color: #98dbcc; 113 | } 114 | 115 | div.sphinxsidebar input { 116 | border: 1px solid #98dbcc; 117 | font-family: sans-serif; 118 | font-size: 1em; 119 | } 120 | 121 | 122 | 123 | /* -- hyperlink styles ------------------------------------------------------ */ 124 | 125 | a { 126 | color: #355f7c; 127 | text-decoration: none; 128 | } 129 | 130 | a:visited { 131 | color: #355f7c; 132 | text-decoration: none; 133 | } 134 | 135 | a:hover { 136 | text-decoration: underline; 137 | } 138 | 139 | 140 | 141 | /* -- body styles ----------------------------------------------------------- */ 142 | 143 | div.body h1, 144 | div.body h2, 145 | div.body h3, 146 | div.body h4, 147 | div.body h5, 148 | div.body h6 { 149 | font-family: 'Trebuchet MS', sans-serif; 150 | background-color: #f2f2f2; 151 | font-weight: normal; 152 | color: #20435c; 153 | border-bottom: 1px solid #ccc; 154 | margin: 20px -20px 10px -20px; 155 | padding: 3px 0 3px 10px; 156 | } 157 | 158 | div.body h1 { margin-top: 0; font-size: 200%; } 159 | div.body h2 { font-size: 160%; } 160 | div.body h3 { font-size: 140%; } 161 | div.body h4 { font-size: 120%; } 162 | div.body h5 { font-size: 110%; } 163 | div.body h6 { font-size: 100%; } 164 | 165 | a.headerlink { 166 | color: #c60f0f; 167 | font-size: 0.8em; 168 | padding: 0 4px 0 4px; 169 | text-decoration: none; 170 | } 171 | 172 | a.headerlink:hover { 173 | background-color: #c60f0f; 174 | color: white; 175 | } 176 | 177 | div.body p, div.body dd, div.body li, div.body blockquote { 178 | text-align: justify; 179 | line-height: 130%; 180 | } 181 | 182 | div.admonition p.admonition-title + p { 183 | display: inline; 184 | } 185 | 186 | div.admonition p { 187 | margin-bottom: 5px; 188 | } 189 | 190 | div.admonition pre { 191 | margin-bottom: 5px; 192 | } 193 | 194 | div.admonition ul, div.admonition ol { 195 | margin-bottom: 5px; 196 | } 197 | 198 | div.note { 199 | background-color: #eee; 200 | border: 1px solid #ccc; 201 | } 202 | 203 | div.seealso { 204 | background-color: #ffc; 205 | border: 1px solid #ff6; 206 | } 207 | 208 | div.topic { 209 | background-color: #eee; 210 | } 211 | 212 | div.warning { 213 | background-color: #ffe4e4; 214 | border: 1px solid #f66; 215 | } 216 | 217 | p.admonition-title { 218 | display: inline; 219 | } 220 | 221 | p.admonition-title:after { 222 | content: ":"; 223 | } 224 | 225 | pre { 226 | padding: 5px; 227 | background-color: #eeffcc; 228 | color: #333333; 229 | line-height: 120%; 230 | border: 1px solid #ac9; 231 | border-left: none; 232 | border-right: none; 233 | } 234 | 235 | code { 236 | background-color: #ecf0f3; 237 | padding: 0 1px 0 1px; 238 | font-size: 0.95em; 239 | } 240 | 241 | th, dl.field-list > dt { 242 | background-color: #ede; 243 | } 244 | 245 | .warning code { 246 | background: #efc2c2; 247 | } 248 | 249 | .note code { 250 | background: #d6d6d6; 251 | } 252 | 253 | .viewcode-back { 254 | font-family: sans-serif; 255 | } 256 | 257 | div.viewcode-block:target { 258 | background-color: #f4debf; 259 | border-top: 1px solid #ac9; 260 | border-bottom: 1px solid #ac9; 261 | } 262 | 263 | div.code-block-caption { 264 | color: #efefef; 265 | background-color: #1c4e63; 266 | } -------------------------------------------------------------------------------- /docs/build/html/_static/css/badge_only.css: -------------------------------------------------------------------------------- 1 | .fa:before{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-style:normal;font-weight:400;src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713?#iefix) format("embedded-opentype"),url(fonts/fontawesome-webfont.woff2?af7ae505a9eed503f8b8e6982036873e) format("woff2"),url(fonts/fontawesome-webfont.woff?fee66e712a8a08eef5805a46892932ad) format("woff"),url(fonts/fontawesome-webfont.ttf?b06871f281fee6b241d60582ae9369b9) format("truetype"),url(fonts/fontawesome-webfont.svg?912ec66d7572ff821749319396470bde#FontAwesome) format("svg")}.fa:before{font-family:FontAwesome;font-style:normal;font-weight:400;line-height:1}.fa:before,a .fa{text-decoration:inherit}.fa:before,a .fa,li .fa{display:inline-block}li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before,.icon-book:before{content:"\f02d"}.fa-caret-down:before,.icon-caret-down:before{content:"\f0d7"}.fa-caret-up:before,.icon-caret-up:before{content:"\f0d8"}.fa-caret-left:before,.icon-caret-left:before{content:"\f0d9"}.fa-caret-right:before,.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60}.rst-versions .rst-current-version:after{clear:both;content:"";display:block}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}} -------------------------------------------------------------------------------- /docs/build/html/_static/custom.css: -------------------------------------------------------------------------------- 1 | /* This file intentionally left blank. */ 2 | -------------------------------------------------------------------------------- /docs/build/html/_static/documentation_options.js: -------------------------------------------------------------------------------- 1 | var DOCUMENTATION_OPTIONS = { 2 | URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'), 3 | VERSION: '0.0.1', 4 | LANGUAGE: 'None', 5 | COLLAPSE_INDEX: false, 6 | BUILDER: 'html', 7 | FILE_SUFFIX: '.html', 8 | LINK_SUFFIX: '.html', 9 | HAS_SOURCE: true, 10 | SOURCELINK_SUFFIX: '.txt', 11 | NAVIGATION_WITH_KEYS: false 12 | }; -------------------------------------------------------------------------------- /docs/build/html/_static/file.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/file.png -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Inconsolata-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Inconsolata-Bold.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Inconsolata-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Inconsolata-Regular.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Inconsolata.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Inconsolata.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato-Bold.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato-Regular.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bold.eot -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bold.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bold.woff -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bold.woff2 -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bolditalic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bolditalic.eot -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bolditalic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bolditalic.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bolditalic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bolditalic.woff -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-bolditalic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-bolditalic.woff2 -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-italic.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-italic.eot -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-italic.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-italic.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-italic.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-italic.woff -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-italic.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-italic.woff2 -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-regular.eot -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-regular.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-regular.woff -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/Lato/lato-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/Lato/lato-regular.woff2 -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab-Bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab-Bold.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab-Regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab-Regular.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.eot -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff2 -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.eot -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff2 -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/fontawesome-webfont.eot: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/fontawesome-webfont.eot -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/fontawesome-webfont.ttf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/fontawesome-webfont.ttf -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/fontawesome-webfont.woff: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/fontawesome-webfont.woff -------------------------------------------------------------------------------- /docs/build/html/_static/fonts/fontawesome-webfont.woff2: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/IIT-LAND/reval_clustering/e69015b50bf4cdd44c8c89dce37597b639c5bb8c/docs/build/html/_static/fonts/fontawesome-webfont.woff2 -------------------------------------------------------------------------------- /docs/build/html/_static/js/theme.js: -------------------------------------------------------------------------------- 1 | !function(n){var e={};function t(i){if(e[i])return e[i].exports;var o=e[i]={i:i,l:!1,exports:{}};return n[i].call(o.exports,o,o.exports,t),o.l=!0,o.exports}t.m=n,t.c=e,t.d=function(n,e,i){t.o(n,e)||Object.defineProperty(n,e,{enumerable:!0,get:i})},t.r=function(n){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},t.t=function(n,e){if(1&e&&(n=t(n)),8&e)return n;if(4&e&&"object"==typeof n&&n&&n.__esModule)return n;var i=Object.create(null);if(t.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:n}),2&e&&"string"!=typeof n)for(var o in n)t.d(i,o,function(e){return n[e]}.bind(null,o));return i},t.n=function(n){var e=n&&n.__esModule?function(){return n.default}:function(){return n};return t.d(e,"a",e),e},t.o=function(n,e){return Object.prototype.hasOwnProperty.call(n,e)},t.p="",t(t.s=0)}([function(n,e,t){t(1),n.exports=t(3)},function(n,e,t){(function(){var e="undefined"!=typeof window?window.jQuery:t(2);n.exports.ThemeNav={navBar:null,win:null,winScroll:!1,winResize:!1,linkScroll:!1,winPosition:0,winHeight:null,docHeight:null,isRunning:!1,enable:function(n){var t=this;void 0===n&&(n=!0),t.isRunning||(t.isRunning=!0,e((function(e){t.init(e),t.reset(),t.win.on("hashchange",t.reset),n&&t.win.on("scroll",(function(){t.linkScroll||t.winScroll||(t.winScroll=!0,requestAnimationFrame((function(){t.onScroll()})))})),t.win.on("resize",(function(){t.winResize||(t.winResize=!0,requestAnimationFrame((function(){t.onResize()})))})),t.onResize()})))},enableSticky:function(){this.enable(!0)},init:function(n){n(document);var e=this;this.navBar=n("div.wy-side-scroll:first"),this.win=n(window),n(document).on("click","[data-toggle='wy-nav-top']",(function(){n("[data-toggle='wy-nav-shift']").toggleClass("shift"),n("[data-toggle='rst-versions']").toggleClass("shift")})).on("click",".wy-menu-vertical .current ul li a",(function(){var t=n(this);n("[data-toggle='wy-nav-shift']").removeClass("shift"),n("[data-toggle='rst-versions']").toggleClass("shift"),e.toggleCurrent(t),e.hashChange()})).on("click","[data-toggle='rst-current-version']",(function(){n("[data-toggle='rst-versions']").toggleClass("shift-up")})),n("table.docutils:not(.field-list,.footnote,.citation)").wrap("
"),n("table.docutils.footnote").wrap("
"),n("table.docutils.citation").wrap("
"),n(".wy-menu-vertical ul").not(".simple").siblings("a").each((function(){var t=n(this);expand=n(''),expand.on("click",(function(n){return e.toggleCurrent(t),n.stopPropagation(),!1})),t.prepend(expand)}))},reset:function(){var n=encodeURI(window.location.hash)||"#";try{var e=$(".wy-menu-vertical"),t=e.find('[href="'+n+'"]');if(0===t.length){var i=$('.document [id="'+n.substring(1)+'"]').closest("div.section");0===(t=e.find('[href="#'+i.attr("id")+'"]')).length&&(t=e.find('[href="#"]'))}t.length>0&&($(".wy-menu-vertical .current").removeClass("current"),t.addClass("current"),t.closest("li.toctree-l1").addClass("current"),t.closest("li.toctree-l1").parent().addClass("current"),t.closest("li.toctree-l1").addClass("current"),t.closest("li.toctree-l2").addClass("current"),t.closest("li.toctree-l3").addClass("current"),t.closest("li.toctree-l4").addClass("current"),t.closest("li.toctree-l5").addClass("current"),t[0].scrollIntoView())}catch(n){console.log("Error expanding nav for anchor",n)}},onScroll:function(){this.winScroll=!1;var n=this.win.scrollTop(),e=n+this.winHeight,t=this.navBar.scrollTop()+(n-this.winPosition);n<0||e>this.docHeight||(this.navBar.scrollTop(t),this.winPosition=n)},onResize:function(){this.winResize=!1,this.winHeight=this.win.height(),this.docHeight=$(document).height()},hashChange:function(){this.linkScroll=!0,this.win.one("hashchange",(function(){this.linkScroll=!1}))},toggleCurrent:function(n){var e=n.closest("li");e.siblings("li.current").removeClass("current"),e.siblings().find("li.current").removeClass("current"),e.find("> ul li.current").removeClass("current"),e.toggleClass("current")}},"undefined"!=typeof window&&(window.SphinxRtdTheme={Navigation:n.exports.ThemeNav,StickyNav:n.exports.ThemeNav}),function(){for(var n=0,e=["ms","moz","webkit","o"],t=0;t