Added initial version of adaptive k-means.