Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How to calculate the clusterig (KLD) loss for every instance #27

Open
djsavic opened this issue Oct 30, 2021 · 0 comments
Open

How to calculate the clusterig (KLD) loss for every instance #27

djsavic opened this issue Oct 30, 2021 · 0 comments

Comments

@djsavic
Copy link

djsavic commented Oct 30, 2021

Great work!
For the problem I studied, the accuracy reaches 97%, which is very impressive.
How can I compute the DEC loss of every instance after the training has been completed. For the autoencoder, it is straightforward by defining a simple function:

def ae_loss(autoencoder, X):
    ae_rec = autoencoder.predict(X)  
    ae_loss = tf.keras.losses.mse(ae_rec, X)  
    return ae_loss

Defining similar function for computing the clustering loss is not working. Any idea how can this be implemented?
I would like to do a further investigation by studying the loss distribution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant