Last active
January 26, 2019 06:06
-
-
Save ashunigion/393a192d314ba19913db3b7213f13175 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from sklearn.cluster import KMeans | |
kmeans_0 = KMeans(n_clusters=10, init='k-means++',random_state=0).fit(label_0) | |
sample_0 = kmeans_0.cluster_centers_ | |
kmeans_1 = KMeans(n_clusters=10, init='k-means++',random_state=0).fit(label_1) | |
sample_1 = kmeans_1.cluster_centers_ | |
#the code can be repeated for all the intermediate labels | |
#... | |
kmeans_9 = KMeans(n_clusters=10, init='k-means++',random_state=0).fit(label_9) | |
sample_9 = kmeans_9.cluster_centers_ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment