Efficient implementation of the clustering using the Expectation Maximization (EM) and K-means algorithms
To apply the EM algorithm on a dateset one needs to call:
$ L = gmm.EM(max_iter=max_iter, tol = tol)
To apply the K-means algorithm on a dataset one needs to call:
$ D = gmm.k_means(max_iter=max_iter, tol=tol)
To sample from an already trained GMM model, one needs to call:
$ Y = gmm.sample(N=N)
Several examples can be found within the main.py file.
[1] Results of the EM algorithm over iterations
[1] Unlabelled data
[2] Labelled data
[1] Final result of the EM algorithm
[2] Final result of the EM algorithm (covariance matrices)
[3] EM cost function over iterations
[1] Final result of the K-means algorithm
[2] K-means cost function over iterations
[1] Sampling results from already trained GMM model