class_docstr: Bbox head used in Double-Head R-CNN
  
  .. code-block:: none
  
                                        /-> cls
                    /-> shared convs ->
                                        \-> reg
      roi features
                                        /-> cls
                    \-> shared fc    ->
                                        \-> reg
class_docstr_tok: ["Bbox","head","used","in","Double-Head","R-CNN","..","code-block",":",":","none","\/-",">","cls","\/-",">","shared","convs","-",">","\\-",">","reg","roi","features","\/-",">","cls","\\-",">","shared","fc","-",">","\\-",">","reg"]
code: def __init__(
      self,
      num_convs: int = 0,
      num_fcs: int = 0,
      conv_out_channels: int = 1024,
      fc_out_channels: int = 1024,
      conv_cfg: OptConfigType = None,
      norm_cfg: ConfigType = dict(type="BN"),
      init_cfg: MultiConfig = dict(
          type="Normal",
          override=[
              dict(type="Normal", name="fc_cls", std=0.01),
              dict(type="Normal", name="fc_reg", std=0.001),
              dict(
                  type="Xavier",
                  name="fc_branch",
                  distribution="uniform",
              ),
          ],
      ),
      **kwargs,
  ) -> None:
      kwargs.setdefault("with_avg_pool", True)
      super().__init__(init_cfg=init_cfg, **kwargs)
      assert self.with_avg_pool
      assert num_convs > 0
      assert num_fcs > 0
      self.num_convs = num_convs
      self.num_fcs = num_fcs
      self.conv_out_channels = conv_out_channels
      self.fc_out_channels = fc_out_channels
      self.conv_cfg = conv_cfg
      self.norm_cfg = norm_cfg
  
      # increase the channel of input features
      self.res_block = BasicResBlock(
          self.in_channels, self.conv_out_channels
      )
  
      # add conv heads
      self.conv_branch = self._add_conv_branch()
      # add fc heads
      self.fc_branch = self._add_fc_branch()
  
      out_dim_reg = (
          4 if self.reg_class_agnostic else 4 * self.num_classes
      )
      self.fc_reg = nn.Linear(self.conv_out_channels, out_dim_reg)
  
      self.fc_cls = nn.Linear(
          self.fc_out_channels, self.num_classes + 1
      )
      self.relu = nn.ReLU()
  
file_path: mmdetection/mmdet/models/roi_heads/bbox_heads/double_bbox_head.py
imports: from typing import Tuple
  import torch.nn
  from mmcv.cnn import ConvModule
  from mmengine.model import BaseModule, ModuleList
  from torch import Tensor
  from mmdet.models.backbones.resnet import Bottleneck
  from mmdet.registry import MODELS
  from mmdet.utils import ConfigType, MultiConfig, OptConfigType, OptMultiConfig
  from .bbox_head import BBoxHead
label_desc: Use image node_id 1 to create a new DoubleConvFCBBoxHead object from inherited base classes: BBoxHead with example: obj = DoubleConvFCBBoxHead(num_convs, num_fcs, conv_out_channels, fc_out_channels, conv_cfg, norm_cfg, init_cfg)