deepinsight / deepinsight/insightface
The effect of pytorch checkpoint to running mean/var in Batchnorm Layer
Open
- Dominant language
- Python
- Stars
- 29.7k
- Forks
- 6.1k
- PR merge metrics
- No merged PRs in 30d
Description
Hi, I've read some discussion(https://discuss.pytorch.org/t/checkpoint-with-batchnorm-running-averages/17738) about pytorch checkpoint. The running mean/var of BN layer seems update twice when checkpoint is used in training. The way to make batch statistic updating correct is changing momentum to (1 - sqrt(1- original momentum)).
In the recognition project, It seems that the checkpoint is simply used without changing BN momentum. Will this affect the model training? Is it necessary to change momentum manually? @anxiangsir
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.