Data screening method and device, equipment and medium

Through the fusion and threshold judgment of the prediction data of the target detection model, the problem of difficulty in identifying uncertain samples by the target detection model is solved, and the accurate screening of uncertain samples and the improvement of detection effect are achieved.

CN118537632APending Publication Date: 2024-08-23ZHEJIANG GEELY HLDG GRP CO LTD +1
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202410582311.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-11
Publication Date
2024-08-23

AI Technical Summary

Technical Problem

When dealing with uncertain samples that are difficult to identify, target detection models have problems with identification difficulties and inaccurate detection results, resulting in inaccurate screening.

Method used

By obtaining sample data and inputting it into multiple target detection models, including teacher models and student models, the prediction data is fused, combined with prediction boxes and confidence levels, to determine the image type of the sample images, and use the intersection ratio and uncertainty threshold to filter out Uncertain sample.

Benefits of technology

It achieves accurate screening of uncertain samples that are difficult to identify by the target detection model, improves the detection effect, reduces uncertainty, and improves screening efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118537632A
    Figure CN118537632A
Patent Text Reader

Abstract

The invention provides a data screening method and device, equipment and a medium, and the method comprises the steps: obtaining a sample data set which comprises a sample image; respectively inputting sample images in the sample data set into a plurality of preset target detection models to obtain a plurality of pieces of output prediction data, the plurality of pieces of prediction data respectively corresponding to the plurality of target detection models, and the prediction data comprising a prediction frame and a confidence coefficient of the prediction frame; and performing data fusion on the prediction frames of the plurality of prediction data and the confidence, so as to determine an image type of the sample image based on a data fusion result, the image type including an uncertain sample and a certain sample. According to the method, the prediction frames of the multiple target detection models and the confidence coefficients of the prediction frames are comprehensively considered, and uncertain samples which are difficult to recognize by the target detection models can be accurately screened out.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of data processing technology, and in particular to a data screening method, device, equipment and medium. Background Art

[0002] Target detection models are widely used in target detection scenarios such as parking space recognition, obstacle recognition, and face recognition to detect target areas. However, when the target detection model detects some uncertain samples that are difficult to identify, it will have difficulty in recognition, and the detection results will have high inaccuracy. Therefore, screening out uncertain samples is very beneficial to improving the detection effect of the target detection model. However, at present, there is a problem of inaccurate screening when screening uncertain samples of the target detection model. Summary of the invention

[0003] The purpose of the present invention is to provide a data screening method, device, equipment and medium, which can accurately screen out uncertain samples that are difficult to identify by a target detection model.

[0004] In order to solve the above technical problems, the present invention is achieved through the following technical solutions:

[0005] The present invention provides a data screening method, comprising:

[0006] Acquire a sample data set, wherein the sample data set includes a sample image;

[0007] Inputting the sample images in the sample data set into a plurality of preset target detection models respectively to obtain a plurality of output prediction data, wherein the plurality of prediction data respectively correspond to the plurality of target detection models, and the prediction data include a prediction box and a confidence level of the prediction box;

[0008] Data fusion is performed on the prediction frames and the confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion, wherein the image type includes an uncertain sample and a determined sample.

[0009] In one embodiment of the present invention, the plurality of target detection models include a plurality of target teacher models and a target student model, and the step of inputting the sample images in the sample data set into the plurality of preset target detection models respectively to obtain the output of the plurality of prediction data includes:

[0010] Inputting the sample images in the sample data set into the plurality of target teacher models respectively to obtain a plurality of first prediction data as output, wherein the plurality of first prediction data respectively correspond to the plurality of target teacher models, and the first prediction data include a first prediction box and a first confidence of the first prediction box;

[0011] A sample image in the sample data set is input into the target student model to obtain output second prediction data, where the second prediction data includes a second prediction box and a second confidence level of the second prediction box.

[0012] In one embodiment of the present invention, the step of fusing the prediction frames and confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion includes:

[0013] Performing data fusion on a plurality of the first prediction boxes, the second prediction boxes, the first confidences, and the second confidences corresponding to the sample image to generate an uncertainty indicator;

[0014] Determine whether the uncertainty index is greater than or equal to a preset uncertainty threshold. If so, determine that the image type of the sample image is an uncertain sample. If so, determine that the image type of the sample image is a determined sample.

[0015] In one embodiment of the present invention, before the step of performing data fusion on the prediction frames and confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion, the method further includes:

[0016] Determine in sequence whether an intersection-and-union ratio between each of the first prediction boxes and the second prediction boxes is greater than or equal to a preset intersection-and-union ratio threshold;

[0017] If there is at least one intersection-and-union ratio between the first prediction box and the second prediction box that is smaller than the intersection-and-union ratio threshold, determining that the image type of the sample image is an uncertain sample;

[0018] If the intersection-and-union ratio between each of the first prediction boxes and the second prediction boxes is greater than or equal to the intersection-and-union ratio threshold, data fusion is performed on the prediction boxes and confidences of the multiple prediction data to determine the image type of the sample image based on the result of the data fusion.

[0019] In an embodiment of the present invention, before the step of determining whether the intersection-and-union ratio between each of the first prediction boxes and the second prediction boxes is greater than or equal to the intersection-and-union ratio threshold, the step further includes:

[0020] Obtain the model number of the target teacher model having the first prediction box in the first prediction data;

[0021] Determine whether the number of models is greater than or equal to a preset number threshold, if it is greater than or equal to the number threshold, then continue to determine whether the intersection and union ratio between each of the first prediction box and the second prediction box is greater than or equal to the intersection and union ratio threshold, if it is less than the number threshold, then determine that the image type of the sample image is an uncertain sample

[0022] In one embodiment of the present invention, before the step of inputting the sample images in the sample data set into a plurality of preset target detection models to obtain a plurality of output prediction data, the step further includes:

[0023] Constructing multiple initial teacher models, and training the multiple initial teacher models respectively based on a preset training image set to generate multiple target teacher models;

[0024] An initial student model is constructed, and the initial student model is trained based on the training image set to generate the target student model.

[0025] In one embodiment of the present invention, the step of constructing a plurality of initial teacher models and training the plurality of initial teacher models respectively based on a preset training image set to generate a plurality of target teacher models comprises:

[0026] Constructing multiple initial teacher models, and setting model parameters of the initial teacher models based on the target detection scenario to generate multiple rotation target detection models;

[0027] The plurality of rotation target detection models are trained based on a preset training image set to generate a plurality of target teacher models.

[0028] The present invention also provides a data screening device, comprising:

[0029] A data acquisition module, used to acquire a sample data set, wherein the sample data set includes a sample image;

[0030] A model detection module, used for inputting the sample images in the sample data set into a plurality of preset target detection models respectively to obtain a plurality of output prediction data, wherein the plurality of prediction data respectively correspond to the plurality of target detection models, and the prediction data include a prediction box and a confidence level of the prediction box;

[0031] The data screening module is used to perform data fusion on the prediction boxes and confidences of the multiple prediction data to determine the image type of the sample image based on the result of the data fusion, and the image type includes an uncertain sample and a determined sample.

[0032] The present invention also provides an electronic device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the above-mentioned data screening method are implemented.

[0033] The present invention also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the steps of the above-mentioned data screening method are implemented.

[0034] As described above, the present invention provides a data screening method, device, equipment and medium, which comprehensively considers the prediction boxes of multiple target detection models and the confidence of the prediction boxes, and can accurately screen out uncertain samples that are difficult for the target detection model to identify.

[0035] Of course, any product implementing the present invention does not necessarily need to achieve all of the advantages described above at the same time. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings required for describing the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without paying creative work.

[0037] Figure 1 This is a scene structure diagram of the data screening method of the present invention applied to target detection.

[0038] Figure 2 The present invention is a flow chart of the data screening method.

[0039] Figure 3 for Figure 2 Flowchart of step S20 in FIG.

[0040] Figure 4 for Figure 2 Flowchart of step S30 in FIG.

[0041] Figure 5 for Figure 2 Flowchart of steps before step S30 in FIG.

[0042] Figure 6 It is a structural diagram of the data screening device of the present invention. DETAILED DESCRIPTION

[0043] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0044] The data screening method provided in this application can be applied to scenarios where target detection models are used for target detection to quickly screen out samples that are difficult to detect. Samples that are difficult to detect can continue to be labeled with targets in any other highly accurate manner.

[0045] Taking the actual scenario of target detection for parking spaces as an example, the parking space image is input into the target detection model. When the target detection model recognizes correctly, the target detection model can output the correct parking space prediction box. When the target detection model recognizes uncertainly, the parking space prediction box output by the target detection model may not be accurate. The present application takes into account the uncertainty problem when the target detection model performs target detection on some parking space images, and provides a data screening method, which can analyze the inaccuracy of the prediction data based on the prediction data of the target detection model to quickly screen out parking space images with high uncertainty. Parking space images with high uncertainty can be marked with parking spaces through other high-accuracy methods.

[0046] In the actual scenario of target detection of obstacles around the vehicle, the obstacle image is input into the target detection model, and the target detection model can output the obstacle prediction frame. Considering the problem of high uncertainty when the target detection model performs target detection on some obstacle images, the present application provides a data screening method, which can analyze the inaccuracy of the prediction data based on the prediction data of the target detection model, so as to quickly screen out obstacle images with high uncertainty, and the obstacle images with high uncertainty can be marked with obstacle areas by other methods with high accuracy.

