# instanceSegmentationMetrics

## Description

Use the `instanceSegmentationMetrics`

object and its object
functions to evaluate the quality of instance segmentation results.

An `instanceSegmentationMetrics`

object stores instance segmentation
quality metrics for a set of images, such as the average precision (AP) and precision and
recall, computed per class and per image. To compute the AP and precision recall metrics, pass
the `instanceSegmentationMetrics`

object to the `averagePrecision`

or the `precisionRecall`

object functions, respectively. To compute the confusion matrix, pass the
`instanceSegmentationMetrics`

object to the `confusionMatrix`

object function. Evaluate the summary of all metrics across all classes and all images in the
data set using the `summarize`

object
function.

## Creation

Create an `instanceSegmentationMetrics`

object using the `evaluateInstanceSegmentation`

function.

## Properties

## Object Functions

`averagePrecision` | Evaluate average precision metric of instance segmentation results |

`confusionMatrix` | Compute confusion matrix of instance segmentation results |

`precisionRecall` | Get precision recall metrics of instance segmentation results |

`summarize` | Summarize instance segmentation performance metrics at data set and class level |

`metricsByArea` | Evaluate instance segmentation across object mask size ranges |

## Version History

**Introduced in R2022b**

## See Also

`solov2`

| `trainSOLOV2`

| `evaluateInstanceSegmentation`

| `maskrcnn`

| `trainMaskRCNN`