rymc / n2d

A deep clustering algorithm. Code to reproduce results for our paper N2D: (Not Too) Deep Clustering via Clustering the Local Manifold of an Autoencoded Embedding.
GNU General Public License v3.0
129 stars 21 forks source link

how to use it if there's no labels #7

Closed stellaywu closed 4 years ago

stellaywu commented 4 years ago

Thanks for the implementation, I am trying to use the code on an unsupervised clustering problem. Is it possible to not feed labels? Thanks!

rymc commented 4 years ago

Hi,

The code expects labels just for the evaluation. If you set 'y' (the labels) to None, I think that the code will currently fail on line 233. But on line 231, we have already computed y_pred which is your predicted labels. So if you add a line of code at 231, you should be able to save the clusters without having the labels.

Alternatively @josephsdavid has reimplemented this unsupervised clustering algorithm into an easier to use API. You may want to have a look at https://github.com/josephsdavid/N2D - it may be easier to work with in your setting.

Best wishes Ryan

stellaywu commented 4 years ago

thanks!