You can call train/eval on individual (sub-) modules, e.g.
model.train()
for m in model.modules():
    if isinstance(m, torch.nn.BatchNorm2d):
      m.eval()

should do the trick.
Note that the weight and bias of batch norm will still require gradients and be trained. You have to set them to not require gradients if you want to avoid that.
Best regards
Thomas