update kmeans using python