class_docstr: A classification head for use in FCOS.
  
  Args:
      in_channels (int): number of channels of the input feature.
      num_anchors (int): number of anchors to be predicted.
      num_classes (int): number of classes to be predicted.
      num_convs (Optional[int]): number of conv layer. Default: 4.
      prior_probability (Optional[float]): probability of prior. Default: 0.01.
      norm_layer: Module specifying the normalization layer to use.
code: def forward(self, x: List[Tensor]) -> Tensor:
      all_cls_logits = []
  
      for features in x:
          cls_logits = self.conv(features)
          cls_logits = self.cls_logits(cls_logits)
  
          # Permute classification output from (N, A * K, H, W) to (N, HWA, K).
          N, _, H, W = cls_logits.shape
          cls_logits = cls_logits.view(N, -1, self.num_classes, H, W)
          cls_logits = cls_logits.permute(0, 3, 4, 1, 2)
          cls_logits = cls_logits.reshape(
              N, -1, self.num_classes
          )  # Size=(N, HWA, 4)
  
          all_cls_logits.append(cls_logits)
  
      return torch.cat(all_cls_logits, dim=1)
  
imports: import math
  import warnings
  from collections import OrderedDict
  from functools import partial
  from typing import Any, Callable, Dict, List, Optional, Tuple
  import torch
  from torch import nn, Tensor
  from ...ops import boxes, generalized_box_iou_loss, misc, sigmoid_focal_loss
  from ...ops.feature_pyramid_network import LastLevelP6P7
  from ...transforms._presets import ObjectDetection
  from ...utils import _log_api_usage_once
  from .._api import register_model, Weights, WeightsEnum
  from .._meta import _COCO_CATEGORIES
  from .._utils import _ovewrite_value_param, handle_legacy_interface
  from ..resnet import resnet50, ResNet50_Weights
  from .None import _utils
  from .anchor_utils import AnchorGenerator
  from .backbone_utils import _resnet_fpn_extractor, _validate_trainable_layers
  from .transform import GeneralizedRCNNTransform
label_desc: Use image node_id 2 for calling the FCOSClassificationHead obj's underlying member method code with example usage: obj.forward(x) and returns: torch