License plate and face detection method and device and related equipment

Through a unified license plate and face detection method, the feature extraction model and confidence value are used to screen target objects, which solves the computing power consumption problem caused by the independent license plate and face detection models in the existing technology, and achieves efficient detection in vehicles. and data desensitization.

CN118570784APending Publication Date: 2024-08-30BEIJING CO WHEELS TECH CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202310215277.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-02-28
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

The existing license plate and face detection models are two independent detection models, which require a lot of computing power in smart cars. They are not suitable for deployment in vehicles and cannot effectively decouple face and license plate data from car transmission images. Min's request.

Method used

Using a unified license plate and face detection method, the image is sampled and processed to generate a feature image and input into the feature extraction model to output the target object features, including detection frame centrality, width and height regression values ​​and classification scores, combined with confidence The degree value filters the target pixels and determines the target objects, including license plates and faces.

Benefits of technology

It saves the computing resources of vehicle-mounted terminals, facilitates deployment in vehicles, meets the requirements for desensitizing face and license plate data in vehicle transmission images, and improves detection efficiency and accuracy.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118570784A
    Figure CN118570784A
Patent Text Reader

Abstract

The invention discloses a license plate and face detection method and device and related equipment. The method comprises: acquiring a second image; sampling the second image to obtain a feature image; the feature image is input into a feature extraction model, target object features are output, the target object features comprise detection frame centrality, detection frame width and height regression values and detection frame classification scores of all pixel points, and the feature extraction model comprises a license plate feature extraction sub-model and a face feature extraction sub-model; processing the detection frame centrality and the detection frame classification score of each pixel point based on a confidence coefficient determination strategy, and determining a confidence coefficient value of each pixel point; target pixel points are screened from the pixel points based on the confidence value, the detection frame height regression value and the target pixel points are processed based on an object determination strategy to obtain target objects, and the target objects comprise at least one of a license plate and a human face.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of vehicle technology, and in particular, relates to a license plate and face detection method, device and related equipment. Background Art

[0002] With the development of automobile intelligence, data desensitization has gradually become a consensus in the industry on automobile data security. The so-called data desensitization refers to the use of data deformation to reduce the sensitivity of data in the process of processing sensitive data, so as to achieve the purpose of protecting user personal information. In layman's terms, it means hiding or blurring sensitive information, and only retaining some non-directional regular data so that data thieves cannot identify it.

[0003] Currently, in the smart car industry, in order to meet the requirements of desensitizing facial and license plate data in images transmitted by cars, the vehicle side needs to accurately find faces and license plates. However, the existing license plate and face detection are two independent detection models, which require a lot of computing power and are not convenient to deploy in vehicles. Summary of the invention

[0004] The embodiments of the present application provide a license plate and face detection method, device and related equipment, which can save the computing power of the vehicle-mounted terminal and be conveniently deployed in the vehicle, thereby meeting the requirements for desensitizing the face and license plate data in the images transmitted by the car.

[0005] In a first aspect, an embodiment of the present application provides a method for detecting a license plate and a face, comprising:

[0006] Acquire a second image, where the second image satisfies the target size and includes at least one license plate or a face;

[0007] Performing sampling processing on the second image to obtain a feature image;

[0008] Input the feature image into a feature extraction model, and output the target object features, wherein the target object features include the detection frame center of each pixel, the detection frame width and height regression value, and the detection frame classification score, wherein the feature extraction model is trained based on the historical feature image and the detection frame center of each pixel in the historical feature image, the detection frame width and height regression value, and the detection frame classification score, and the feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model;

[0009] Based on the confidence determination strategy, the detection frame center and the detection frame classification score of each pixel point are processed to determine the confidence value of each pixel point;

[0010] Filter target pixel points from the pixel points based on the confidence value, and process the detection frame height regression value and the target pixel points based on an object determination strategy to obtain a target object, wherein the target object includes at least one of the license plate and the face.

[0011] In a second aspect, an embodiment of the present application provides a license plate and face detection device, comprising:

[0012] An acquisition module, used to acquire a second image, where the second image meets the target size and includes at least one license plate or a face image;

[0013] A processing module, used for performing sampling processing on the second image to obtain a feature image;

[0014] A feature extraction module is used to input the feature image into a feature extraction model and output target object features, wherein the target object features include the detection frame center degree, detection frame width and height regression value, and detection frame classification score of each pixel point, wherein the feature extraction model is trained based on the historical feature image and the detection frame center degree, detection frame width and height regression value, and detection frame classification score of each pixel point in the historical feature image, and the feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model;

[0015] A first determination module is used to process the detection box center and the detection box classification score of each pixel point based on a confidence determination strategy to determine the confidence value of each pixel point;

[0016] The second determination module is used to filter target pixel points from the pixel points based on the confidence value, and process the detection frame height regression value and the target pixel points based on the object determination strategy to obtain a target object, wherein the target object includes at least one of the license plate and the face.

[0017] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, it implements the license plate and face detection method as described in any one of the above.

