code: def __init__(
      self,
      in_channel=256,
      num_convs=4,
      conv_dim=256,
      out_channel=1024,
      resolution=7,
      norm_type="gn",
      freeze_norm=False,
      stage_name="",
  ):
      super(XConvNormHead, self).__init__()
      self.in_channel = in_channel
      self.num_convs = num_convs
      self.conv_dim = conv_dim
      self.out_channel = out_channel
      self.norm_type = norm_type
      self.freeze_norm = freeze_norm
  
      self.bbox_head_convs = []
      fan = conv_dim * 3 * 3
      initializer = KaimingNormal(fan_in=fan)
      for i in range(self.num_convs):
          in_c = in_channel if i == 0 else conv_dim
          head_conv_name = stage_name + "bbox_head_conv{}".format(i)
          head_conv = self.add_sublayer(
              head_conv_name,
              ConvNormLayer(
                  ch_in=in_c,
                  ch_out=conv_dim,
                  filter_size=3,
                  stride=1,
                  norm_type=self.norm_type,
                  freeze_norm=self.freeze_norm,
                  initializer=initializer,
              ),
          )
          self.bbox_head_convs.append(head_conv)
  
      fan = conv_dim * resolution * resolution
      self.fc6 = nn.Linear(
          conv_dim * resolution * resolution,
          out_channel,
          weight_attr=paddle.ParamAttr(
              initializer=XavierUniform(fan_out=fan)
          ),
          bias_attr=paddle.ParamAttr(
              learning_rate=2.0, regularizer=L2Decay(0.0)
          ),
      )
  
imports: import numpy
  import paddle
  import paddle.nn
  import paddle.nn.functional
  from paddle.nn.initializer import Normal, XavierUniform, KaimingNormal
  from paddle.regularizer import L2Decay
  from ppdet.core.workspace import register, create
  from .roi_extractor import RoIAlign
  from ..shape_spec import ShapeSpec
  from ..bbox_utils import bbox2delta
  from ..cls_utils import _get_class_default_kwargs
  from ppdet.modeling.layers import ConvNormLayer
label_desc: Use image node_id 1 to create a new XConvNormHead object from inherited base classes: nn with example: obj = XConvNormHead(in_channel, num_convs, conv_dim, out_channel, resolution, norm_type, freeze_norm, stage_name)