class_docstr: Base class for segmentors.
class_docstr_tok: ["Base","class","for","segmentors","."]
docstr: Initialize the weights in segmentor.
  
  Args:
      pretrained (str, optional): Path to pre-trained weights.
          Defaults to None.
docstr_tok: ["Initialize","the","weights","in","segmentor",".","Args",":","pretrained","(","str",",","optional",")",":","Path","to","pre-trained","weights",".","Defaults","to","None","."]
code: def init_weights(self, pretrained=None):
      """Initialize the weights in segmentor.
  
      Args:
          pretrained (str, optional): Path to pre-trained weights.
              Defaults to None.
      """
      if pretrained is not None:
          logger = logging.getLogger()
          logger.info(f"load model from: {pretrained}")
  
imports: import logging
  import warnings
  from abc import ABCMeta, abstractmethod
  from collections import OrderedDict
  import annotator.uniformer.mmcv
  import numpy
  import torch
  import torch.distributed
  import torch.nn
  from annotator.uniformer.mmcv.runner import auto_fp16
label_desc: Use image node_id 10 for calling the BaseSegmentor obj's underlying member method code with example usage: obj.init_weights(pretrained) without return types