[0018] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium having computer program instructions stored thereon. When the computer program instructions are executed by a processor, the license plate and face detection method as described in any one of the above items is implemented.

[0019] In a fifth aspect, an embodiment of the present application provides a vehicle, comprising: an electronic device, wherein the electronic device is used to implement the license plate and face detection method as described in any one of the above.

[0020] The license plate and face detection method, device and related equipment of the embodiment of the present application can sample and process the second image collected by the vehicle, and the obtained feature image is input into the feature extraction model to output the target object feature, the target object feature includes the detection frame center of each pixel, the detection frame width and height regression value and the detection frame classification score, the feature extraction model is trained based on the historical feature image and the detection frame center of each pixel in the historical feature image, the detection frame width and height regression value and the detection frame classification score, the feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model, and finally traverses each pixel in the feature image, and when the confidence value of the target pixel is greater than the first threshold, the target object is determined based on the target pixel and the detection frame width and height regression value of the target pixel, the target pixel is any pixel in the feature image, and the target object includes at least one of the license plate and the face. In this way, the second image is uniformly sampled and processed in this embodiment, and then input into the corresponding license plate or face feature extraction sub-model, which can save the computing power of the vehicle terminal and is convenient to be deployed in the vehicle, thereby meeting the requirements for desensitizing the face and license plate data in the image transmitted by the car. BRIEF DESCRIPTION OF THE DRAWINGS

[0021] In order to more clearly illustrate the technical solution of the embodiments of the present application, the following is a brief introduction to the drawings required for use in the embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without any creative work.

[0022] Figure 1 It is a flowchart of a license plate and face detection method provided in an embodiment of the present application;

[0023] Figure 2 It is a schematic diagram of the structure of the convolutional neural network model provided in the embodiment of the present application;

[0024] Figure 3 It is a structural schematic diagram of a license plate and face detection device provided in an embodiment of the present application;

[0025] Figure 4 It is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0026] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.

[0027] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.

[0028] With the development of automobile intelligence, data desensitization has gradually become a consensus in the industry on automobile data security. The so-called data desensitization refers to the use of data deformation to reduce the sensitivity of data in the process of processing sensitive data, so as to achieve the purpose of protecting user personal information. In layman's terms, it means hiding or blurring sensitive information, and only retaining some non-directional regular data so that data thieves cannot identify it.

[0029] Currently, in the smart car industry, in order to meet the requirements of desensitizing facial and license plate data in images transmitted by cars, the vehicle side needs to accurately find faces and license plates. However, the existing license plate and face detection are two independent detection models, which require a lot of computing power and are not convenient to deploy in vehicles.

[0030] In order to solve the problems in the prior art, the embodiments of the present application provide a license plate and face detection method, apparatus and related equipment. The license plate and face detection method provided by the embodiments of the present application is first introduced below.

[0031] Figure 1 FIG. 1 is a flow chart of a license plate and face detection method provided by an embodiment of the present application. Figure 1 As shown, a method for detecting a license plate and a human face is applied to a vehicle-mounted terminal, and the method includes the following steps S101 to S105.

[0032] S101. Acquire a second image, where the second image meets a target size and includes at least one license plate or a human face.

[0033] S102: Perform sampling processing on the second image to obtain a feature image.

[0034] S103. Input the feature image into the feature extraction model and output the target object features. The target object feature image includes the detection frame center degree, detection frame width and height regression value and detection frame classification score of each pixel. The feature extraction model is trained based on the historical feature image and the detection frame center degree, detection frame width and height regression value and detection frame classification score of each pixel in the historical feature image. The feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model.

[0035] S104: Process the detection box center and the detection box classification score of each pixel based on the confidence determination strategy to determine the confidence value of each pixel.

[0036] S105. Filter target pixels from the pixels based on the confidence value, and process the detection frame height regression value and the target pixels based on the object determination strategy to obtain a target object, wherein the target object includes at least one of a license plate and a face.

[0037] The license plate and face detection method of the embodiment of the present application can sample and process the second image collected by the vehicle, and the obtained feature image is input into the feature extraction model to output the target object feature, the target object feature includes the detection frame center of each pixel point, the detection frame width and height regression value and the detection frame classification score, the feature extraction model is based on the historical feature image and the detection frame center of each pixel point in the historical feature image, the detection frame width and height regression value and the detection frame classification score training, the feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model, and finally traverses each pixel point in the feature image, and when the confidence value of the target pixel point is greater than the first threshold, the target object is determined based on the target pixel point and the detection frame width and height regression value of the target pixel point, the target pixel point is any pixel point in the feature image, and the target object includes at least one of the license plate and the face. In this way, the second image is uniformly sampled and processed in this embodiment, and then input into the corresponding license plate or face feature extraction sub-model, which can save the computing power of the vehicle terminal and is convenient to be deployed in the vehicle, thereby meeting the requirements for desensitizing the face and license plate data in the image transmitted by the car.

[0038] The above license plate and face detection methods are mainly applied to vehicle terminals. This application is not limited to this, and can also be a terminal device with data processing capabilities such as a vehicle central control system or a cloud server.

[0039] The specific implementation methods of the above steps are introduced below.

[0040] In S101, the second image may be a second image meeting the target size captured by a vehicle-mounted camera; or, the second image may be a first image including at least one license plate or face captured by the vehicle-mounted camera, and the first image is reduced to the target size to obtain the second image.

[0041] In some embodiments, the above S101, obtaining the second image, may be to reduce the at least one first image captured to a target size to obtain the second image. The first image may be a panoramic image captured by the vehicle through at least one vehicle-mounted camera, wherein the panoramic image includes a license plate and facial information. The size of the first image is relatively large, for example, 4K or 8K resolution, which is not limited to this in this embodiment and is not specifically limited here.

[0042] The first image is reduced to a target size to obtain the second image. For example, the first image of 4K size can be reduced to a target size (for example, a resolution of 480*256) to obtain the second image. It should be noted that the target size is not limited to a resolution of 480*256, but can also be other values ​​smaller than the resolution of the first image.

[0043] In S102, the characteristic image includes a first characteristic image.

[0044] In some embodiments, the above S102 may specifically include:

[0045] Performing multiple downsampling processes on the second image to obtain multiple downsampled images, where different downsampled images correspond to different sampling multiples;

[0046] Performing upsampling processing on the first downsampled image to obtain a first upsampled image, wherein the first downsampled image is a downsampled image with a maximum sampling multiple among the multiple downsampled images;

[0047] The first up-sampled image and the second down-sampled image are added to obtain a first feature image, wherein the second down-sampled image is a down-sampled image with the same sampling multiple as the first up-sampled image among the multiple down-sampled images.

[0048] The above-mentioned downsampling process, i.e. reducing the image, or downsampling, has two main purposes: 1. making the image fit the size of the display area; 2. generating a thumbnail of the corresponding image. Taking an image I of size MN as an example to illustrate the principle of downsampling, image I is downsampled s times, that is, a resolution image of size (M / s)(N / s) is obtained, where s is the common divisor of M and N. If the image is in matrix form, the image in the s*s window of the original image is converted into a pixel, and the value of this pixel is the mean of all pixels in the window.

[0049] The above-mentioned upsampling process, i.e., image enlargement, or image interpolation, is mainly aimed at enlarging the original image so that it can be displayed on a display device with a higher resolution. Image enlargement is almost always performed using the interpolation method, i.e., inserting new elements between pixels based on the original image pixels using a suitable interpolation algorithm.

[0050] The second image is downsampled multiple times to obtain multiple downsampled images. For example, the second image may be downsampled five times to obtain five downsampled images, namely, a 2-fold downsampled image, a 4-fold downsampled image, an 8-fold downsampled image, a 16-fold downsampled image, and a 32-fold downsampled image. The higher the multiple, the smaller the image.

[0051] The first multiple mentioned above can be, for example, a sampling multiple of 4. Of course, it is not limited thereto, and can also be other set values, which are not specifically limited here.

[0052] In this embodiment, downsampling the image can reduce the amount of data processing while retaining the extracted features, and then upsampling the downsampled image and adding it to the second downsampled image to obtain a first feature image. In this way, the first feature image has the features extracted from the first downsampled image and the features extracted from the second downsampled image, thereby improving the accuracy of the license plate frame center degree, license plate frame width and height regression value and license plate frame classification score output by the license plate feature extraction submodel.

[0053] In S103, the Bbox Centerness is used to indicate the determination of the centrality of the pixel relative to the detection box. For example, the dimension of Bbox centerness may be (n, 1, h, w), where n represents the nth first image in at least one first image, 1 represents that the pixel is the center of the detection box (if the pixel is not the center of the detection box, 0 is used), h represents the height of the feature image, and w represents the width of the feature image.

[0054] The above detection box width and height regression value (Bbox Regression, Bbox reg) is used to predict the distance from the pixel to the four upper, lower, left and right boundaries of the detection box. Exemplarily, the dimension of Bbox reg is (n, 4, h, w), where n / h / w has the same meaning as in the above Bbox centerness, and will not be repeated here. The 4-dimensional represents the distance from the pixel to the four upper, lower, left and right boundaries of the detection box, which can be represented as (l, t, r, b).

[0055] The above detection box classification score (Bbox Classification Score, Bbox cls) represents the classification score of the predicted pixel as the target object. Exemplarily, the dimension of Bbox cls is (n, 2, h, w), where n / h / w have the same meaning as in the above Bbox centerness, and will not be repeated here. The 2-dimensional representation represents whether the pixel is the target object, where 1 is used to represent the pixel as the target object, and 0 is used to represent the pixel as not being the target object.

[0056] The above feature extraction model is trained based on the historical feature image and the detection frame center degree, detection frame width and height regression value and detection frame classification score of each pixel in the historical feature image.

