docstr: Args:
      num_classes (int): The number of classes.
      matcher (HungarianMatcher): It computes an assignment between the targets
          and the predictions of the network.
      loss_coeff (dict): The coefficient of loss.
      aux_loss (bool): If 'aux_loss = True', loss at each decoder layer are to be used.
      use_focal_loss (bool): Use focal loss or not.
docstr_tok: ["Args",":","num_classes","(","int",")",":","The","number","of","classes",".","matcher","(","HungarianMatcher",")",":","It","computes","an","assignment","between","the","targets","and","the","predictions","of","the","network",".","loss_coeff","(","dict",")",":","The","coefficient","of","loss",".","aux_loss","(","bool",")",":","If","'aux_loss","=","True","'",",","loss","at","each","decoder","layer","are","to","be","used",".","use_focal_loss","(","bool",")",":","Use","focal","loss","or","not","."]
code: def __init__(
      self,
      num_classes=80,
      matcher="HungarianMatcher",
      loss_coeff={
          "class": 1,
          "bbox": 5,
          "giou": 2,
          "no_object": 0.1,
          "mask": 1,
          "dice": 1,
      },
      aux_loss=True,
      use_focal_loss=False,
      use_vfl=False,
      use_uni_match=False,
      uni_match_ind=0,
  ):
      r"""
      Args:
          num_classes (int): The number of classes.
          matcher (HungarianMatcher): It computes an assignment between the targets
              and the predictions of the network.
          loss_coeff (dict): The coefficient of loss.
          aux_loss (bool): If 'aux_loss = True', loss at each decoder layer are to be used.
          use_focal_loss (bool): Use focal loss or not.
      """
      super(DETRLoss, self).__init__()
  
      self.num_classes = num_classes
      self.matcher = matcher
      self.loss_coeff = loss_coeff
      self.aux_loss = aux_loss
      self.use_focal_loss = use_focal_loss
      self.use_vfl = use_vfl
      self.use_uni_match = use_uni_match
      self.uni_match_ind = uni_match_ind
  
      if not self.use_focal_loss:
          self.loss_coeff["class"] = paddle.full(
              [num_classes + 1], loss_coeff["class"]
          )
          self.loss_coeff["class"][-1] = loss_coeff["no_object"]
      self.giou_loss = GIoULoss()
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import paddle
  import paddle.nn
  import paddle.nn.functional
  from ppdet.core.workspace import register
  from .iou_loss import GIoULoss
  from ..transformers import bbox_cxcywh_to_xyxy, sigmoid_focal_loss, varifocal_loss_with_logits
  from ..bbox_utils import bbox_iou
label_desc: Use image node_id 1 to create a new DETRLoss object from inherited base classes: nn with example: obj = DETRLoss(num_classes, matcher, loss_coeff, aux_loss, use_focal_loss, use_vfl, use_uni_match, uni_match_ind)