Search

CN-114399546-B - Target detection method and device

CN114399546BCN 114399546 BCN114399546 BCN 114399546BCN-114399546-B

Abstract

The invention provides a target detection method and device, the method comprises the steps of carrying out target detection on an obtained target image to be detected to obtain a target detection result, inputting the target detection result into an area prediction model to obtain a target prediction area output by the area prediction model, wherein the area prediction model is obtained by training based on the target prediction result corresponding to a target training image and a target area true value corresponding to the target training image, the area prediction model is used for predicting based on position coordinates extracted from the target detection result to obtain a target prediction area, obtaining a target actual area based on the target detection result, and judging whether the target detection result is accurate or not according to the target prediction area and the target actual area to obtain an accuracy detection result. The accuracy of the target detection result is determined by comparing the target prediction area obtained by predicting the target detection result with the target actual area obtained by detecting the target.

Inventors

  • WANG KANG
  • ZHANG YINGYING
  • CHENG XINJING

Assignees

  • 际络科技(上海)有限公司

Dates

Publication Date
20260508
Application Date
20211130

Claims (9)

  1. 1. A method of detecting an object, comprising: performing target detection on the acquired target image to be detected to obtain a target detection result; inputting the target detection result into an area prediction model to obtain a target prediction area output by the area prediction model; The area prediction model is obtained by training based on a target prediction result corresponding to a target training image and a target area true value corresponding to the target training image; the area prediction model is used for predicting the position coordinates extracted from the target detection result to obtain a target prediction area; obtaining a target actual area based on the target detection result; judging whether the target detection result is accurate according to the target prediction area and the target actual area to obtain an accuracy detection result; based on the target detection result, obtaining a target actual area includes: obtaining the coordinate position of the target according to the target detection result; calculating according to the coordinate position of the target to obtain the actual area of the target; The area prediction model includes: the feature extraction layer is used for extracting features of an input target detection result to obtain center point position coordinates; the target area prediction layer predicts based on the central point position coordinates to obtain a target prediction area; extracting features of an input target detection result to obtain center point position coordinates, wherein the feature extraction comprises the following steps: Extracting target contour features based on the target detection result; and obtaining the coordinates of the central point according to the extracted contour features.
  2. 2. The target detection method according to claim 1, wherein the predicting based on the center point position coordinates to obtain a target predicted area includes: and based on the central point position coordinates, predicting the target area by utilizing a regression line obtained by fitting in advance to obtain the target predicted area.
  3. 3. The method for detecting an object according to claim 1, further comprising performing edge processing on the object image to be detected before performing feature extraction on the input object detection result.
  4. 4. The method of claim 1, wherein the determining whether the target detection result is accurate according to the target predicted area and the target actual area, to obtain an accuracy detection result, includes: obtaining a deviation value according to the target predicted area and a target actual area obtained in advance; and comparing the deviation value with a preset range to obtain an accuracy detection result.
  5. 5. The method of claim 1, wherein training the area prediction model comprises: acquiring a target training image and a target area true value corresponding to the target training image; performing target detection on the target training image to obtain a target prediction result; And training the model to be trained based on the target prediction result as input data used for training and the target area true value as a label to obtain an area prediction model for generating a predicted target area of the target detection result.
  6. 6. An object detection apparatus, comprising: the target detection module is used for carrying out target detection on the acquired target image to be detected to obtain a target detection result; the area prediction module is used for inputting the target detection result into an area prediction model to obtain a target prediction area output by the area prediction model; the area prediction model is obtained by training based on a target prediction result corresponding to a target training image and a target area truth value corresponding to the target training image, and is used for predicting based on position coordinates extracted from the target detection result to obtain a target prediction area; the area acquisition module is used for acquiring the actual area of the target based on the target detection result; the accuracy detection module is used for judging whether the target detection result is accurate according to the target prediction area and the target actual area to obtain an accuracy detection result; the area acquisition module includes: The target acquisition unit is used for acquiring the coordinate position of the target according to the target detection result; the area acquisition unit is used for calculating according to the coordinate position of the target to obtain the actual area of the target; the area prediction module includes: The feature extraction unit is used for extracting features of the input target detection result to obtain center point position coordinates; The target area prediction unit predicts the target area based on the central point position coordinates to obtain a target predicted area; The feature extraction unit includes: a feature extraction subunit, for extracting a target contour feature based on the target detection result; and the coordinate acquisition subunit acquires the coordinates of the central point position according to the extracted contour features.
  7. 7. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the steps of the object detection method according to any one of claims 1 to 5 when the program is executed by the processor.
  8. 8. A non-transitory computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when executed by a processor, implements the steps of the object detection method according to any one of claims 1 to 5.
  9. 9. A computer program product comprising a computer program which, when executed by a processor, implements the steps of the object detection method according to any one of claims 1 to 5.

