fix bug on dendrogram--crashing on Chinese files, cleanup on KMeans