[0047] It should be noted that the application scenarios of this data screening method are not limited to the above examples, but may also be obstacle recognition scenarios, road sign recognition scenarios, face recognition scenarios or other applicable target recognition scenarios.

[0048] See also Figure 1 , Figure 1 The present invention shows a scenario architecture diagram of the data screening method of the present application applied to target detection, and the scenario architecture includes an image acquisition end and a server end, and the image acquisition end is communicatively connected to the server end. The image acquisition end can acquire sample images and transmit them to the server end, and the server end can use a data screening method to determine whether the sample image is an image with high uncertainty. When running the data screening method, first, after receiving the sample image, the server end inputs the sample image into a pre-created target detection model to output prediction data. Based on the prediction data, the inaccuracy of the prediction data can be analyzed, so that it can be determined whether the sample image is an image with high uncertainty. If the sample image is an image with high uncertainty, the parking space is marked by other methods with high accuracy. It should be noted that the server end can be composed of one or more servers. The image acquisition end can include various types of equipment such as vehicles, computers, camera equipment, wearable devices, etc.

[0049] See also Figure 1, taking the application of the data screening method to parking space detection as an example, the image acquisition end can be a vehicle. The on-board camera on the vehicle can capture the parking space image and transmit it to the server side, and the server side can use the data screening method to determine whether the parking space image is an image with high uncertainty. When running the data screening method, first, after the server side receives the parking space image, the parking space image is input into a pre-created target detection model to output prediction data. Based on the prediction data, it can be determined whether the parking space image is an image with high uncertainty. If the parking space image is an image with high uncertainty, the parking space is marked by other methods with high accuracy. For example, the correct parking space frame is manually marked.

[0050] See also Figure 2 , Figure 2 A flow chart of a data screening method is shown. The data screening method provided by the present invention may include the following steps:

[0051] Step S10, obtaining a sample data set, where the sample data set includes a sample image;

[0052] Step S20: inputting the sample images in the sample data set into a plurality of preset target detection models respectively to obtain a plurality of output prediction data, wherein the plurality of prediction data respectively correspond to the plurality of target detection models, and the prediction data include a prediction box and a confidence of the prediction box;

[0053] Step S30: performing data fusion on the prediction boxes and confidences of the plurality of prediction data, so as to determine the image type of the sample image based on the result of the data fusion, where the image type includes an uncertain sample and a determined sample.

[0054] In one embodiment of the present invention, in step S10, a sample data set is obtained, and the sample data set includes a sample image. Specifically, the sample image may be a target image. One or more target images may constitute a sample data set. Taking the scenario where the data screening method is applied to parking space target detection as an example, the sample image is a parking space image, such as. The parking space image may be collected and stored by vehicle-side devices such as vehicle-side cameras and vehicle-side sensors. The vehicle-side device may collect multiple parking space images, generate a sample data set including multiple parking space images, and transmit the sample data set to the server side, so that the server side can detect whether each parking space image is an uncertain sample based on the prediction data of the target detection model, thereby screening out parking space images with high uncertainty from multiple parking space images.

[0055] Of course, the vehicle-side device can also generate a sample data set containing a parking space image after collecting a parking space image, and transmit the sample data set to the server side so that the server side can detect whether the parking space image is an uncertain sample based on the prediction data of the target detection model.

[0056] It should be noted that, in the scenario of performing target detection on obstacles around a vehicle, the sample image is the obstacle region image. In the scenario of performing target detection on a human face, the sample image is the human face image.

[0057] In one embodiment of the present invention, in step S20, the sample images in the sample data set are respectively input into a plurality of preset target detection models to obtain a plurality of output prediction data, wherein the plurality of prediction data correspond to the plurality of target detection models respectively, and the prediction data include prediction boxes and the confidence of the prediction boxes. Specifically, the preset target detection model can be a convolutional neural network model, a residual network model or other neural network model pre-trained on the server side, such as a yolov5 network model. When multiple target detection models perform target detection on the same sample image, the plurality of prediction data obtained by the plurality of target detection models may be different. If the difference between the plurality of prediction data obtained by the plurality of target detection models is large, it can be explained that when the sample image is predicted by the target detection model, the prediction data is likely to be inaccurate, and at this time the sample image is an uncertain sample. If the difference between the plurality of prediction data obtained by the plurality of target detection models is small, it can be explained that when the sample image is detected by the target detection model, the prediction data is likely to be accurate, and at this time the sample image is a determined sample. Therefore, the sample images in the sample data set can be respectively input into multiple preset target detection models. Based on the differences between the prediction data of multiple target detection models for a sample image, it can be determined whether the image type of the sample image is an uncertain sample or a determined sample.

