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

loss不是很懂 #19

Open
henbucuoshanghai opened this issue Jul 29, 2021 · 6 comments
Open

loss不是很懂 #19

henbucuoshanghai opened this issue Jul 29, 2021 · 6 comments

Comments

@henbucuoshanghai
Copy link

No description provided.

@henbucuoshanghai
Copy link
Author

self.binar_map_loss = (torch.abs(binar_map-mask_gt)).mean()

        self.head_map_loss = F.mse_loss(pre_map, mask_gt)

请问为什么二个map在回归的时候 均和mask_gt计算loss? 那这样的话 推理的时候直接任何一个map不就是最后的结果?为什么二者做差呢?不是很懂 多谢

@taohan10200
Copy link
Owner

两个损失针对的是不同的对象,一个是二值化后的输出,一个是二值化前的,二值化后的输出才是最后用来检测连通域进行定位的输出。二者作差即L1损失。

@henbucuoshanghai
Copy link
Author

henbucuoshanghai commented Aug 1, 2021 via email

@taohan10200
Copy link
Owner

pre_map和gt计算L2 loss, gt 是[0,1]的mask图。 没有出现两个map做差再和gt算L1 loss的, 用来计算L1 loss的是二值化后的输出binar_map。

@henbucuoshanghai
Copy link
Author

你好 感谢回复 请问figure1的 图 代码有公开吗?请问在哪里呢?感谢

@henbucuoshanghai
Copy link
Author

密度图方法是怎样生成groundtruth的? 直接人头中心是一个点,只有一个点吗?密度图的gt云图是怎么得到的?

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

2 participants