class_docstr: This class implements the RecMetricComputation for AUPRC, i.e. Area Under the Curve.
  
  The constructor arguments are defined in RecMetricComputation.
  See the docstring of RecMetricComputation for more detail.
  Args:
      grouped_auprc (bool): If True, computes AUPRC per group and returns average AUPRC across all groups.
          The `grouping_keys` is provided during state updates along with predictions, labels, weights.
          This feature is currently not enabled for `fused_update_limit`.
code: def _compute(self) -> List[MetricComputationReport]:
      reports = [
          MetricComputationReport(
              name=MetricName.AUPRC,
              metric_prefix=MetricPrefix.WINDOW,
              value=compute_auprc(
                  self._n_tasks,
                  cast(torch.Tensor, getattr(self, PREDICTIONS)[0]),
                  cast(torch.Tensor, getattr(self, LABELS)[0]),
                  cast(torch.Tensor, getattr(self, WEIGHTS)[0]),
              ),
          )
      ]
      if self._grouped_auprc:
          reports.append(
              MetricComputationReport(
                  name=MetricName.GROUPED_AUPRC,
                  metric_prefix=MetricPrefix.WINDOW,
                  value=compute_auprc_per_group(
                      self._n_tasks,
                      cast(torch.Tensor, getattr(self, PREDICTIONS)[0]),
                      cast(torch.Tensor, getattr(self, LABELS)[0]),
                      cast(torch.Tensor, getattr(self, WEIGHTS)[0]),
                      cast(
                          torch.Tensor, getattr(self, GROUPING_KEYS)[0]
                      ),
                  ),
              )
          )
      return reports
  
imports: from functools import partial
  from typing import Any, cast, Dict, List, Optional, Type
  import torch
  import torch.distributed
  import torch.nn.functional
  from torchrec.metrics.metrics_config import RecComputeMode, RecTaskInfo
  from torchrec.metrics.metrics_namespace import MetricName, MetricNamespace, MetricPrefix
  from torchrec.metrics.rec_metric import MetricComputationReport, RecMetric, RecMetricComputation, RecMetricException
label_desc: Use image node_id 4 for calling the AUPRCMetricComputation obj's underlying member method code with example usage: obj._compute() and returns: reports