clus

A complete fuzzy clus framework


Keywords
cli, clus, clustering, fuzzy, fuzzy_clustering, research, upmc, sorbonne, sorbonne_universite, fcm, fcmdd, fuzzy-clustering, kmeans, pcm, pypi-package, research-tool
License
GPL-3.0
Install
pip install clus==0.0.2

Documentation

clustering

Clustering and fuzzy-clustering library with integrated CLI.

Installation

$ python3 setup.py install

Running the setup.py script will download all required packages and install the following commands either in your ~/.local/bin/ for local installation or in the /usr/lib/pythonX.X directories :

  • clus : Main command for partition-based clustering.
  • dclus : density-based clustering.
  • hclus : Hierarchical clustering.
  • eclus : Evaluate clustering. Implementing diferents way to evaluate clustering results by comparing two partitions.

Usage

# Simple clustering with 500-components kmeans algorithm
$ clus dataset.csv kmeans -k 500 --max-iter 100  --eps 0.001 --header --save-clus

# Clustering with a weighted euclidean distance + matplotlib visualisation
$ clus dataset.npy kmeans --pairwise-distance weighted_euclidean --weights 1 0 1 1 --visualise

# Clustering from a .npz file with a 3D matplotlib visualisation
$ clus dataset.npz fcm --array-name clusters_center --visualise-3d

# Clustering with automatic dataset filetype guessing and with a normalization beforehand 
$ clus dataset kmeans --file-type guess --normalization rescaling --save-clus

# DBSCAN clustering with a custom clustering results saving path
$ dclus dataset.csv dbscan --save-clus --seed 1 --format-filename-dest-results dbased_{clustering_algorithm}_{dataset}_{seed}

TODO

References