Kmeans with fine grained locks