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

About labeled Regression Loss(Gaussian Probability) #7

Open
JooYJang opened this issue Mar 24, 2023 · 0 comments
Open

About labeled Regression Loss(Gaussian Probability) #7

JooYJang opened this issue Mar 24, 2023 · 0 comments

Comments

@JooYJang
Copy link

Hello, Thank you for sharing interesting research

I'm wondering why gaussian pdf is directly used to formulate labeled regression loss as a cross-entropy loss.
Is this generally used?

gaussian = gaussian_dist_pdf(fg_pred_deltas[..., :4],  gt_pred_deltas, sigma_xywh)
loss_box_reg_gaussian = - torch.log(gaussian + 1e-9).sum()

and gaussian_dist_pdf

def gaussian_dist_pdf(val, mean, var, eps=1e-9):
     simga_constant = 0.3
     return torch.exp(-(val - mean) ** 2.0 / (var + eps) / 2.0) / torch.sqrt(2.0 * np.pi * (var + simga_constant))

As far as I understand, the goal of mean and variance term used in this paper is to be gt_box (x_off, y_off, box_width, box_height) and zeros, since gt has direct delta fucntion with mean = gt_box and var = 0.
In this respect, directly using gaussian pdf as above would have infinite loss.

p.s/ How did you get sigma_constant = 0.3??

Thanks in advance
Joo Young Jang

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