koraykv / unsup

Some unsupervised learning modules using Torch
86 stars 36 forks source link

kmeans - NaN Centroids #1

Closed jtbates closed 11 years ago

jtbates commented 11 years ago

In the kmeans function if no sample is matched to a given centroid during an iteration then there is a divide by zero and the centroid becomes NaN (line 76)

clementfarabet commented 11 years ago

Oups, thanks for the patch!

culurciello commented 11 years ago

good job guys patching this much needed