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

关于模型train阶段的问题 #6

Open
mymuli opened this issue Apr 24, 2022 · 2 comments
Open

关于模型train阶段的问题 #6

mymuli opened this issue Apr 24, 2022 · 2 comments

Comments

@mymuli
Copy link

mymuli commented Apr 24, 2022

您好!
我想问一下:
Q1: 在模型训练的时候,模型最终是几个输出?是 BatchFormer前的classifier + BatchFormer后的classifier 这两个输出呢?然后分别与ground truth计算呢?

Q2: 代码里面,如下所示,这行代码表示的是BatchFormer后的classifier的输出呢?还是对模型两个classifier的输出做concat操作后,最后再与ground truth计算呢?

return torch.cat([pre_feature, feature], dim=0)

@zhihou7
Copy link
Owner

zhihou7 commented Apr 25, 2022

Sorry for getting you latter.
A1: Yes, you can understand like that.
A2: We can concat the two outputs of the classifier, and calculate the loss with the Ground Truth. Because the classifier is shared, we can thus directly concat the feature and duplicate the labels. Actually, we concat the feature between before BatchFormer and after BatchFormer.

By the way, for moco-v3, it is not necessary to use the two features according to our new experience.

@yandun72
Copy link

really thanks for your reply,I understand it!thanks very much!

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

3 participants