class_docstr: Head of CentripetalNet: Pursuing High-quality Keypoint Pairs for Object
  Detection.
  
  CentripetalHead inherits from :class:`CornerHead`. It removes the
  embedding branch and adds guiding shift and centripetal shift branches.
  More details can be found in the `paper
  <https://arxiv.org/abs/2003.09119>`_ .
  
  Args:
      num_classes (int): Number of categories excluding the background
          category.
      in_channels (int): Number of channels in the input feature map.
      num_feat_levels (int): Levels of feature from the previous module.
          2 for HourglassNet-104 and 1 for HourglassNet-52. HourglassNet-104
          outputs the final feature and intermediate supervision feature and
          HourglassNet-52 only outputs the final feature. Defaults to 2.
      corner_emb_channels (int): Channel of embedding vector. Defaults to 1.
      train_cfg (:obj:`ConfigDict` or dict, optional): Training config.
          Useless in CornerHead, but we keep this variable for
          SingleStageDetector.
      test_cfg (:obj:`ConfigDict` or dict, optional): Testing config of
          CornerHead.
      loss_heatmap (:obj:`ConfigDict` or dict): Config of corner heatmap
          loss. Defaults to GaussianFocalLoss.
      loss_embedding (:obj:`ConfigDict` or dict): Config of corner embedding
          loss. Defaults to AssociativeEmbeddingLoss.
      loss_offset (:obj:`ConfigDict` or dict): Config of corner offset loss.
          Defaults to SmoothL1Loss.
      loss_guiding_shift (:obj:`ConfigDict` or dict): Config of
          guiding shift loss. Defaults to SmoothL1Loss.
      loss_centripetal_shift (:obj:`ConfigDict` or dict): Config of
          centripetal shift loss. Defaults to SmoothL1Loss.
     init_cfg (:obj:`ConfigDict` or dict, optional): the config to control
         the initialization.
class_docstr_tok: ["Head","of","CentripetalNet",":","Pursuing","High-quality","Keypoint","Pairs","for","Object","Detection",".","CentripetalHead","inherits","from",":","class",":","`","CornerHead","`",".","It","removes","the","embedding","branch","and","adds","guiding","shift","and","centripetal","shift","branches",".","More","details","can","be","found","in","the","`","paper","<","https",":","\/\/arxiv.org\/abs\/2003.09119",">","`","_",".","Args",":","num_classes","(","int",")",":","Number","of","categories","excluding","the","background","category",".","in_channels","(","int",")",":","Number","of","channels","in","the","input","feature","map",".","num_feat_levels","(","int",")",":","Levels","of","feature","from","the","previous","module",".","2","for","HourglassNet-104","and","1","for","HourglassNet-52",".","HourglassNet-104","outputs","the","final","feature","and","intermediate","supervision","feature","and","HourglassNet-52","only","outputs","the","final","feature",".","Defaults","to","2.","corner_emb_channels","(","int",")",":","Channel","of","embedding","vector",".","Defaults","to","1.","train_cfg","(",":","obj",":","`","ConfigDict","`","or","dict",",","optional",")",":","Training","config",".","Useless","in","CornerHead",",","but","we","keep","this","variable","for","SingleStageDetector",".","test_cfg","(",":","obj",":","`","ConfigDict","`","or","dict",",","optional",")",":","Testing","config","of","CornerHead",".","loss_heatmap","(",":","obj",":","`","ConfigDict","`","or","dict",")",":","Config","of","corner","heatmap","loss",".","Defaults","to","GaussianFocalLoss",".","loss_embedding","(",":","obj",":","`","ConfigDict","`","or","dict",")",":","Config","of","corner","embedding","loss",".","Defaults","to","AssociativeEmbeddingLoss",".","loss_offset","(",":","obj",":","`","ConfigDict","`","or","dict",")",":","Config","of","corner","offset","loss",".","Defaults","to","SmoothL1Loss",".","loss_guiding_shift","(",":","obj",":","`","ConfigDict","`","or","dict",")",":","Config","of","guiding","shift","loss",".","Defaults","to","SmoothL1Loss",".","loss_centripetal_shift","(",":","obj",":","`","ConfigDict","`","or","dict",")",":","Config","of","centripetal","shift","loss",".","Defaults","to","SmoothL1Loss",".","init_cfg","(",":","obj",":","`","ConfigDict","`","or","dict",",","optional",")",":","the","config","to","control","the","initialization","."]
code: def init_weights(self) -> None:
      super().init_weights()
      for i in range(self.num_feat_levels):
          normal_init(self.tl_feat_adaption[i], std=0.01)
          normal_init(self.br_feat_adaption[i], std=0.01)
          normal_init(self.tl_dcn_offset[i].conv, std=0.1)
          normal_init(self.br_dcn_offset[i].conv, std=0.1)
          _ = [
              x.conv.reset_parameters()
              for x in self.tl_guiding_shift[i]
          ]
          _ = [
              x.conv.reset_parameters()
              for x in self.br_guiding_shift[i]
          ]
          _ = [
              x.conv.reset_parameters()
              for x in self.tl_centripetal_shift[i]
          ]
          _ = [
              x.conv.reset_parameters()
              for x in self.br_centripetal_shift[i]
          ]
  
imports: from typing import List, Optional, Tuple
  import torch.nn
  from mmcv.cnn import ConvModule
  from mmcv.ops import DeformConv2d
  from mmengine.model import normal_init
  from torch import Tensor
  from mmdet.registry import MODELS
  from mmdet.utils import ConfigType, InstanceList, OptInstanceList, OptMultiConfig
  from ..utils import multi_apply
  from .corner_head import CornerHead
label_desc: Use image node_id 4 for calling the CentripetalHead obj's underlying member method code with example usage: obj.init_weights() without return types