class_docstr: Base match cost class.
  
  Args:
      weight (Union[float, int]): Cost weight. Defaults to 1.
class_docstr_tok: ["Base","match","cost","class",".","Args",":","weight","(","Union","[","float",",","int","]",")",":","Cost","weight",".","Defaults","to","1","."]
code: def __init__(self, weight: Union[float, int] = 1.0) -> None:
      self.weight = weight
  
imports: from abc import abstractmethod
  from typing import Optional, Union
  import torch
  import torch.nn.functional
  from mmengine.structures import InstanceData
  from torch import Tensor
  from mmdet.registry import TASK_UTILS
  from mmdet.structures.bbox import bbox_overlaps, bbox_xyxy_to_cxcywh
label_desc: Use image node_id 1 to create a new BaseMatchCost object  with example: obj = BaseMatchCost(weight)