xingyizhou / CenterNet2

Two-stage CenterNet
Apache License 2.0
1.21k stars 188 forks source link

About Gaussian kernel calculation #72

Open shenjiantao opened 3 years ago

shenjiantao commented 3 years ago

https://github.com/xingyizhou/CenterNet2/blob/9ba5c8e6ba6b44afc1c19d7767b0ec72cb314586/projects/CenterNet2/centernet/modeling/dense_heads/centernet.py#L306 I can't understand this part of the code well,can you provide complete mathematical formulas?How to calculate the Gaussian kernel and apply it in the heatmap?Thanks very much.

xingyizhou commented 2 years ago

Hi, Thank you for your interest and sorry for the delay. The radius is a simplified version of the original radius used in CornerNet and CenterNet. I just want the radius to be proportional to sqrt(area). Other factors can be controlled by self.delta. I believe I did not do strict math here, but just set this empirically.