All Projects → fcomitani → Simpsom

fcomitani / Simpsom

Licence: mit
Python library for Self-Organizing Maps

Programming Languages

python
139335 projects - #7 most used programming language

Projects that are alternatives of or similar to Simpsom

Icellr
Single (i) Cell R package (iCellR) is an interactive R package to work with high-throughput single cell sequencing technologies (i.e scRNA-seq, scVDJ-seq, ST and CITE-seq).
Stars: ✭ 80 (-19.19%)
Mutual labels:  clustering
Swarm
A robust and fast clustering method for amplicon-based studies
Stars: ✭ 88 (-11.11%)
Mutual labels:  clustering
R Course
Una introduccion al analisis de datos con R y R Studio
Stars: ✭ 93 (-6.06%)
Mutual labels:  clustering
Stringlifier
Stringlifier is on Opensource ML Library for detecting random strings in raw text. It can be used in sanitising logs, detecting accidentally exposed credentials and as a pre-processing step in unsupervised ML-based analysis of application text data.
Stars: ✭ 85 (-14.14%)
Mutual labels:  clustering
Machine learning code
机器学习与深度学习算法示例
Stars: ✭ 88 (-11.11%)
Mutual labels:  clustering
Refinr
Cluster and merge similar char values: an R implementation of Open Refine clustering algorithms
Stars: ✭ 91 (-8.08%)
Mutual labels:  clustering
Lithosphere Docker
The docker for lithosphere project
Stars: ✭ 76 (-23.23%)
Mutual labels:  clustering
Text Summarizer
Python Framework for Extractive Text Summarization
Stars: ✭ 96 (-3.03%)
Mutual labels:  clustering
Cop Kmeans
A Python implementation of COP-KMEANS algorithm
Stars: ✭ 88 (-11.11%)
Mutual labels:  clustering
Hazelcast Python Client
Hazelcast IMDG Python Client
Stars: ✭ 92 (-7.07%)
Mutual labels:  clustering
Ml
A high-level machine learning and deep learning library for the PHP language.
Stars: ✭ 1,270 (+1182.83%)
Mutual labels:  clustering
N2d
A deep clustering algorithm. Code to reproduce results for the paper N2D: (Not Too) Deep Clustering via Clustering the Local Manifold of an Autoencoded Embedding.
Stars: ✭ 88 (-11.11%)
Mutual labels:  clustering
Fingerprints
Make it easier to compare and cross-reference the names of companies and people by applying strong normalisation.
Stars: ✭ 91 (-8.08%)
Mutual labels:  clustering
Supercluster
A very fast geospatial point clustering library for browsers and Node.
Stars: ✭ 1,246 (+1158.59%)
Mutual labels:  clustering
Retina Features
Project for segmentation of blood vessels, microaneurysm and hardexudates in fundus images.
Stars: ✭ 95 (-4.04%)
Mutual labels:  clustering
Ml code
A repository for recording the machine learning code
Stars: ✭ 75 (-24.24%)
Mutual labels:  clustering
Lda Topic Modeling
A PureScript, browser-based implementation of LDA topic modeling.
Stars: ✭ 91 (-8.08%)
Mutual labels:  clustering
Typescript Restful Starter
Node.js + ExpressJS + Joi + Typeorm + Typescript + JWT + ES2015 + Clustering + Tslint + Mocha + Chai
Stars: ✭ 97 (-2.02%)
Mutual labels:  clustering
Deeptemporalclustering
📈 Keras implementation of the Deep Temporal Clustering (DTC) model
Stars: ✭ 96 (-3.03%)
Mutual labels:  clustering
Uis Rnn
This is the library for the Unbounded Interleaved-State Recurrent Neural Network (UIS-RNN) algorithm, corresponding to the paper Fully Supervised Speaker Diarization.
Stars: ✭ 1,308 (+1221.21%)
Mutual labels:  clustering

SimpSOM (Simple Self-Organizing Maps)

DOI PyPI version Build Status Documentation Status

Version 1.3.4

SimpSOM is a lightweight implementation of Kohonen Self-Organizing Maps (SOM) for Python 2.7 and 3, useful for unsupervised learning, clustering and dimensionality reduction.

The package is now available on PyPI, to retrieve it just type pip install SimpSOM or download it from here and install with python setup.py install.

It allows you to build and train SOM on your dataset, save/load the trained network weights, and display or print graphs of the network with selected features. The function run_colorsExample() will run a toy model, where a number of colors will be mapped from the 3D RGB space to the 2D network map and clustered according to their similarity in the origin space.

Dependencies

  • Numpy 1.11.0 (older versions may work);
  • Matplotlib 1.5.1 (older versions may work);
  • Sklearn 0.15 (older versions may work);

Example of Usage

Here is a quick example on how to use the library with a raw_data dataset:

#Import the library
import SimpSOM as sps

#Build a network 20x20 with a weights format taken from the raw_data and activate Periodic Boundary Conditions. 
net = sps.somNet(20, 20, raw_data, PBC=True)

#Train the network for 10000 epochs and with initial learning rate of 0.01. 
net.train(0.01, 10000)

#Save the weights to file
net.save('filename_weights')

#Print a map of the network nodes and colour them according to the first feature (column number 0) of the dataset
#and then according to the distance between each node and its neighbours.
net.nodes_graph(colnum=0)
net.diff_graph()

#Project the datapoints on the new 2D network map.
net.project(raw_data, labels=labels)

#Cluster the datapoints according to the Quality Threshold algorithm.
net.cluster(raw_data, type='qthresh')	

A More Interesting Example: MNIST

Here is another example of SimpSOM capabilites: the library was used to try and reduce a MNIST handwritten digits dataset. A 50x50 nodes map was trained with 500 MINST landmark datapoints and 100000 epochs in total, starting from a 0.1 learning rate and without PCA Initialisation.

Projecting a few of those points on the map gives the following result, showing a clear distinction between cluster of digits with a few exceptions. Similar shapes (such as 7 and 9) are mapped closed together, while relatively far from other more distinct digits. The accuracy of this mapping could be further improved by tweaking the map parameters, by training the network for more epochs or with a more adequate choice of initial dataset.

Documentation

See here the full API documentation

Citation

If using this library, please cite it as

Federico Comitani, 2019. fcomitani/SimpSOM: v1.3.4. doi:10.5281/zenodo.2621560

What's New

  • It's now possible to explicitly choose the output folder.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].