[0058] Furthermore, the prediction data of the target detection model for the sample image may include a prediction box and the confidence of the prediction box. For example, when performing parking space target detection, the parking space image is input into the target detection model, and the target detection model may output a marked parking space box, which is the prediction box. In addition, the target detection model may output the attributes and confidence of the parking space box. The attributes may include whether the vehicle can be parked or not, and the confidence may indicate the certainty of the attribute. When considering the differences between the prediction data of multiple target detection models, the prediction boxes and the confidence of the prediction boxes of multiple target detection models are comprehensively considered, so that the differences between the multiple prediction data can be more accurately determined.

[0059] In one embodiment of the present invention, taking into account the actual application scenario of the data screening method, when the target detection model used by the data screening method needs to be deployed in a smaller system, the present application can preset multiple target detection models as multiple target teacher models and a target student model. It should be explained here that the target teacher model is a teacher network model (teacher model), and the target student model is a student network model (student model). The network structure of the teacher network model is more complex than that of the student network model. In the initial model training stage, the same training samples can be used to train the two models to generate a small student network model and a larger teacher network model with similar detection effects. The small target student model can be deployed in a smaller system. The target teacher model has a more complex, larger network structure with stronger computing power, which can be deployed on the server side to provide more prediction data, thereby obtaining better data screening effects.

[0060] Furthermore, after the data screening method of the present application screens out uncertain samples and uses other methods with high accuracy to label the samples, the labeled uncertain samples can be used to train the above-mentioned target student model to improve the prediction accuracy of the target student model. The trained small target student model has a simple structure and high prediction accuracy, and can be directly deployed in a smaller system for target detection.

[0061] See also Figure 3 In one embodiment of the present invention, in step S20, the following steps may be specifically included:

[0062] Step S21: input the sample images in the sample data set into multiple target teacher models respectively to obtain multiple first prediction data as output, wherein the multiple first prediction data correspond to the multiple target teacher models respectively, and the first prediction data include a first prediction box and a first confidence of the first prediction box.

[0063] Step S22: input the sample image in the sample data set into the target student model to obtain output second prediction data, where the second prediction data includes a second prediction box and a second confidence of the second prediction box.

[0064] When executing step S21 and step S22, it should be understood that when the data screening method performs parking space target detection, the sample image is the parking space image. After the parking space image is collected by a vehicle-mounted camera or sensor or other equipment, the parking space image can be input into multiple target teacher models to obtain multiple first prediction data output by multiple target teacher models respectively. This first prediction data may include the parking space frame marked by the target teacher model, the attributes of the parking space frame, and the first confidence. The parking space frame marked by the target teacher model is the first prediction frame, and the first confidence can represent the certainty of the attribute output by the target teacher model. In addition, the parking space image can be input into the target student model to obtain the output second prediction data, and this second prediction data may include the parking space frame marked by the target student model, the attributes of the parking space frame, and the second confidence. The parking space frame marked by the target student model is the second prediction frame, and the second confidence can represent the certainty of the attribute output by the target student model.

[0065] See also Figure 3 In one embodiment of the present invention, before step S20, that is, before the step of inputting the sample images in the sample data set into the preset multiple target detection models respectively to obtain the output multiple prediction data, the following steps are also included:

[0066] Step S201: construct multiple initial teacher models, and train the multiple initial teacher models based on a preset training image set to generate multiple target teacher models.

[0067] Step S202: construct an initial student model, and train the initial student model based on the training image set to generate a target student model.

[0068] In one embodiment of the present invention, in step S201 and step S202, specifically, taking the scenario where the data screening method is applied to parking space target detection as an example, the training image set includes multiple training images, and the training images may include multiple images pre-collected by devices such as vehicle-mounted cameras or sensors, parking space frames annotated for each image, and frame attributes, and the frame attributes may be parking available or non-parking available. The number of multiple training images may not be limited and may be specifically set based on actual training needs. The annotated training images may be input into the initial teacher model or the initial student model for model training to obtain the final target detection model.

[0069] When training multiple initial teacher models and initial student models, the same training image set can be used to train each model to obtain multiple target detection models with similar detection effects. This facilitates the subsequent determination of whether the image type of the sample image is an uncertain sample or a certain sample based on the differences between the prediction data of multiple target detection models for a sample image.

[0070] It should be noted that the initial teacher model and the initial student model can be a yolov5 model, an SSD model, an RCNN model or other target detection models. It should be explained that the yolov5 model can include a yolov5s model, a yolov5m model, a yolov5l model, a yolov5x model and other yolov5 models. Among them, the model structure of the yolov5s model is smaller than that of the yolov5m model, the model structure of the yolov5m model is smaller than that of the yolov5l model, and the model structure of the yolov5l model is smaller than that of the yolov5x model. However, the model speed of the yolov5s model is greater than that of the yolov5m model, the model speed of the yolov5m model is greater than that of the yolov5l model, and the model speed of the yolov5l model is greater than that of the yolov5x model. When the initial teacher model is the yolov5 model, the initial teacher model can select the specific type of the yolov5 model based on the calculation speed requirements and the amount of calculation data, such as the yolov5l model with a larger model structure. The initial student model can also select the specific type of the yolov5 model based on the calculation speed requirements and the amount of calculation data, such as the yolov5s model with a smaller model structure.

[0071] Furthermore, the specific model parameters of the initial teacher model and the initial student model can be adjusted based on the actual target detection scenario. Taking the parking space target detection scenario as an example, when the initial teacher model is the yolov5 model, the yolov5 model performs target detection based on a rectangular box. However, when performing actual target detection, the shape features of the parking space target often undergo rotation changes, and the rectangular box is difficult to accurately identify.

[0072] Based on the above problems, the model parameters of the yolov5 model can be adjusted based on the rotation of the parking space target, for example, by increasing the number of network layers, adjusting the loss function, etc., to generate a yolov5-obb model (rotated target detection model). When the yolov5-obb model performs target detection on the parking space, it can detect and identify the rotated target frame and obtain a more accurate parking space frame detection result.

[0073] It can be explained that when pre-training the yolov5-obb model, training images with various rotation angles can be collected to train the yolov5-obb model to train the required target detection model. Taking the scenario where the data screening method is applied to parking space target detection as an example, multiple images pre-collected by devices such as vehicle-mounted cameras or sensors can be obtained, and the rotated parking space frame and frame attributes of each image can be annotated. The frame attributes can be parking or non-parking. The annotated training images are input into the yolov5-obb model for training, and the required target teacher model can be obtained in the end.

[0074] Furthermore, when the initial student model is a yolov5 model, the specific model parameters of the initial student model can also be adjusted based on actual applications to create a rotation target detection model to obtain a more accurate detection result. Of course, the rotation target detection model is not limited to the above-mentioned yolov5-obb model improved based on the yolov5 model, but can also be an RCNN model, an SSD model or other rotation target detection models.

[0075] See also Figure 4 In step S30, data fusion is performed on the prediction frames and confidences of the multiple prediction data to determine the image type of the sample image based on the result of the data fusion, which specifically includes the following steps:

[0076] Step S31, performing data fusion on a plurality of first prediction boxes, second prediction boxes, first confidences and second confidences corresponding to the sample image to generate an uncertainty index;

[0077] Step S32: determine whether the uncertainty index is greater than or equal to a preset uncertainty threshold. If it is greater than or equal to the uncertainty threshold, determine that the image type of the sample image is an uncertain sample. If it is less than the uncertainty threshold, determine that the image type of the sample image is a determined sample.

[0078] In one embodiment of the present invention, for step S31 and step S32, specifically, the data screening method of the present application, when considering the differences between the prediction data of multiple target detection models, comprehensively considers the prediction boxes of multiple target teacher models and target student models and the confidence of the prediction boxes, and can more accurately determine the difference size of multiple prediction data. It not only fuses the positions of the prediction boxes of multiple target teacher models and target student models, but also considers the confidence of each model for the prediction box, and this fused data is more comprehensive and accurate. Further, the data generated by the data fusion of the data screening method is an uncertain indicator, and the uncertain indicator can be used to indicate the inaccuracy of the prediction of the sample image by multiple target detection models. The higher the uncertainty indicator, the greater the inaccuracy. Based on the preset uncertainty threshold and the uncertainty indicator of each sample image, a quick comparison is performed to determine whether the sample image is a certain sample or an uncertain sample. The screened uncertain samples can be annotated in other ways with high accuracy, such as manual annotation. This data screening method is not only highly accurate, but also has a faster screening efficiency. It should be noted that the uncertainty threshold can be set based on actual screening requirements, such as 0.6, 0.7 or other thresholds. When the screening requirement is high, the uncertainty threshold can be set lower, and sample images greater than or equal to the uncertainty threshold are determined as uncertain samples. When the screening requirement is low, the uncertainty threshold can be set higher.

[0079] In order to more accurately fuse multiple first prediction boxes, second prediction boxes, first confidences, and second confidences, the data screening method of the present application provides an uncertainty index formula, which can fuse the intersection-over-union ratio between the first prediction box and the second prediction box, the first confidence of the first prediction box, and the second confidence of the second prediction box together, and perform average calculation to obtain the data fusion results of multiple target teacher models and target student models, that is, the uncertainty index. The above uncertainty index can be expressed as U, Among them, iou k represents the intersection-over-union ratio between the first prediction box corresponding to the K-th target teacher model and the second prediction box corresponding to the target student model, score k Represents the first confidence of the first prediction box corresponding to the K-th target teacher model, K is a positive integer, score s Represents the second confidence of the second prediction box corresponding to the target student model. n t Represents the number of target teacher models whose IoU ratio between the first prediction box and the second prediction box is greater than or equal to the IoU threshold.

[0080] It should be noted that in the above uncertainty indicator formula, data fusion can be performed only on the target teacher model whose IoU ratio between the first prediction box and the second prediction box is greater than or equal to the IoU ratio threshold. The target teacher model whose IoU ratio between the first prediction box and the second prediction box is greater than or equal to the IoU ratio threshold can be pre-determined as an uncertain sample and does not need to participate in data fusion, thereby reducing the amount of data calculation and greatly improving data screening efficiency. For details, please refer to Figure 5 , before step S30, that is, before the step of fusing the prediction frames and confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion, the following steps are also included:

[0081] Step S301: determine in turn whether the intersection-and-union ratio between each first prediction frame and the second prediction frame is greater than or equal to a preset intersection-and-union ratio threshold.

[0082] Step S302: If there is at least one IoU ratio between the first prediction box and the second prediction box that is less than an IoU ratio threshold, determine that the image type of the sample image is an uncertain sample.

[0083] Step S303: If the IoU ratio between each first prediction box and the second prediction box is greater than or equal to the IoU ratio threshold, data fusion is performed on the prediction boxes and confidences of multiple prediction data to determine the image type of the sample image based on the result of the data fusion.

[0084] In one embodiment of the present invention, in step S301, step S302 and step S303, since multiple target teacher models can be set, when judging whether the intersection-and-union ratio between the first prediction frame and the second prediction frame is greater than or equal to the preset intersection-and-union ratio threshold, it can be judged in turn whether the intersection-and-union ratio between the first prediction frame and the second prediction frame of each target teacher model is greater than or equal to the intersection-and-union ratio threshold. As long as there are a predetermined number of intersection-and-union ratios between the first prediction frame and the second prediction frame that are less than the intersection-and-union ratio threshold, it can be determined that when multiple target teacher models and target student models detect the sample image, the uncertainty is high, and this sample image is an uncertain sample, and no data fusion is required, which greatly reduces the amount of data calculation. This predetermined number can be set to at least one, for example, one, two or other numbers. If the intersection-and-union ratio of a prediction frame of each target teacher model to the second prediction frame is greater than or equal to the intersection-and-union ratio threshold, it can be explained that when multiple target teacher models and target student models detect the sample image, they have a high degree of certainty. However, at this time, data fusion is still needed to obtain an uncertainty index to further determine whether the sample image is a certain sample. The accuracy and efficiency of this data screening method are greatly improved. It should be noted that the above-mentioned intersection-and-union ratio threshold can be set based on actual screening requirements, such as 0.7, 0.8 or other thresholds. When the screening requirements are high, the intersection-and-union ratio threshold can be set higher, and sample images less than the intersection-and-union ratio threshold are determined as uncertain samples. When the screening requirements are low, the uncertainty threshold can be set lower.

[0085] See also Figure 5 In one embodiment of the present invention, before step S301, that is, before determining whether the intersection-and-union ratio between each first prediction frame and the second prediction frame is greater than or equal to a preset intersection-and-union ratio threshold, the following steps may also be included:

[0086] Step S304, obtaining the number of models of the target teacher model having the first prediction box in the first prediction data;

[0087] Step S305, determine whether the number of models is greater than or equal to a preset number threshold. If it is greater than or equal to the number threshold, continue to determine whether the intersection and union ratio between each first prediction box and the second prediction box is greater than or equal to the intersection and union ratio threshold. If it is less than the number threshold, determine that the image type of the sample image is an uncertain sample.

[0088] In one embodiment of the present invention, for step S304 and step S305, in order to further improve the computational efficiency and accuracy of data fusion, before determining the predicted data participating in data fusion based on the intersection-and-union ratio threshold, the conditions of the predicted data participating in data fusion can be further limited. Specifically, before comparing the intersection-and-union ratio of the predicted data with the intersection-and-union ratio threshold, the number of models with the first prediction box in multiple target teacher models can be obtained. If the number of models is small and less than the preset number threshold, it means that this sample image is difficult to predict, and the sample image can be determined as an uncertain sample. If the number of models is greater than or equal to the preset number threshold, it means that this sample image is a normal sample, and the intersection-and-union ratio of the predicted data of the sample image can be further compared with the intersection-and-union ratio threshold. Through this limiting method, the number of uncertain samples can be further reduced in advance, and the predicted data of all sample images do not need to participate in data fusion, which greatly improves the screening efficiency. It should be noted that the above-mentioned number threshold can be set based on the number of all target teacher models and the actual screening requirements, such as 2, 3 or other thresholds. When the screening requirements are high, the number threshold can be set higher, and the sample images less than the number threshold are all determined as uncertain samples. When the screening requirements are low, the quantity threshold can be set lower.

[0089] In summary, the present invention provides a data screening method, which comprehensively considers the prediction boxes of multiple target detection models and the confidence of the prediction boxes, and can quickly and accurately screen out uncertain samples with inaccurate predictions.

[0090] See also Figure 6 , Figure 1 The structural diagram of a data screening device provided by the present invention is shown. The data screening device can be set on the server side 10, and can include a data acquisition module 11, a model detection module 12 and a data screening module 13. The data acquisition module 11 can be used to obtain a sample data set from the image acquisition terminal 20. The model detection module 12 can be used to input the sample images in the sample data set into a plurality of preset target detection models respectively to obtain a plurality of output prediction data. Among them, the prediction data includes a prediction box and the confidence of the prediction box. The data screening module 13 can be used to perform data fusion on the prediction boxes and confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion, and the image type includes an uncertain sample and a determined sample.

[0091] In one embodiment of the present invention, the model detection module 12 can be specifically used to input the sample images in the sample data set into multiple target teacher models respectively to obtain multiple first prediction data as output, wherein the multiple first prediction data correspond to the multiple target teacher models respectively, and the first prediction data includes a first prediction box and a first confidence of the first prediction box. Input the sample images in the sample data set into the target student model to obtain the second prediction data as output, and the second prediction data includes a second prediction box and a second confidence of the second prediction box.

[0092] In one embodiment of the present invention, the model detection module 12 can also be specifically used to construct multiple initial teacher models, train the multiple initial teacher models based on a preset training image set, and generate multiple target teacher models. And construct an initial student model, train the initial student model based on the training image set, and generate a target student model.

[0093] In one embodiment of the present invention, the data screening module 13 can also be specifically used to perform data fusion on multiple first prediction boxes, second prediction boxes, first confidences and second confidences corresponding to the sample image to generate an uncertainty index. And determine whether the uncertainty index is greater than or equal to a preset uncertainty threshold. If it is greater than or equal to the uncertainty threshold, the image type of the sample image is determined to be an uncertain sample. If it is less than the uncertainty threshold, the image type of the sample image is determined to be a certain sample. The uncertainty index can be expressed as U, io k represents the intersection-over-union ratio between the first prediction box corresponding to the K-th target teacher model and the second prediction box corresponding to the target student model, score k Represents the first confidence of the first prediction box corresponding to the K-th target teacher model, K is a positive integer, score s Represents the second confidence of the second prediction box corresponding to the target student model. n t Represents the number of target teacher models whose IoU ratio between the first prediction box and the second prediction box is greater than or equal to the IoU threshold.

[0094] In one embodiment of the present invention, the data screening module 13 can also be specifically used to determine in turn whether the intersection-and-union ratio between each first prediction box and the second prediction box is greater than or equal to a preset intersection-and-union ratio threshold. If there is at least one intersection-and-union ratio between the first prediction box and the second prediction box that is less than the intersection-and-union ratio threshold, the image type of the sample image is determined to be an uncertain sample. If the intersection-and-union ratio between each first prediction box and the second prediction box is greater than or equal to the intersection-and-union ratio threshold, data fusion is performed on the prediction boxes and confidences of the multiple prediction data to determine the image type of the sample image based on the result of the data fusion.

[0095] In one embodiment of the present invention, the data screening module 13 can also be specifically used to obtain the model number of the target teacher model in which the first prediction box exists in the first prediction data. It is determined whether the model number is greater than or equal to a preset number threshold. If it is greater than or equal to the number threshold, it is further determined whether the intersection and union ratio between each first prediction box and the second prediction box is greater than or equal to the intersection and union ratio threshold. If it is less than the number threshold, it is determined that the image type of the sample image is an uncertain sample.

[0096] The data screening device provided in the embodiment of the present application can implement each process of the above-mentioned data screening method embodiment, and will not be described again here to avoid repetition.

[0097] In one embodiment of the present invention, the present application also provides an electronic device, including a memory and a processor, the memory stores a computer program, and when the processor executes the computer program, the various processes of the above-mentioned data screening method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0098] In one embodiment of the present invention, the present application also provides a computer-readable storage medium on which a computer program is stored. When the computer program is executed by a processor, the various processes of the above-mentioned data screening method embodiment are implemented and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0099] Through the description of the above implementation methods, those skilled in the art can clearly understand that each implementation method can be implemented by means of software plus a necessary general hardware platform, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solution is essentially or the part that contributes to the prior art can be embodied in the form of a software product, and the computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment or some parts of the embodiments.

[0100] The embodiments of the present invention disclosed above are only used to help illustrate the present invention. The embodiments do not describe all the details in detail, nor do they limit the invention to the specific embodiments described. Obviously, many modifications and changes can be made according to the content of this specification. This specification selects and specifically describes these embodiments in order to better explain the principles and practical applications of the present invention, so that those skilled in the art can understand and use the present invention well. The present invention is limited only by the claims and their full scope and equivalents.

Claims

