title: KNN classifier taking too much time even on gpu
body: <p>I am classifying the MNSIT digit using KNN on kaggle but at last step it is taking to much time to execute and mnsit data is juts 15 mb like i am still waiting can you point any problem that is in my code thanks. </p>
  
  <pre><code>import numpy as np # linear algebra
  import pandas as pd # data processing, CSV file I/O (e.g. pd.read_csv)
  
  import os
  print(os.listdir("../input"))
  #Loading datset
  
  train=pd.read_csv('../input/mnist_test.csv')
  
  test=pd.read_csv('../input/mnist_train.csv')
  
  X_train=train.drop('label',axis=1)
  
  y_train=train['label']
  
  X_test=test.drop('label',axis=1)
  
  y_test=test['label']
  
  from sklearn.neighbors import KNeighborsClassifier
  
  clf=KNeighborsClassifier(n_neighbors=3)
  
  clf.fit(X_train,y_train)
  
  accuracy=clf.score(X_test,y_test)
  
  accuracy
  </code></pre>