Fixes ticket #773

moving kmeans.py to models and fixing Jia, et al. NIPS 2011 workshop paper implementation