class_docstr: Assign a corresponding gt bbox or background to each bbox.
  
  Each proposals will be assigned with `-1`, `0`, or a positive integer
  indicating the ground truth index.
  
  - -1: don't care
  - 0: negative sample, no assigned gt
  - positive integer: positive sample, index (1-based) of assigned gt
  
  Args:
      center_ratio (float): ratio of the region in the center of the bbox to
          define positive sample.
      ignore_ratio (float): ratio of the region to define ignore samples.
class_docstr_tok: ["Assign","a","corresponding","gt","bbox","or","background","to","each","bbox",".","Each","proposals","will","be","assigned","with","`","-1","`",",","`","0","`",",","or","a","positive","integer","indicating","the","ground","truth","index",".","-","-1",":","do","n't","care","-","0",":","negative","sample",",","no","assigned","gt","-","positive","integer",":","positive","sample",",","index","(","1-based",")","of","assigned","gt","Args",":","center_ratio","(","float",")",":","ratio","of","the","region","in","the","center","of","the","bbox","to","define","positive","sample",".","ignore_ratio","(","float",")",":","ratio","of","the","region","to","define","ignore","samples","."]
code: def __init__(
      self, center_ratio: float = 0.2, ignore_ratio: float = 0.5
  ) -> None:
      self.center_ratio = center_ratio
      self.ignore_ratio = ignore_ratio
  
file_path: mmdetection/mmdet/models/task_modules/assigners/region_assigner.py
imports: from typing import List, Optional, Tuple
  import torch
  from mmengine.structures import InstanceData
  from torch import Tensor
  from mmdet.registry import TASK_UTILS
  from ..prior_generators import anchor_inside_flags
  from .assign_result import AssignResult
  from .base_assigner import BaseAssigner
label_desc: Use image node_id 1 to create a new RegionAssigner object from inherited base classes: BaseAssigner with example: obj = RegionAssigner(center_ratio, ignore_ratio)