K-Means is an Unsupervised Machine Learning technique and a powerful algorithm for data clustering or even use it for image processing tasks. Specifically, K-Means is a data clustering algorithm that tries to assign every data point in a dataset to exactly one of K possible clusters. The main idea here is that the algorithm tries to build the clusters in such way that two data points from the same cluster are as similar as possible, while two data points from two different clusters are as different as possible.
This code uses K-Means Clustering on biomedical image to perform image segmentation. Besides, Elbow Method is used to determine the optimal value of k in K-Means.