Skip to content

What is the best way to extract recall and precision for a specific Intersection-over-Union threshold? #2152

Answered by tcotte
bw4sz asked this question in CompVision
Discussion options

You must be logged in to vote

Hello, I am not sure to understand well your first question but I can answer to the second one.
It exists a boolean attribute extended_summary (default=False) of the class MeanAveragePrecision which enables to return precision and recall when compute() is call.

metric = MeanAveragePrecision(iou_type="bbox", extended_summary=True)`

validation_metrics = metric.compute()

precision = validation_metrics['precision']

recall= validation_metrics['recall']

As you can read in the documentation:

  • precision: a tensor of shape (TxRxKxAxM) containing the precision values. Here T is the
    number of IoU thresholds, R is the number of recall thresholds, K is the number of classes,
    A is the number of areas and

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by bw4sz
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants