affinity-loss icon indicating copy to clipboard operation
affinity-loss copied to clipboard

Some questions about the calculation of rw in GaussianAffinity Loss

Open A-New-Page opened this issue 2 years ago • 0 comments

In your code, when regularization is computed, the rw is multiplied by a coefficient, that is:

https://github.com/koshian2/affinity-loss/blob/c678c3cd5c63767ff4217733bd978e0d9ef24ceb/affinity_loss.py#L46

But in the original paper, the coefficient is unnecessary, see Equations 7 and 8 for details. And the coefficient should only be multiplied in the calculation of mu, that is

https://github.com/koshian2/affinity-loss/blob/c678c3cd5c63767ff4217733bd978e0d9ef24ceb/affinity_loss.py#L44

May I ask why this coefficient is multiplied twice? Thanks!

A-New-Page avatar Feb 24 '23 03:02 A-New-Page