class_docstr: ResNet with the softmax chopped off and the batchnorm frozen
class_docstr_tok: ["ResNet","with","the","softmax","chopped","off","and","the","batchnorm","frozen"]
docstr: Override the default train() to freeze the BN parameters
docstr_tok: ["Override","the","default","train","(",")","to","freeze","the","BN","parameters"]
code: def train(self, mode=True):
      """
      Override the default train() to freeze the BN parameters
      """
      super().train(mode)
      self.freeze_bn()
  
imports: import torch
  import torch.nn
  import torch.nn.functional
  import torchvision.models
label_desc: Use image node_id 3 for calling the ResNet obj's underlying member method code with example usage: obj.train(mode) without return types