class_docstr: FocalLossCost.
  
  Args:
      alpha (Union[float, int]): focal_loss alpha. Defaults to 0.25.
      gamma (Union[float, int]): focal_loss gamma. Defaults to 2.
      eps (float): Defaults to 1e-12.
      binary_input (bool): Whether the input is binary. Currently,
          binary_input = True is for masks input, binary_input = False
          is for label input. Defaults to False.
      weight (Union[float, int]): Cost weight. Defaults to 1.
class_docstr_tok: ["FocalLossCost",".","Args",":","alpha","(","Union","[","float",",","int","]",")",":","focal_loss","alpha",".","Defaults","to","0.25.","gamma","(","Union","[","float",",","int","]",")",":","focal_loss","gamma",".","Defaults","to","2.","eps","(","float",")",":","Defaults","to","1e-12",".","binary_input","(","bool",")",":","Whether","the","input","is","binary",".","Currently",",","binary_input","=","True","is","for","masks","input",",","binary_input","=","False","is","for","label","input",".","Defaults","to","False",".","weight","(","Union","[","float",",","int","]",")",":","Cost","weight",".","Defaults","to","1","."]
code: def __init__(
      self,
      alpha: Union[float, int] = 0.25,
      gamma: Union[float, int] = 2,
      eps: float = 1e-12,
      binary_input: bool = False,
      weight: Union[float, int] = 1.0,
  ) -> None:
      super().__init__(weight=weight)
      self.alpha = alpha
      self.gamma = gamma
      self.eps = eps
      self.binary_input = binary_input
  
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 FocalLossCost object from inherited base classes: BaseMatchCost with example: obj = FocalLossCost(alpha, gamma, eps, binary_input, weight)