code: def test_torch_PrecisionRecallCurve():
      from bigdl.orca.learn.pytorch.pytorch_metrics import (
          PrecisionRecallCurve,
      )
  
      target = torch.tensor([0, 1, 1, 0, 1, 1])
      preds = torch.tensor([0, 0.2, 1.0, 0.8, 0.6, 0.5])
      curve = PrecisionRecallCurve()
      curve(preds, target)
      print(curve.compute())
      precision, recall, thresholds = curve.compute()
      assert precision[0] - 0.8 < 10e-6
      assert recall[0] - 1.0 < 10e-6
      assert thresholds[0] - 0.2 < 10e-6
  
file_path: BigDL/python/orca/test/bigdl/orca/learn/test_metrics.py
imports: import torch
  import pytest
label_desc: Use image node_id 18 for calling a global function with example usage: test_torch_PrecisionRecallCurve() without return types