class_docstr: OKSLoss.
  
  Computing the oks loss between a set of predicted poses and target poses.
  
  Args:
      linear (bool): If True, use linear scale of loss instead of log scale.
          Default: False.
      eps (float): Eps to avoid log(0).
      reduction (str): Options are "none", "mean" and "sum".
      loss_weight (float): Weight of loss.
class_docstr_tok: ["OKSLoss",".","Computing","the","oks","loss","between","a","set","of","predicted","poses","and","target","poses",".","Args",":","linear","(","bool",")",":","If","True",",","use","linear","scale","of","loss","instead","of","log","scale",".","Default",":","False",".","eps","(","float",")",":","Eps","to","avoid","log","(","0",")",".","reduction","(","str",")",":","Options","are","``","none","''",",","``","mean","''","and","``","sum","''",".","loss_weight","(","float",")",":","Weight","of","loss","."]
code: def __init__(
      self,
      linear=False,
      num_keypoints=17,
      eps=1e-6,
      reduction="mean",
      loss_weight=1.0,
  ):
      super(OKSLoss, self).__init__()
      self.linear = linear
      self.eps = eps
      self.reduction = reduction
      self.loss_weight = loss_weight
      if num_keypoints == 17:
          self.sigmas = (
              np.array(
                  [
                      0.26,
                      0.25,
                      0.25,
                      0.35,
                      0.35,
                      0.79,
                      0.79,
                      0.72,
                      0.72,
                      0.62,
                      0.62,
                      1.07,
                      1.07,
                      0.87,
                      0.87,
                      0.89,
                      0.89,
                  ],
                  dtype=np.float32,
              )
              / 10.0
          )
      elif num_keypoints == 14:
          self.sigmas = (
              np.array(
                  [
                      0.79,
                      0.79,
                      0.72,
                      0.72,
                      0.62,
                      0.62,
                      1.07,
                      1.07,
                      0.87,
                      0.87,
                      0.89,
                      0.89,
                      0.79,
                      0.79,
                  ]
              )
              / 10.0
          )
      else:
          raise ValueError(
              f"Unsupported keypoints number {num_keypoints}"
          )
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from itertools import cycle, islice
  from collections import abc
  import numpy
  import paddle
  import paddle.nn
  from ppdet.core.workspace import register, serializable
label_desc: Use image node_id 1 to create a new OKSLoss object from inherited base classes: nn with example: obj = OKSLoss(linear, num_keypoints, eps, reduction, loss_weight)