DEC-Keras
DEC-Keras copied to clipboard
visualize
how can we visualize the clusters?
To visualize the components in 2d, perform predictions using only the encoder to get the embedded vectors for each sample. Then perform a PCA with two components on this array and plot the array using matplot lib. If you make predictions with the whole model, you will get a reconstruction of the image, which does not give us useful clusters, get the embedded vectors using model.get_layer(index=0).predict(X).
or possibly use model.encoder.predict(X)