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

Logits or softmax probabilities #2

Closed
YanWang2014 opened this issue Nov 4, 2017 · 3 comments
Closed

Logits or softmax probabilities #2

YanWang2014 opened this issue Nov 4, 2017 · 3 comments

Comments

@YanWang2014
Copy link

YanWang2014 commented Nov 4, 2017

In the paper,

Through this loss function, we aim to directly penalize the distance between the
predicted output logits.

So for the PairwiseConfusion, we are using logits? which is the direct output of pytorch models.

But for EntropicConfusion, obviously we should use softmax probabilities, which is obtained by feeding logits through a softmax function.

Am I right?
Thank you

@abhimanyudubey
Copy link
Owner

Hi Yan,

For both models of confusion, the preferred usage is softmax probabilities (obtained after feeding the logits through a softmax). You can, alternatively, try the logits for pairwise confusion, but the loss weight will have to be scaled to a very small value to prevent oscillations, and hence we recommend operating on the softmax probabilities themselves.

Abhi

@YanWang2014
Copy link
Author

Thank you!

@twmht
Copy link

twmht commented Feb 19, 2019

@abhimanyudubey

In the Entropy confusion (https://github.com/abhimanyudubey/confusion/blob/master/confusion_pytorch/__init__.py#L15), it seems that you missed a negative sign according to the paper. isn't this a loss function?

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

3 participants