How to use Batch normalization in testing model

the parameter affine in nn.BatchNorm2d() is true when I train the model
and I need to set affine is False when I test the model

Do I get the right understand?

1 Like