Description

Target detection method and device Technical Field The present invention relates to the field of image processing technologies, and in particular, to a target detection method and apparatus. Background The target detection is an important research content in the field of computer vision, in recent years, the deep learning and neural network technology continuously breaks through the target detection task, and in the field of automatic driving of automobiles, along with development and upgrading of the automatic driving technology, a visual perception scheme based on the deep learning and neural network technology is widely applied in the field of automatic driving gradually. Often, objects, such as pedestrians and vehicles, need to be avoided during automatic driving, detection of the objects is critical to automatic driving, and the accuracy of the detection of the objects determines an automatic driving decision of automatic driving. At present, an accuracy rate detection method generally adopted for a target detection model is mostly used for detecting the accuracy rate of the target detection model before the trained target detection model is put into use, and the accuracy rate reaches a certain threshold value based on the detection accuracy rate and is put into use again, so that the accuracy rate of target detection is improved. The accuracy of the model which is put into use after passing the accuracy detection is fixed, and the accuracy of the model cannot reach the accuracy of a hundred percent, so that partial errors still exist in the detection result correspondingly output by the model. Disclosure of Invention The invention provides a target detection method and device, which are used for solving the defect of poor target detection accuracy in the prior art so as to detect the target detection result in accuracy and improve the detection accuracy. The invention provides a target detection method, which comprises the steps of carrying out target detection on an obtained target image to be detected to obtain a target detection result, inputting the target detection result into an area prediction model to obtain a target prediction area output by the area prediction model, wherein the area prediction model is obtained by training based on a target prediction result corresponding to a target training image and a target area true value corresponding to the target training image, the area prediction model is used for predicting based on position coordinates extracted from the target detection result to obtain a target prediction area, obtaining a target actual area based on the target detection result, and judging whether the target detection result is accurate or not according to the target prediction area and the target actual area to obtain an accuracy detection result. The target detection method comprises a feature extraction layer, a target area prediction layer and a target prediction area prediction layer, wherein the feature extraction layer is used for extracting features of an input target detection result to obtain central point position coordinates, and the target area prediction layer is used for predicting the central point position coordinates to obtain a target prediction area. The target detection method comprises the steps of predicting the target area by utilizing a regression line obtained by fitting in advance based on the central point position coordinates to obtain the target prediction area. According to the target detection method provided by the invention, before the input target detection result is subjected to feature extraction, the method further comprises the step of carrying out edge processing on the target image to be detected. The target detection method provided by the invention judges whether the target detection result is accurate according to the target prediction area and the target actual area to obtain an accuracy detection result, and comprises the steps of obtaining a deviation value according to the target prediction area and a target actual area obtained in advance, and comparing the deviation value with a preset range to obtain the accuracy detection result. The target detection method comprises the steps of obtaining a target training image and a target area true value corresponding to the target training image, carrying out target detection on the target training image to obtain a target prediction result, and training a model to be trained based on the target prediction result as input data used for training and the target area true value as a label to obtain an area prediction model for generating a predicted target area of the target detection result. The invention further provides a target detection device, which comprises a target detection module, an area prediction module, an area detection module and an accuracy detection module, wherein the target detection module is used for carrying out target detection on an acquired target image to be det