cuixing158_1:

Do I still need to set the track_running_stats=false of BN after inference model.eval() is executed?


No, this argument is only used during the initialization of the batchnorm layer to define, if the running statistics should be tracked or not.
Changing this attribute later should not have any effect.
You would only have to call .train() and .eval() to switch between the different behaviors.