KNN digit recognizer