IoU simple to understand

IoU full name and delivery ratio (Intersection over Union)
by this name we can probably guess the calculation method IoU.
IoU calculation is the ratio of "prediction border" and the intersection of the "real border" and the union.

Before starting the calculations, we first carried out analyzes intersection and union in the end should be how to calculate: First, we need to calculate the intersection, and then set the border area of ​​the two through the intersection and minus part is the union, therefore the difficulty of computing IoU It computes the intersection lies.

In order to calculate the intersection, the way you mind first thought should be: to consider the relative positions of two border, then follow the relative position (upper left, lower left, upper right, lower right, contain, disjoint) with different situations, to calculate the intersection.

Let's rethink computing the intersection of two boxes. In real terms the intersection of two boxes is to calculate the intersection of two sets.
Here Insert Picture Description

The logical intersection of the calculated
intersection of the lower bound z1: max (x1, y1)
bound the intersection z2: min (x2, y2)
if z2-z1, z2 -z1 is less than 0, then set A and set B disjoint .

Published 60 original articles · won praise 8 · views 3336

Guess you like

Origin blog.csdn.net/qq_43476433/article/details/103426958