[0057] Since the features of faces and license plates are different and cannot be shared, the above-mentioned feature extraction model may include a license plate feature extraction sub-model and a face feature extraction sub-model.

[0058] In some embodiments, the above S103 may specifically include:

[0059] When the sampling multiple of the first feature image is greater than or equal to the first multiple, the first feature image is input into the license plate feature extraction sub-model, and the license plate frame center degree, license plate frame width and height regression value and license plate frame classification score of each pixel in the first feature image are output. The above license plate feature extraction sub-model is trained based on the historical feature image and the license plate frame center degree, license plate frame width and height regression value and license plate frame classification score of each pixel in the historical feature image.

[0060] In this embodiment, when the sampling multiple of the first feature image is greater than or equal to the first multiple, the first feature image is input into the license plate feature extraction sub-model, which can accurately identify the license plate frame center degree, license plate frame width and height regression value and license plate frame classification score.

[0061] In some embodiments, since a human face is smaller than a license plate, in order to accurately extract the facial features in the first feature image, the first feature image may be upsampled. The feature image also includes a second feature image. Before the above S103, the following may also be included:

[0062] Performing upsampling processing on the first feature image to obtain a second upsampling image;

[0063] The second up-sampled image and the third down-sampled image are added to obtain a second feature image, wherein the third down-sampled image is a down-sampled image with the same sampling multiple as the second up-sampled image among the multiple down-sampled images, and the sampling multiple of the second feature image is smaller than the sampling multiple of the first feature image;

[0064] The above S103 may include:

[0065] When the sampling multiple of the second feature image is greater than or equal to the second multiple, the second feature image is input into the face feature extraction sub-model, and the face frame center degree, face frame width and height regression value and face frame classification score of each pixel point in the second feature image are output. The face feature extraction sub-model is trained based on the historical feature image and the face frame center degree, face frame width and height regression value and face frame classification score of each pixel point in the historical feature image.

[0066] The second multiple, for example, may be a sampling multiple of 2. Of course, it is not limited thereto, and may also be other set values, as long as the second multiple is smaller than the first multiple, and no specific limitation is made here.

[0067] In this embodiment, since the face is smaller than the license plate, the first feature image is upsampled, and the second upsampled image is added to the third downsampled image to obtain the second feature image, which is input into the face feature extraction sub-model to accurately obtain the face frame center, face frame width and height regression value and face frame classification score.

[0068] In S104, the confidence value of each pixel is the product of the detection box center of each pixel and the detection box classification. In statistics, the confidence interval of a probability sample is an interval estimate of a population parameter of the sample. The confidence interval shows the degree to which the true value of the parameter has a certain probability of falling around the measurement result.

[0069] The above confidence-based determination strategy processes the detection box center and the detection box classification score of each pixel to determine the confidence value of each pixel. Specifically, the detection box center of each pixel is multiplied by the detection box classification score to determine the confidence value of each pixel.

[0070] In S105, the target pixel is selected from the pixels based on the confidence value, and the detection frame height regression value and the target pixel are processed based on the object determination strategy to obtain the target object. When the confidence value of the target pixel is greater than the first threshold, the target pixel is added to the detection frame width and height regression value of the target pixel to determine the target object. The target pixel is any pixel in the feature image. The first threshold can be a value set according to user needs, not limited to a fixed value, but can also be other values, which are not specifically limited here.

[0071] In some embodiments, the above S105 may specifically include:

[0072] When the confidence value of the target pixel is greater than the first threshold, determining that a target object exists at the position of the target pixel;

[0073] The target object is determined based on the target pixel and the width and height regression value of the detection box of the target pixel.

[0074] The target object is determined based on the target pixel point and the detection box width and height regression value of the target pixel point. For example, the coordinates of the target pixel point (x, y) are added to the detection box width and height regression value of the target pixel point (l, t, r, b) to determine that the detection box bbox of the target object is [x+l, y+t, x+r, y+b], and the target object is within the detection box.

[0075] In this embodiment, when the confidence value of the target pixel is greater than the first threshold, it means that there is a target object at the position of the target pixel, and then based on the target pixel and the detection frame width and height regression value of the target pixel, the target object is accurately determined.

[0076] As an implementation of the present application, in order to filter duplicate target objects, after the above S104, the following is further included:

[0077] Calculating a difference between a center degree of a detection frame of a first target object and a center degree of a detection frame of a second target object to obtain a center degree difference, wherein the first target object and the second target object are any two adjacent target objects among the plurality of target objects;

[0078] When the center degree difference is less than or equal to the second threshold, determining that the first target object and the second target object are two repeated target objects;

[0079] In a case where the confidence value of the first target object is greater than the confidence value of the second target object, the first target object is determined to be a valid object.

[0080] In the above case, when the confidence value of the first target object is greater than the confidence value of the second target object, the first target object is determined as a valid object. Specifically, when the confidence value of the first target object is greater than the confidence value of the second target object, the first target object is determined as a valid object and the second target object is deleted.

