Skip to content

Instantly share code, notes, and snippets.

@amueller
Last active December 14, 2015 05:18
Show Gist options
  • Save amueller/5033992 to your computer and use it in GitHub Desktop.
Save amueller/5033992 to your computer and use it in GitHub Desktop.
simple kmeans test with n_jobs=2
from sklearn.cluster import KMeans
from sklearn.datasets import make_blobs
X, y = make_blobs()
KMeans(n_jobs=2).fit(X)
print("done")
from sklearn.cluster import KMeans
from sklearn.datasets import make_blobs
def main():
X, y = make_blobs()
KMeans(n_jobs=2).fit(X)
print("done")
if __name__ == "__main__":
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment