A post-processing and diagonal evaluation method for road damage target detection

Through the post-processing method of road damage target detection, including merging overlapping bounding boxes and suppressed small boxes, combined with the diagonal evaluation standard, the problem of inaccurate overlapping detection and evaluation indicators in road damage detection is solved, and a more accurate detection effect is achieved. .

CN113989614BActive Publication Date: 2024-10-15NANJING UNIV OF AERONAUTICS & ASTRONAUTICS
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202111218293.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-10-19
Publication Date
2024-10-15
Estimated Expiration
2041-10-19

AI Technical Summary

Technical Problem

There are a large number of overlapping bounding boxes in road damage detection, which cannot be effectively suppressed by the existing non-maximum suppression (NMS) post-processing method, and the IOU-based evaluation index cannot accurately reflect the detection effect of the model, especially because the local characteristics of road damage are different from Global features are highly similar, resulting in redundant and inaccurate detection results.

Method used

A post-processing and diagonal evaluation method for road damage target detection is adopted, including merging the same type of bounding boxes, suppressing highly overlapping bounding boxes, suppressing small boxes covered by large frames, and judging by the diagonal evaluation criteria The accuracy of the detection frame is calculated by calculating the ratio of the length of the diagonal of the detection frame covered by the intersection frame to the length of its own diagonal to evaluate the accuracy of the detection frame.

Benefits of technology

It effectively removes overlapping bounding boxes in road damage detection, provides a more accurate evaluation standard, can better evaluate the effects of different target detection models, and improves the accuracy and recall rate of detection results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113989614B_ABST
    Figure CN113989614B_ABST
Patent Text Reader

Abstract

The present invention provides a post-processing and diagonal evaluation method for road damage target detection, which belongs to the field of computer vision and effectively removes a large number of overlapping bounding boxes generated by road damage target detection. At the same time, by observing the characteristics of road damage targets, the effects of different target detection models can be more accurately evaluated. The present invention proposes a three-step post-processing method, including the following steps: merging overlapping boxes of the same type, suppressing highly overlapping boxes, and suppressing small boxes covered by large boxes. This process can effectively remove a large number of overlapping bounding boxes generated by road damage target detection. At the same time, by observing the characteristics of road damage targets, a diagonal-based evaluation standard is proposed to more accurately evaluate the effects of different target detection models.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of computer vision, and in particular relates to a post-processing and diagonal evaluation method for road damage target detection. Background Art

[0002] Object detection is one of the most popular topics in the field of computer vision. Its purpose is to find objects of predefined categories within the image and determine their location. The most commonly used post-processing method in object detection is non-maximum suppression (NMS) (Neubeck and Van Gool, 2006). NMS searches for maxima in local areas and then suppresses those non-maximum objects. For object detection, repeated detection of the same object may occur locally. The role of NMS is to retain the one with the highest confidence from these detection bounding boxes. In terms of object detection evaluation indicators, the most commonly used criterion for defining "correct detection" and "incorrect detection" is IOU. IOU calculates the ratio of the intersection area between the predicted bounding box and the true bounding box to their union area.

[0003] Applying target detection technology to road damage detection is convenient and economical. However, road damage detection is different from general target detection (such as face detection and pedestrian detection). The local features of general targets are only used to provide features for the target. For example, the local features of a face include facial features and contours, but face detection cannot be formed by these local features alone. However, the local features of road damage are highly similar to the global features. For example, the length of a crack can be very short or very long, so it can be considered that the global features and local features of the same road damage target are only different in scale. Therefore, the road damage target detection model will have many overlapping detection results. However, the non-maximum suppression (NMS) post-processing method mentioned above cannot effectively suppress these overlapping detections. At the same time, it is difficult to define and divide the manual annotation of road damage targets in a standard way, so the evaluation index based on IOU cannot accurately reflect the detection effect of the model. Summary of the invention

[0004] The present invention provides a post-processing and diagonal evaluation method for road damage target detection, which effectively removes a large number of overlapping boundary boxes generated by road damage target detection. At the same time, by observing the characteristics of road damage targets, a diagonal-based evaluation standard is proposed, which can more accurately evaluate the effects of different target detection models.

[0005] To achieve the above objectives, the present invention adopts the following technical solutions:

[0006] A post-processing and diagonal evaluation method for road damage target detection includes the following steps:

[0007] Step 1: Merge bounding boxes of the same type: Selectively merge bounding boxes of the same type with partially redundant detections;

[0008] Step 2: Suppress highly overlapping bounding boxes: The road damage situation is relatively complex. The damaged road surface in the same area may be detected as different damage types, so there may be multiple highly overlapping detection boxes. In this step, the highly overlapping bounding boxes are suppressed, and only the detection boxes with higher confidence or the detection boxes with the same confidence but larger area are retained;

[0009] Step 3: Suppress small boxes covered by large boxes: After the first two steps, some overlapping bounding boxes can be effectively removed, but there will still be a large detection box that may overlap with many small detection boxes. Select to suppress the detection box with a smaller area. If most of the area of ​​a small box is already included in the larger detection box, remove the small box. From an application perspective, road repair should give priority to larger area damage;

[0010] Step 4: Evaluation criteria based on diagonals: First, find the intersection frame of all detection frames and true annotation frames, match the detection frame with the intersection frame, calculate how much of the diagonal of the detection frame is covered by the intersection frame, and use the ratio of the matching length of the diagonal divided by the length of the diagonal of the detection frame to determine whether the detection frame is correct.

[0011] In the above steps, the merging condition in step 1 is that the IOU of the bounding box is greater than 0.25, and the merging method is to replace the bounding box with the minimum circumscribed rectangle of the bounding box;

[0012] The IOU threshold for determining whether two bounding boxes are highly overlapped in step 2 is set to 0.5;

[0013] In step 4, calculating how much of the diagonal of the detection frame is covered by the intersection frame specifically includes the following steps: the diagonal is expressed as a line segment, and the four sides of the intersection frame can also be expressed as four line segments. By calculating the intersection points of the diagonal line segments and the intersection frame side segments, how much of the diagonal of the detection frame is covered by the intersection frame is calculated. The calculation process is as follows:

[0014] The diagonal line segment of the detection box is represented by two-point coordinates (x0, y0) and (x1, y1). (x0, y0) and (x1, y1) are the two endpoint coordinates of the diagonal line segment of the detection box output by the model.

[0015] Use the line segment coordinates to find the intersection point with the two intersecting side line segments of the intersection box. The side line segment representation method is the same as the diagonal line segment. The calculation steps are as follows:

[0016] In plane analytic geometry, the equation of a line has many forms. The equation of a line used in this method is the general form:

[0017] ax+by+c=0,

[0018] Knowing the coordinates of the two endpoints of the line segment, we can find a, b, and c in the general straight line equation;

[0019] a=y1-y0,

[0020] b=-(x1-x0),

[0021] c=-a×x0-b×y0

[0022] Using the parameters a, b, c of the general equation of the straight line, we can respectively find a1, b1, c1 of the diagonal line segment and a2, b2, c2 of the edge line segment of the intersection box. Then we can calculate the horizontal coordinate x and vertical coordinate y of the intersection point of the diagonal line segment and the edge line segment of the intersection box. The calculation formula is:

[0023]

[0024]

[0025] Since a diagonal line and a rectangular frame have only two intersection lines, that is, two intersection points, the distance between the two intersection points can be calculated through Euclidean distance, that is, the matching length of the diagonal line covered by the intersection box;

[0026] Since a detection box may correspond to multiple real annotation boxes of the same type, traverse each intersection box, repeat the above two steps, and iteratively sum the matching lengths;

[0027] The criterion for judging whether the detection frame is correct is that the ratio of the matching length of the diagonal divided by the length of the diagonal of the detection frame is greater than or equal to 0.5.

[0028] Beneficial effects: The present invention provides a post-processing and diagonal evaluation method for road damage target detection, and proposes a three-step post-processing method: merging overlapping frames of the same type, suppressing highly overlapping frames, and suppressing small frames covered by large frames. This process can effectively remove a large number of overlapping boundary boxes generated by road damage target detection; at the same time, by observing the characteristics of road damage targets, a diagonal-based evaluation standard is proposed, which can more accurately evaluate the effects of different target detection models. BRIEF DESCRIPTION OF THE DRAWINGS

[0029] Figure 1 A schematic diagram of merging bounding boxes of the same type in an embodiment of the present invention;

[0030] Figure 2 A schematic diagram of suppressing highly overlapping frames in an embodiment of the present invention;

[0031] Figure 3A schematic diagram of suppressing a small frame from being covered by a large frame in an embodiment of the present invention;

[0032] Figure 4 is a schematic diagram of an evaluation criterion based on a diagonal line in an embodiment of the present invention;

[0033] Figure 5 Schematic diagram of the detection results in the embodiment of the present invention. DETAILED DESCRIPTION

[0034] The present invention is described in detail below with reference to the accompanying drawings and specific embodiments:

[0035] A post-processing and diagonal evaluation method for road damage target detection includes the following steps:

[0036] Step 1: Merge bounding boxes of the same type: For two detection bounding boxes of the same type, if the IOU of the two detection boxes is greater than 0.25, they are merged by replacing the bounding box with its minimum enclosing rectangle. The results are shown in Figure 1. Figure 1 As shown in the figure, if traditional NMS post-processing is used, then as shown on the far left, all three bounding boxes will be retained, resulting in redundant results and inaccurate final evaluation indicators. After merging bounding boxes of the same type, the result is shown on the far right, which is almost the same as the bounding boxes we manually annotated;

[0037] Step 2: Suppress highly overlapping bounding boxes: In step 1, we merged the same type of detection boxes with partially redundant detections. However, in actual applications, we found that road damage is more complicated. The damaged road surface in the same area may be detected as different damage types, so there may be multiple highly overlapping detection boxes. In this step, we suppress highly overlapping bounding boxes and only retain detection boxes with higher confidence or detection boxes with the same confidence but larger area. Here, the IOU threshold for judging whether two bounding boxes are highly overlapping is set to 0.5; Figure 2 As shown in the figure above, NMS cannot handle different types of detections, which also leads to redundant and conflicting detections. We use our method of suppressing highly overlapping bounding boxes without caring about the category, such as Figure 2 As shown in the figure below, redundant detection boxes are effectively removed. The threshold here is consistent with the common threshold of NMS, which is IOU = 0.5;

[0038] Step 3: Suppress small boxes covered by large boxes: After the first two steps, some overlapping bounding boxes can be effectively removed, but there will still be a large detection box that may overlap with many small detection boxes. Select to suppress the detection box with a smaller area, that is, if most of the area of ​​a small box is already included in the larger detection box, remove the small box. From the application point of view, road repair should give priority to larger area damage; e.g. Figure 3 As shown, NMS is strictly based on IOU judgment, so Figure 3 The bounding boxes 1, 2, 3, and 4 in the image are all retained, resulting in redundant detection and inaccurate results. In the last step of the post-processing of the present invention, there are some small detection boxes that have not been processed. These small boxes are selectively suppressed according to the proportion of their area occupied by the large box. The threshold here is set to 0.75.

[0039] Step 4: Evaluation criteria based on diagonal lines: First, find the intersection box of all detection boxes and true annotation boxes, and use the intersection box to match the detection box; calculate how much of the diagonal of the detection box is covered by the intersection box. The calculation process is as follows:

[0040] The diagonal line segment of the detection box is represented by two-point coordinates (x0, y0) and (x1, y1). (x0, y0) and (x1, y1) are the two endpoint coordinates of the diagonal line segment of the detection box output by the model.

[0041] Use the line segment coordinates to find the intersection point with the two intersecting side segments of the intersection box. The side segment representation method is the same as the diagonal line segment. The calculation steps are as follows

[0042] In plane analytic geometry, the equation of a line has many forms. The equation of a line used in this method is the general form: ax+by+c=0.

[0043] Knowing the coordinates of the two endpoints of the line segment, we can find a, b, and c in the general straight line equation;

[0044] a=y1-y0,

[0045] b=-(x1-x0),

[0046] c=-a×x0-b×y0

[0047] Using the parameters a, b, c of the general equation of the straight line, we can respectively find a1, b1, c1 of the diagonal line segment and a2, b2, c2 of the edge line segment of the intersection box. Then we can calculate the horizontal coordinate x and vertical coordinate y of the intersection point of the diagonal line segment and the edge line segment of the intersection box. The calculation formula is:

[0048]

[0049]

[0050] Since a diagonal line and a rectangular box have only two intersection lines, that is, two intersection points, through the Euclidean distance, we can calculate the distance between the two intersection points, that is, the matching length of the diagonal line covered by the intersection box.

[0051] Since a detection box may correspond to multiple real annotation boxes of the same type, we traverse each intersection box, repeat the above two steps, and iteratively sum the matching lengths.

[0052] Assumptions Figure 4 The solid frame in the left figure is the detection frame, and the dotted frame is the detection frame. If IOU ≥ 0.5 is used to determine whether the detection is correct or not, then the accuracy and recall rates are both zero; however, the detection of the present invention is very accurate. First, the present invention first calculates the intersection frame, such as Figure 4 As shown in the transparent area on the right, when we use the evaluation index based on diagonal matching, we can accurately reflect the detection effect of the model. The results are as follows Figure 5 As shown, Figure 5 There are three dotted boxes in the figure, which are the intersection boxes of the three real annotation boxes and the realized detection boxes. For each intersection box, the matching lengths of the diagonal of the solid detection box and the intersection box are calculated, which are recorded as L1, L2, and L3 respectively; then the final Match Length = L1+L2+L3. We compare the Match Length with the length of the diagonal line itself to determine whether the detection is correct. The standard used in our method is