[0081] In this embodiment, when the center difference is less than or equal to the second threshold, the first target object and the second target object are determined to be two duplicate target objects, the first target object with a larger confidence value is determined to be a valid object, and the second target object with a smaller confidence value is deleted, thereby filtering out duplicate target objects.

[0082] In order to facilitate the understanding of the license plate and face detection method in the embodiment of the present application, the application process of the license plate and face detection method is described here, as follows:

[0083] The embodiment of the present application provides a license plate and face detection method, which is applied to a vehicle-mounted terminal, and the specific steps are as follows:

[0084] 1. Input the original image (i.e. the first image).

[0085] 2. The size of the original input image is very large and needs to be scaled down to a resolution of (480, 256).

[0086] 3. Input into the convolutional neural network model, the model structure is as follows Figure 2As shown, the face feature extraction sub-model is detected on the feature image with a 2-fold downsampling multiple of the input, and the license plate feature extraction sub-model is detected on the feature image with a 4-fold downsampling multiple of the input.

[0087] 4. The facial feature extraction sub-model includes a face box centerness extraction module, a face box width and height regression value extraction module, and a face box classification score extraction module, which has three corresponding outputs: face bbox centerness, face bbox width and height regression value face bbox reg, and face bbox classification score face bbox cls.

[0088] 5. Similarly, the license plate feature extraction sub-model includes a license plate frame centrality extraction module, a license plate frame width and height regression value extraction module, and a license plate frame classification score extraction module, corresponding to three outputs, license plate frame centrality plate bboxcenterness, license plate frame width and height regression value plate bbox reg, and license plate frame classification score plate bbox cls.

[0089] 6. Among them, the dimension of Bbox reg is (n, 4, h, w); the dimension of Bbox cls is (n, 2, h, w); the dimension of Bboxcenterness is (n, 1, h, w).

[0090] 7. Take face detection as an example to illustrate. Traverse each pixel in the feature image. Assume that the coordinates of each pixel are (x, y). Calculate the confidence value of bbox cls[x, y]*bbox centerness[x, y] to determine whether it is greater than the set threshold. If it is greater than the set threshold, it is considered that there is a target object at the pixel position. Otherwise, continue to traverse the pixel at the next position. If the position is a target, take the value on the feature map output by bbox reg to get bbox_reg[x, y], which can be represented as (l, t, r, b)

[0091] 8. Determine the face bbox of the final model output: [x+l, y+t, x+r, y+b]. The method for processing license plate output is the same as that for human face, so it will not be repeated here.

[0092] 9. Filter the face detection results and license plate detection results, delete duplicate results (i.e. duplicate target objects), and retain valid results (i.e. valid objects).

[0093] Based on the license plate and face detection methods provided in the above embodiments, the present application also provides specific implementations of license plate and face detection devices. Please refer to the following embodiments.

[0094] like Figure 3 As shown, a license plate and face detection device 300 provided in an embodiment of the present application is applied to a vehicle-mounted terminal. The device 300 may include the following modules: an acquisition module 301, a processing module 302, a feature extraction module 303, a first determination module 304 and a second determination module 305.

[0095] The acquisition module 301 is used to acquire a second image, where the second image meets the target size and includes at least one license plate or a face.

[0096] The processing module 302 is used to perform sampling processing on the second image to obtain a feature image.

[0097] The feature extraction module 303 is used to input the feature image into the feature extraction model and output the target object features. The target object feature image includes the detection frame center degree, detection frame width and height regression value and detection frame classification score of each pixel point. The feature extraction model is trained based on the historical feature image and the detection frame center degree, detection frame width and height regression value and detection frame classification score of each pixel point in the historical feature image. The feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model.

[0098] The first determination module 304 is used to process the detection box center degree and the detection box classification score of each pixel point based on the confidence determination strategy to determine the confidence value of each pixel point.

[0099] The second determination module 305 is used to filter target pixels from the pixels based on the confidence value, and process the detection frame height regression value and the target pixel to obtain the target object based on the object determination strategy, wherein the target object includes at least one of a license plate and a face.

[0100] The license plate and face detection device of the embodiment of the present application can sample and process the second image collected by the vehicle, and the obtained feature image is input into the feature extraction model to output the target object feature, the target object feature includes the detection frame center of each pixel point, the detection frame width and height regression value and the detection frame classification score, the feature extraction model is based on the historical feature image and the detection frame center of each pixel point in the historical feature image, the detection frame width and height regression value and the detection frame classification score training, the feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model, and finally traverses each pixel point in the feature image, and when the confidence value of the target pixel point is greater than the first threshold, the target object is determined based on the target pixel point and the detection frame width and height regression value of the target pixel point, the target pixel point is any pixel point in the feature image, and the target object includes at least one of a license plate and a face. In this way, the second image is uniformly sampled and processed in this embodiment, and then input into the corresponding license plate or face feature extraction sub-model, which can save the computing power of the vehicle terminal and is convenient to be deployed in the vehicle, thereby meeting the requirements for desensitizing the face and license plate data in the image transmitted by the car.

