class_docstr: Base class for text encoder
class_docstr_tok: ["Base","class","for","text","encoder"]
code: def freeze_norm_layers(self) -> None:
      for m in self.modules():
          if isinstance(m, norm_layers_tuple):
              m.eval()
              m.weight.requires_grad = False
              m.bias.requires_grad = False
              m.training = False
  
file_path: ml-cvnets/cvnets/text_encoders/base_text_encoder.py
imports: import argparse
  from typing import Any, Dict, Optional
  import torch
  from torch import Tensor, nn
  from cvnets import parameter_list
  from cvnets.layers import norm_layers_tuple
  from cvnets.misc.init_utils import initialize_weights
  from utils import logger
  from utils.ddp_utils import is_master
label_desc: Use image node_id 5 for calling the BaseTextEncoder obj's underlying member method code with example usage: obj.freeze_norm_layers() without return types