tfma.metrics.COCOAveragePrecision

Confusion matrix at thresholds.

Inherits From: Metric

It computes the average precision of object detections for a single class and a single iou_threshold.

num_thresholds (Optional) Number of thresholds to use for calculating the matrices and finding the precision at given recall.
iou_threshold (Optional) Used for object detection, threholds for a detection and ground truth pair with specific iou to be considered as a match.
object_class_id (Optional) Used for object detection, the class id for calculating metrics. It must be provided if use_object_detection is True.
object_class_weight (Optional) Used for object detection, the weight associated with the object class id.
area_range (Optional) Used for object detection, the area-range for objects to be considered for metrics.
max_num_detections (Optional) Used for object detection, the maximum number of detections for a single image.
recalls (Optional) recalls at which precisions will be calculated.
num_recalls (Optional) Used for objecth detection, the number of recalls for calculating average precision, it equally generates points bewteen 0 and 1. (Only one of recalls and num_recalls should be used).
name (Optional) string name of the metric instance.

compute_confidence_interval Whether to compute confidence intervals for this metric.

Note that this may not completely remove the computational overhead involved in computing a given metric. This is only respected by the jackknife confidence interval method.

Methods

computations

View source

Creates computations associated with metric.

get_config

View source

Returns serializable config.