perrying/realistic-ssl-evaluation-pytorch

BN update

jizongFox opened this issue · 4 comments

Hi @perrying
Thanks for sharing this code.
I saw that you have implemented the track_bn_statistic method in your network by overriding the foward method. This seems strange and what is the propose of using such way.

I noticed that track_running_stats=False does not work in this case.

In my implementation, the model is inputted the same data twice in one iteration.
Thus, I'd like to prevent updating the running_mean and running_var with the same data.

There may be better ways to implement it, but overriding is a comprehensible way for me.

So in this implementation, you ignore totally the unlabeled data, instead of considering it once.

The unlabeled data are also used to calculate running_mean and running_var.
What do you concern?

In this particular setting, there is little difference.