[0101] In some embodiments, the feature image includes a first feature image;

[0102] The processing module 302 may specifically include:

[0103] A first processing unit is used to perform multiple downsampling processes on the second image to obtain multiple downsampled images, where different downsampled images correspond to different sampling multiples;

[0104] A second processing unit is used to perform upsampling processing on the first downsampled image to obtain a first upsampled image, where the first downsampled image is a downsampled image with a maximum sampling multiple among the multiple downsampled images;

[0105] The third processing unit is used to add the first up-sampled image and the second down-sampled image to obtain a first feature image, where the second down-sampled image is a down-sampled image with the same sampling multiple as the first up-sampled image among the multiple down-sampled images.

[0106] In some embodiments, the feature extraction module 303 may specifically include:

[0107] The license plate feature extraction unit is used to input the first feature image into the license plate feature extraction sub-model when the sampling multiple of the first feature image is greater than or equal to the first multiple, and output the license plate frame centrality, license plate frame width and height regression value and license plate frame classification score of each pixel point in the first feature image. The license plate feature extraction sub-model is trained based on the historical feature image and the license plate frame centrality, license plate frame width and height regression value and license plate frame classification score of each pixel point in the historical feature image.

[0108] In some embodiments, since a human face is smaller than a license plate, in order to accurately extract the facial features in the first feature image, the first feature image may be upsampled. The feature image also includes a second feature image. The processing module 302 may further include:

[0109] A fourth processing unit, configured to perform upsampling processing on the first feature image to obtain a second upsampling image;

[0110] The fifth processing unit is used to add the second up-sampled image and the third down-sampled image to obtain a second feature image, where the third down-sampled image is a down-sampled image with the same sampling multiple as the second up-sampled image among multiple down-sampled images, and the sampling multiple of the second feature image is smaller than the sampling multiple of the first feature image.

[0111] The feature extraction module 303 may include:

[0112] The facial feature extraction unit is used to input the second feature image into the facial feature extraction sub-model when the sampling multiple of the second feature image is greater than or equal to the second multiple, and output the facial frame center degree, facial frame width and height regression value and facial frame classification score of each pixel point in the second feature image. The facial feature extraction sub-model is trained based on the historical feature image and the facial frame center degree, facial frame width and height regression value and facial frame classification score of each pixel point in the historical feature image.

[0113] In some embodiments, the second determining module 305 may specifically include:

[0114] A first determining unit, configured to determine that a target object exists at a position where the target pixel point is located when the confidence value of the target pixel point is greater than a first threshold;

[0115] The second determining unit is used to determine the target object based on the target pixel point and the detection frame width and height regression value of the target pixel point.

[0116] As an implementation of the present application, in order to filter duplicate target objects, the above-mentioned device 300 may further include:

[0117] a calculation module, configured to calculate a difference between a center degree of a detection frame of a first target object and a center degree of a detection frame of a second target object to obtain a center degree difference, wherein the first target object and the second target object are any two adjacent target objects among the plurality of target objects;

[0118] A third determination module is used to determine that the first target object and the second target object are two duplicate target objects when the center difference is less than or equal to a second threshold;

[0119] The fourth determination module is used to determine the first target object as a valid object when the confidence value of the first target object is greater than the confidence value of the second target object.

[0120] Based on the license plate and face detection methods provided in the above embodiments, the present application also provides a specific implementation of the electronic device. Please refer to the following embodiments.

[0121] In some embodiments, acquiring the second image may specifically include:

[0122] An acquisition unit is used to acquire a first image, where the first image is an image including at least one license plate or a human face.

[0123] The reduction unit is used to reduce the first image to a target size to obtain a second image.

[0124] Figure 4 A schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application is shown.

[0125] The electronic device may include a processor 401 and a memory 402 storing computer program instructions.

[0126] Specifically, the processor 401 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiments of the present application.

[0127] Memory 402 may include a large capacity memory for data or instructions. By way of example and not limitation, memory 402 may include a hard disk drive (HDD), a floppy disk drive, a flash memory, an optical disk, a magneto-optical disk, a magnetic tape, or a universal serial bus (USB) drive or a combination of two or more of these. In appropriate cases, memory 402 may include a removable or non-removable (or fixed) medium. In appropriate cases, memory 402 may be inside or outside of an integrated gateway disaster recovery device. In a specific embodiment, memory 402 is a non-volatile solid-state memory.

[0128] In certain embodiments, the memory 402 may include a read-only memory (ROM), a random access memory (RAM), a magnetic disk storage media device, an optical storage media device, a flash memory device, an electrical, optical or other physical / tangible memory storage device. Thus, in general, the memory includes one or more tangible (non-transitory) computer-readable storage media (e.g., a memory device) encoded with software including computer-executable instructions, and when the software is executed (e.g., by one or more processors), it is operable to perform the operations described with reference to the method according to an aspect of the present disclosure.

[0129] The processor 401 implements any one of the license plate and face detection methods in the above embodiments by reading and executing computer program instructions stored in the memory 402 .

[0130] In one example, the electronic device may further include a communication interface 403 and a bus 410. Figure 4 As shown, the processor 401, the memory 402, and the communication interface 403 are connected via a bus 410 and communicate with each other.

[0131] The communication interface 403 is mainly used to implement communication between various modules, devices, units and / or equipment in the embodiments of the present application.

[0132] Bus 410 includes hardware, software or both, and the parts of electronic equipment are coupled to each other. For example, but not limitation, bus may include accelerated graphics port (AGP) or other graphics bus, enhanced industrial standard architecture (EISA) bus, front side bus (FSB), hypertransport (HT) interconnection, industrial standard architecture (ISA) bus, infinite bandwidth interconnection, low pin count (LPC) bus, memory bus, micro channel architecture (MCA) bus, peripheral component interconnection (PCI) bus, PCI-Express (PCI-X) bus, serial advanced technology attachment (SATA) bus, video electronics standard association local (VLB) bus or other suitable bus or two or more of these combinations. In appropriate cases, bus 410 may include one or more buses. Although the present application embodiment describes and shows a specific bus, the application considers any suitable bus or interconnection.

[0133] The electronic device can execute the license plate and face detection method in the embodiment of the present application, thereby realizing the combination of Figure 1 and Figure 3 A method and apparatus for detecting license plates and human faces is described.

[0134] In addition, in combination with the license plate and face detection methods in the above embodiments, the embodiments of the present application may provide a computer-readable storage medium for implementation. The computer-readable storage medium stores computer program instructions; when the computer program instructions are executed by the processor, any one of the license plate and face detection methods in the above embodiments is implemented.

[0135] In combination with the license plate and face detection methods in the above embodiments, the present application embodiment can provide a vehicle for implementation. The vehicle includes: an electronic device for implementing any of the license plate and face detection methods as above.

[0136] It should be clear that the present application is not limited to the specific configuration and processing described above and shown in the figures. For the sake of simplicity, a detailed description of the known method is omitted here. In the above embodiments, several specific steps are described and shown as examples. However, the method process of the present application is not limited to the specific steps described and shown, and those skilled in the art can make various changes, modifications and additions, or change the order between the steps after understanding the spirit of the present application.

[0137] The functional blocks shown in the above block diagram can be implemented as hardware, software, firmware or a combination thereof. When implemented in hardware, it can be, for example, an electronic circuit, an application specific integrated circuit (ASIC), appropriate firmware, a plug-in, a function card, etc. When implemented in software, the elements of the present application are programs or code segments that are used to perform the required tasks. The program or code segment can be stored in a machine-readable medium, or transmitted on a transmission medium or a communication link by a data signal carried in a carrier wave. "Machine-readable medium" can include any medium capable of storing or transmitting information. Examples of machine-readable media include electronic circuits, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), floppy disks, CD-ROMs, optical disks, hard disks, optical fiber media, radio frequency (RF) links, etc. The code segment can be downloaded via a computer network such as the Internet, an intranet, etc.

[0138] It should also be noted that the exemplary embodiments mentioned in this application describe some methods or systems based on a series of steps or devices. However, this application is not limited to the order of the above steps, that is, the steps can be performed in the order mentioned in the embodiment, or in a different order from the embodiment, or several steps can be performed simultaneously.

[0139] Aspects of the present disclosure are described above with reference to the flowchart and / or block diagram of the method, device (system) and computer program product according to the embodiment of the present disclosure. It should be understood that each box in the flowchart and / or block diagram and the combination of each box in the flowchart and / or block diagram can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device to produce a machine so that these instructions executed by the processor of the computer or other programmable data processing device enable the implementation of the function / action specified in one or more boxes of the flowchart and / or block diagram. Such a processor can be, but is not limited to, a general-purpose processor, a special-purpose processor, a special application processor, or a field programmable logic circuit. It can also be understood that each box in the block diagram and / or flowchart and the combination of boxes in the block diagram and / or flowchart can also be implemented by dedicated hardware that performs a specified function or action, or can be implemented by a combination of dedicated hardware and computer instructions.

[0140] The above are only specific implementation methods of the present application. Those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working processes of the systems, modules and units described above can refer to the corresponding processes in the aforementioned method embodiments, and will not be repeated here. It should be understood that the protection scope of the present application is not limited to this. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed in this application, and these modifications or replacements should be included in the protection scope of this application.

[0141] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the term "comprising" or any other variant thereof is intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprising a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

Claims

1. A method for detecting license plates and faces, characterized in that: include: Acquire a second image, where the second image satisfies the target size and includes at least one license plate or a face; Performing sampling processing on the second image to obtain a feature image; Input the feature image into a feature extraction model, and output the target object features, wherein the target object features include the detection frame center of each pixel, the detection frame width and height regression value, and the detection frame classification score, wherein the feature extraction model is trained based on the historical feature image and the detection frame center of each pixel in the historical feature image, the detection frame width and height regression value, and the detection frame classification score, and the feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model; Based on the confidence determination strategy, the detection frame center and the detection frame classification score of each pixel point are processed to determine the confidence value of each pixel point; Filter target pixel points from the pixel points based on the confidence value, and process the detection frame height regression value and the target pixel points based on an object determination strategy to obtain a target object, wherein the target object includes at least one of the license plate and the face.

2. The method according to claim 1, characterized in that The feature image includes a first feature image; The sampling process of the second image to obtain a feature image includes: Performing multiple downsampling processes on the second image to obtain multiple downsampled images, wherein different downsampled images correspond to different sampling multiples; Performing upsampling processing on the first downsampled image to obtain a first upsampled image, wherein the first downsampled image is a downsampled image with the largest sampling multiple among the multiple downsampled images; The first up-sampled image and the second down-sampled image are added to obtain the first feature image, wherein the second down-sampled image is a down-sampled image with the same sampling multiple as the first up-sampled image among the multiple down-sampled images.

3. The method according to claim 2, characterized in that The step of inputting the feature image into a feature extraction model and outputting target object features comprises: When the sampling multiple of the first feature image is greater than or equal to the first multiple, the first feature image is input into the license plate feature extraction sub-model, and the license plate frame centrality, license plate frame width and height regression value and license plate frame classification score of each pixel point are output. The license plate feature extraction sub-model is trained based on the historical feature image and the license plate frame centrality, license plate frame width and height regression value and license plate frame classification score of each pixel point in the historical feature image.

4. The method according to claim 2, characterized in that The characteristic image also includes a second characteristic image; Before inputting the feature image into the feature extraction model and outputting the target object features, the method further includes: Performing upsampling processing on the first feature image to obtain a second upsampling image; Adding the second up-sampled image and the third down-sampled image to obtain the second feature image, wherein the third down-sampled image is a down-sampled image with the same sampling multiple as the second up-sampled image among the plurality of down-sampled images, and the sampling multiple of the second feature image is smaller than the sampling multiple of the first feature image; The step of inputting the feature image into a feature extraction model and outputting target object features comprises: When the sampling multiple of the second feature image is greater than or equal to the second multiple, the second feature image is input into the facial feature extraction sub-model, and the facial frame center degree, facial frame width and height regression value and facial frame classification score of each pixel point in the second feature image are output. The facial feature extraction sub-model is trained based on the historical feature image and the facial frame center degree, facial frame width and height regression value and facial frame classification score of each pixel point in the historical feature image.

5. The method according to claim 1, characterized in that After adding the target pixel point to the detection frame width and height regression value of the target pixel point to determine the target object, the method further includes: Calculating a difference between a detection box center of a first target object and a detection box center of a second target object to obtain a center difference, wherein the first target object and the second target object are any two adjacent target objects among the plurality of target objects; When the center degree difference is less than or equal to a second threshold, determining that the first target object and the second target object are two repeated target objects; In a case where the confidence value of the first target object is greater than the confidence value of the second target object, the first target object is determined to be a valid object.

6. The method according to claim 1, characterized in that The acquiring of the second image comprises: Acquire a first image, where the first image is an image captured including at least one license plate or a human face, The first image is reduced to the target size to obtain a second image.

7. A license plate and face detection device, characterized in that: The device comprises: An acquisition module, used to acquire a second image, where the second image meets the target size and includes at least one license plate or a face image; A processing module, used for performing sampling processing on the second image to obtain a feature image; A feature extraction module is used to input the feature image into a feature extraction model and output target object features, wherein the target object features include the detection frame center degree, detection frame width and height regression value, and detection frame classification score of each pixel point, wherein the feature extraction model is trained based on the historical feature image and the detection frame center degree, detection frame width and height regression value, and detection frame classification score of each pixel point in the historical feature image, and the feature extraction model includes a license plate feature extraction sub-model and a face feature extraction sub-model; A first determination module is used to process the detection box center and the detection box classification score of each pixel point based on a confidence determination strategy to determine the confidence value of each pixel point; The second determination module is used to filter target pixel points from the pixel points based on the confidence value, and process the detection frame height regression value and the target pixel points based on the object determination strategy to obtain a target object, wherein the target object includes at least one of the license plate and the face.

8. An electronic device, characterized in that: The electronic device comprises: a processor and a memory storing computer program instructions; when the processor executes the computer program instructions, the license plate and face detection method as described in any one of claims 1-6 is implemented.

9. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer program instructions, and when the computer program instructions are executed by the processor, the license plate and face detection method as described in any one of claims 1-6 is implemented.

10. A vehicle, characterized in that: include: An electronic device, wherein the electronic device is used to implement the license plate and face detection method as described in any one of claims 1 to 6.

Citation Information

Cited By

  • Object detection method and apparatus, computer device and storage medium

    WO2026170964A1