class_docstr: Assign a corresponding gt bbox or background to each prior.
  
  Each proposals will be assigned with `0` or a positive integer
  indicating the ground truth index.
  
  - 0: negative sample, no assigned gt
  - positive integer: positive sample, index (1-based) of assigned gt
  
  If ``alpha`` is not None, it means that the dynamic cost
  ATSSAssigner is adopted, which is currently only used in the DDOD.
  
  Args:
      topk (int): number of priors selected in each level
      alpha (float, optional): param of cost rate for each proposal only
          in DDOD. Defaults to None.
      iou_calculator (:obj:`ConfigDict` or dict): Config dict for iou
          calculator. Defaults to ``dict(type='BboxOverlaps2D')``
      ignore_iof_thr (float): IoF threshold for ignoring bboxes (if
          `gt_bboxes_ignore` is specified). Negative values mean not
          ignoring any bboxes. Defaults to -1.
code: def __init__(
      self,
      topk: int,
      alpha: Optional[float] = None,
      iou_calculator: ConfigType = dict(type="BboxOverlaps2D"),
      ignore_iof_thr: float = -1,
  ) -> None:
      self.topk = topk
      self.alpha = alpha
      self.iou_calculator = TASK_UTILS.build(iou_calculator)
      self.ignore_iof_thr = ignore_iof_thr
  
file_path: mmdetection/mmdet/models/task_modules/assigners/atss_assigner.py
imports: import warnings
  from typing import List, Optional
  import torch
  from mmengine.structures import InstanceData
  from torch import Tensor
  from mmdet.registry import TASK_UTILS
  from mmdet.utils import ConfigType
  from .assign_result import AssignResult
  from .base_assigner import BaseAssigner
label_desc: Use image node_id 1 to create a new ATSSAssigner object from inherited base classes: BaseAssigner with example: obj = ATSSAssigner(topk, alpha, iou_calculator, ignore_iof_thr)