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

Shift Learning implementation #3

Closed
ZhiyuanDang opened this issue Apr 11, 2021 · 4 comments
Closed

Shift Learning implementation #3

ZhiyuanDang opened this issue Apr 11, 2021 · 4 comments

Comments

@ZhiyuanDang
Copy link

Hi, thanks for your works. However, in your paper, the implementation of shift learning has not been described detail.

I guess that the BN parameters are re-trained in Stage-II, since the different means and variances. Is that true?

@zs-zhong
Copy link
Collaborator

Hello! The BN running parameters (running means and variances) are updated in Stage-II. We fix the BN affine parameters (alpha and beta) in Stage-II.

@ZhiyuanDang
Copy link
Author

Thanks for your reply.

'update' means reset the running means and variances in Stage-I or save them? And, which BN running parameters you adopted at the test phase?

@zs-zhong
Copy link
Collaborator

zs-zhong commented Apr 14, 2021

Hi, Zhiyuan, thanks for your interest! Concretely, in Stage-1, BN is trained on instance-balanced data (normal). The statistic running means and variances are , and the learnable affine parameters are . In Stage-2, we fix the learnable affine parameters and momentum update on classes-balanced data (re-sample). Finally, we get new statistic running means and variances . During the test phase, we adopt and for BN.

@ZhiyuanDang
Copy link
Author

Thanks a lot for your detailed reply. I think it addresses my confusion.

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