class_docstr: The class for implementing FCENet head.
  
  FCENet(CVPR2021): `Fourier Contour Embedding for Arbitrary-shaped Text
  Detection <https://arxiv.org/abs/2104.10442>`_
  
  Args:
      in_channels (int): The number of input channels.
      fourier_degree (int) : The maximum Fourier transform degree k. Defaults
          to 5.
      module_loss (dict): Config of loss for FCENet. Defaults to
          ``dict(type='FCEModuleLoss', num_sample=50)``.
      postprocessor (dict): Config of postprocessor for FCENet.
      init_cfg (dict, optional): Initialization configs.
docstr: Args:
      inputs (List[Tensor]): Each tensor has the shape of :math:`(N, C_i,
          H_i, W_i)`.
      data_samples (list[TextDetDataSample], optional): A list of data
          samples. Defaults to None.
  
  Returns:
      list[dict]: A list of dict with keys of ``cls_res``, ``reg_res``
      corresponds to the classification result and regression result
      computed from the input tensor with the same index. They have
      the shapes of :math:`(N, C_{cls,i}, H_i, W_i)` and :math:`(N,
      C_{out,i}, H_i, W_i)`.
code: def forward(
      self,
      inputs: List[torch.Tensor],
      data_samples: Optional[List[TextDetDataSample]] = None,
  ) -> Dict:
      """
      Args:
          inputs (List[Tensor]): Each tensor has the shape of :math:`(N, C_i,
              H_i, W_i)`.
          data_samples (list[TextDetDataSample], optional): A list of data
              samples. Defaults to None.
  
      Returns:
          list[dict]: A list of dict with keys of ``cls_res``, ``reg_res``
          corresponds to the classification result and regression result
          computed from the input tensor with the same index. They have
          the shapes of :math:`(N, C_{cls,i}, H_i, W_i)` and :math:`(N,
          C_{out,i}, H_i, W_i)`.
      """
      cls_res, reg_res = multi_apply(self.forward_single, inputs)
      level_num = len(cls_res)
      preds = [
          dict(cls_res=cls_res[i], reg_res=reg_res[i])
          for i in range(level_num)
      ]
      return preds
  
file_path: mmocr/mmocr/models/textdet/heads/fce_head.py
imports: from typing import Dict, List, Optional
  import torch
  import torch.nn
  from mmdet.models.utils import multi_apply
  from mmocr.models.textdet.heads import BaseTextDetHead
  from mmocr.registry import MODELS
  from mmocr.structures import TextDetDataSample
label_desc: Use image node_id 2 for calling the FCEHead obj's underlying member method code with example usage: obj.forward(inputs, data_samples) and returns: preds