ovr-cnn icon indicating copy to clipboard operation
ovr-cnn copied to clipboard

a question about loss for background

Open liyunsheng13 opened this issue 2 years ago • 1 comments

❓ Questions and Help

Hi

In your paper of Equation 6, you build the supervised loss for regions. I'm curious whether for the background regions, the numerator of Equation 6 should be 1, while the denominator reminds the same. Besides, I do not find the implementation of this part in your code. Could you point it out for me for further reference?

Thanks

liyunsheng13 avatar Aug 18 '22 18:08 liyunsheng13

Hi Yunsheng,

Thanks for your comment. The loss is a regular CrossEntropyLoss, and does not need a custom implementation. The only difference is how the logits are computed. In open-vocabulary settings, we set the background embedding to an all-zero vector here. This means the exponential of dot product between background weights and any input will be exactly 1. Hence you are right, the numerator will be 1.

alirezazareian avatar Sep 01 '22 17:09 alirezazareian