- If set to an `int` (larger than 1), will use that number of thresholds linearly spaced from 0 to 1 as bins for the calculation. - If set to an `list` of floats, will use the indicated thresholds in the list as bins for the calculation - If set to an 1d `tensor` of floats, will use the indicated thresholds in the tensor as bins for the calculation. validate_args: bool indicating if input arguments and tensors should be validated for correctness. Set to ``False`` for faster computations. Example: >>> from torchmetrics.classification import MultilabelPrecisionRecallCurve >>> preds = torch.tensor([[0.75, 0.05, 0.35], ... [0.45, 0.75, 0.05], ... [0.05, 0.55, 0.75], ... [0.05, 0.65, 0.05]]) >>> target = torch.tensor([[1, 0, 1], ... [0, 0, 0], ... [0, 1, 1], ... [1, 1, 1]]) >>> mlprc = MultilabelPrecisionRecallCurve(num_labels=3, thresholds=None) >>> precision, recall, thresholds = mlprc(preds, target) >>> precision # doctest: +NORMALIZE_WHITESPACE [tensor([0.5000, 0.5000, 1.0000, 1.0000]), tensor([0.5000, 0.6667, 0.5000, 0.0000, 1.0000]), tensor([0.7500, 1.0000, 1.0000, 1.0000])] >>> recall # doctest: +NORMALIZE_WHITESPACE [tensor([1.0000, 0.5000, 0.5000, 0.0000]), tensor([1.0000, 1.0000, 0.5000, 0.0000, 0.0000]), tensor([1.0000, 0.6667, 0.3333, 0.0000])] >>> thresholds # doctest: +NORMALIZE_WHITESPACE [tensor([0.0500, 0.4500, 0.7500]), tensor([0.0500, 0.5500, 0.6500, 0.7500]), tensor([0.0500, 0.3500, 0.7500])] >>> mlprc = MultilabelPrecisionRecallCurve(num_labels=3, thresholds=5) >>> mlprc(preds, target) # doctest: +NORMALIZE_WHITESPACE (tensor([[0.5000, 0.5000, 1.0000, 1.0000, 0.0000, 1.0000], [0.5000, 0.6667, 0.6667, 0.0000, 0.0000, 1.0000], [0.7500, 1.0000, 1.0000, 1.0000, 0.0000, 1.0000]]), tensor([[1.0000, 0.5000, 0.5000, 0.5000, 0.0000, 0.0000], [1.0000, 1.0000, 1.0000, 0.0000, 0.0000, 0.0000], [1.0000, 0.6667, 0.3333, 0.3333, 0.0000, 0.0000]]), tensor([0.0000, 0.2500, 0.5000, 0.7500, 1.0000])) Fr'