1. A data screening method, characterized in that: include: Acquire a sample data set, wherein the sample data set includes a sample image; Inputting the sample images in the sample data set into a plurality of preset target detection models respectively to obtain a plurality of output prediction data, wherein the plurality of prediction data respectively correspond to the plurality of target detection models, and the prediction data include a prediction box and a confidence level of the prediction box; Data fusion is performed on the prediction frames and the confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion, wherein the image type includes an uncertain sample and a determined sample.

2. A data screening method according to claim 1, characterized in that: The multiple target detection models include multiple target teacher models and target student models. The step of inputting the sample images in the sample data set into the preset multiple target detection models to obtain the output multiple prediction data includes: Inputting the sample images in the sample data set into the plurality of target teacher models respectively to obtain a plurality of first prediction data as output, wherein the plurality of first prediction data respectively correspond to the plurality of target teacher models, and each of the first prediction data includes a first prediction box and a first confidence of the first prediction box; A sample image in the sample data set is input into the target student model to obtain output second prediction data, where the second prediction data includes a second prediction box and a second confidence level of the second prediction box.

3. A data screening method according to claim 2, characterized in that: The step of fusing the prediction frames and confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion comprises: Performing data fusion on a plurality of the first prediction boxes, the second prediction boxes, the first confidence levels, and the second confidence levels corresponding to the sample image to generate an uncertainty indicator; Determine whether the uncertainty index is greater than or equal to a preset uncertainty threshold. If so, determine that the image type of the sample image is an uncertain sample. If so, determine that the image type of the sample image is a determined sample.

4. A data screening method according to claim 2, characterized in that: Before the step of fusing the prediction frames and confidences of the plurality of prediction data to determine the image type of the sample image based on the result of the data fusion, the method further includes: Determine in sequence whether an intersection-and-union ratio between each of the first prediction boxes and the second prediction boxes is greater than or equal to a preset intersection-and-union ratio threshold; If there is at least one intersection-and-union ratio between the first prediction box and the second prediction box that is smaller than the intersection-and-union ratio threshold, determining that the image type of the sample image is an uncertain sample; If the intersection-and-union ratio between each of the first prediction boxes and the second prediction boxes is greater than or equal to the intersection-and-union ratio threshold, data fusion is performed on the prediction boxes and confidences of the multiple prediction data to determine the image type of the sample image based on the result of the data fusion.

5. A data screening method according to claim 4, characterized in that: Before the step of determining whether the intersection-and-union ratio between each of the first prediction frame and the second prediction frame is greater than or equal to the intersection-and-union ratio threshold, the method further includes: Obtaining the model number of the target teacher model having the first prediction box in the first prediction data; Determine whether the number of models is greater than or equal to a preset number threshold; if so, continue to determine whether the intersection-and-union ratio between each of the first prediction box and the second prediction box is greater than or equal to the intersection-and-union ratio threshold; if less than the number threshold, determine that the image type of the sample image is an uncertain sample.

6. A data screening method according to claim 2, characterized in that: Before the step of inputting the sample images in the sample data set into the preset multiple target detection models to obtain the output multiple prediction data, the method further includes: Constructing multiple initial teacher models, and training the multiple initial teacher models respectively based on a preset training image set to generate multiple target teacher models; An initial student model is constructed, and the initial student model is trained based on the training image set to generate the target student model.

7. A data screening method according to claim 6, characterized in that: The step of constructing a plurality of initial teacher models and training the plurality of initial teacher models respectively based on a preset training image set to generate a plurality of target teacher models comprises: Constructing a plurality of the initial teacher models, and setting model parameters of the initial teacher models based on the target detection scenario to generate a plurality of rotation target detection models; The plurality of rotated object detection models are trained based on the training image set to generate a plurality of target teacher models.

8. A data screening device, characterized in that: include: A data acquisition module, used to acquire a sample data set, wherein the sample data set includes a sample image; A model detection module, used for inputting the sample images in the sample data set into a plurality of preset target detection models respectively to obtain a plurality of output prediction data, wherein the plurality of prediction data respectively correspond to the plurality of target detection models, and the prediction data include a prediction box and a confidence level of the prediction box; The data screening module is used to perform data fusion on the prediction boxes and confidences of the multiple prediction data to determine the image type of the sample image based on the result of the data fusion, and the image type includes an uncertain sample and a determined sample.

9. An electronic device, characterized in that: The method comprises a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the data screening method according to any one of claims 1 to 7 are implemented.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the data screening method according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Method and device for screening difficult sample data

    CN112149698A

  • Label-free knowledge distillation method based on multi-target detection model and storage medium

    CN113610126A

  • Uncertain sample detection method and device in defect detection and medium

    CN114092472A

  • Target detection method and device based on improved target detection frame

    CN115761214A

  • Remote sensing image ship detection method and system based on rotating target detection model

    CN116310860A