[0053] The above description is only a preferred embodiment of the present invention. It should be pointed out that for those skilled in the art, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present invention.

Claims

1. A post-processing and diagonal evaluation method for road damage target detection, characterized in that: The following steps are involved: Step 1: Merge bounding boxes of the same type: Selectively merge bounding boxes of the same type with partially redundant detections; Step 2: Suppress highly overlapping bounding boxes: The road damage situation is relatively complex. The damaged road surface in the same area may be detected as different damage types, so there may be multiple highly overlapping detection boxes. In this step, the highly overlapping bounding boxes are suppressed, and only the detection boxes with higher confidence or the detection boxes with the same confidence but larger area are retained; Step 3: Suppress small frames covered by large frames: Select the detection frame with a smaller suppression area. If most of the area of ​​a small frame is already included in the larger detection frame, remove the small frame. From the application point of view, pavement repair gives priority to larger area damage; Step 4: Evaluation criteria based on diagonals: First, find the intersection frame of all detection frames and true annotation frames, match the detection frame with the intersection frame, calculate how much of the diagonal of the detection frame is covered by the intersection frame, and use the ratio of the matching length of the diagonal divided by the length of the diagonal of the detection frame to determine whether the detection frame is correct.

2. The post-processing and diagonal evaluation method for road damage target detection according to claim 1, characterized in that: The condition for merging in step 1 is that the IOU of the bounding box is greater than 0.

25.

3. The post-processing and diagonal evaluation method for road damage target detection according to claim 1 or 2, characterized in that: The merging method in step 1 is to replace the bounding box with the minimum circumscribed rectangle of the bounding box.

4. The post-processing and diagonal evaluation method for road damage target detection according to claim 1, characterized in that: The IOU threshold for determining whether two bounding boxes are highly overlapped in step 2 is set to 0.

5.

5. The post-processing and diagonal evaluation method for road damage target detection according to claim 1, characterized in that: Calculating how much of the diagonal of the detection frame is covered by the intersection frame in step 4 specifically includes the following steps: the diagonal is expressed as a line segment, and the four sides of the intersection frame can also be expressed as four line segments. By calculating the intersection points of the diagonal line segments and the intersection box side segments, it is calculated how much of the diagonal of the detection frame is covered by the intersection frame.

6. The post-processing and diagonal evaluation method for road damage target detection according to claim 5, characterized in that: The calculation process is as follows: The diagonal line segment of the detection box is represented by two-point coordinates (x0, y0) and (x1, y1). (x0, y0) and (x1, y1) are the two endpoint coordinates of the diagonal line segment of the detection box output by the model. Use the line segment coordinates to find the intersection point with the two intersecting side segments of the intersection box. The side segment representation method is the same as the diagonal line segment. The calculation steps are as follows: The linear equation used is the general formula: ax+by+c=0, Given the coordinates of the two endpoints of a line segment, find a, b, and c in the general straight line equation; a=y1-y0, b=-(x1-x0), c=-a×x0-b×y0 Using the parameters a, b, c of the general equation of the straight line, we can respectively find a1, b1, c1 of the diagonal line segment and a2, b2, c2 of the edge line segment of the intersection box, and then calculate the horizontal coordinate x and vertical coordinate y of the intersection point of the diagonal line segment and the edge line segment of the intersection box. The calculation formula is:

7. The post-processing and diagonal evaluation method for road damage target detection according to claim 1, characterized in that: In step 4, since a diagonal line and the rectangular frame have only two intersection lines, namely two intersection points, the distance between the two intersection points is calculated by Euclidean distance, that is, the matching length of the diagonal line covered by the intersection frame.

8. The post-processing and diagonal evaluation method for road damage target detection according to claim 1 or 6, characterized in that: In step 4, when a detection box corresponds to multiple real annotation boxes of the same type, the calculation process is repeated to iteratively sum the matching lengths.

9. The post-processing and diagonal evaluation method for road damage target detection according to claim 1, characterized in that: The criterion for judging whether the detection frame is correct in step 4 is that the ratio of the matching length of the diagonal divided by the length of the diagonal of the detection frame is greater than or equal to 0.5.