docstr: Args:
      det_outs (list[Tensor]): output from detection head, each one
          is a 4-D Tensor with shape [N, C, H, W].
      targets (dict): contains 'im_id', 'gt_bbox', 'gt_ide', 'image',
          'im_shape', 'scale_factor' and 'tbox', 'tconf', 'tide' of
          each FPN level.
      anchors (list[list]): anchor setting of JDE model, N row M col, N is
          the anchor levels(FPN levels), M is the anchor scales each
          level.
docstr_tok: ["Args",":","det_outs","(","list","[","Tensor","]",")",":","output","from","detection","head",",","each","one","is","a","4-D","Tensor","with","shape","[","N",",","C",",","H",",","W","]",".","targets","(","dict",")",":","contains","'im_id","'",",","'gt_bbox","'",",","'gt_ide","'",",","'image","'",",","'im_shape","'",",","'scale_factor","'","and","'tbox","'",",","'tconf","'",",","'tide","'","of","each","FPN","level",".","anchors","(","list","[","list","]",")",":","anchor","setting","of","JDE","model",",","N","row","M","col",",","N","is","the","anchor","levels","(","FPN","levels",")",",","M","is","the","anchor","scales","each","level","."]
code: def forward(self, det_outs, targets, anchors):
      """
      Args:
          det_outs (list[Tensor]): output from detection head, each one
              is a 4-D Tensor with shape [N, C, H, W].
          targets (dict): contains 'im_id', 'gt_bbox', 'gt_ide', 'image',
              'im_shape', 'scale_factor' and 'tbox', 'tconf', 'tide' of
              each FPN level.
          anchors (list[list]): anchor setting of JDE model, N row M col, N is
              the anchor levels(FPN levels), M is the anchor scales each
              level.
      """
      assert len(det_outs) == len(anchors)
      loss_confs = []
      loss_boxes = []
      for i, (p_det, anchor) in enumerate(zip(det_outs, anchors)):
          t_conf = targets["tconf{}".format(i)]
          t_box = targets["tbox{}".format(i)]
  
          loss_conf, loss_box = self.det_loss(
              p_det, anchor, t_conf, t_box
          )
          loss_confs.append(loss_conf)
          loss_boxes.append(loss_box)
      if self.for_mot:
          return {"loss_confs": loss_confs, "loss_boxes": loss_boxes}
      else:
          jde_conf_losses = sum(loss_confs)
          jde_box_losses = sum(loss_boxes)
          jde_det_losses = {
              "loss_conf": jde_conf_losses,
              "loss_box": jde_box_losses,
              "loss": jde_conf_losses + jde_box_losses,
          }
          return jde_det_losses
  
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
label_desc: Use image node_id 3 for calling the JDEDetectionLoss obj's underlying member method code with example usage: obj.forward(det_outs, targets, anchors) and returns: dict, jde_det_losses