Image processing method and device, equipment and medium

By performing human body key point detection and face desensitization processing in the vehicle sentry mode, the problem of low human body detection accuracy and high computing power consumption is solved, efficient anomaly detection and desensitization processing are achieved, and detection accuracy and face desensitization are improved. Computing performance.

CN118570761APending Publication Date: 2024-08-30ZHEJIANG GEELY HLDG GRP CO LTD +1
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202410569894.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-09
Publication Date
2024-08-30

AI Technical Summary

Technical Problem

In the vehicle sentry mode, the accuracy of human body detection is low, and it consumes a lot of computing power on the vehicle, requiring high computing performance and needs to be improved.

Method used

By acquiring the target video outside the vehicle, human body key points are detected, the coordinates of multiple human body key points are determined, abnormal image frames are determined based on the coordinates of the foot key points, and face desensitization is performed based on the head key points of the abnormal image frames. Processing, reducing the number of models, reducing computing power consumption, and improving detection accuracy.

Benefits of technology

It is possible to complete vehicle exterior anomaly detection and face desensitization by using a model that detects human body key points, reducing the number of models, reducing computing power consumption, improving detection accuracy, and reducing false positives and false negatives.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118570761A
    Figure CN118570761A
Patent Text Reader

Abstract

The embodiment of the invention relates to an image processing method and device, equipment and a medium, and the method comprises the steps: obtaining a target video outside a vehicle, and enabling the target video to comprise a plurality of image frames; performing human body key point detection on each image frame, and determining coordinates of a plurality of human body key points; determining at least one abnormal image frame in the plurality of image frames based on the coordinates of the foot key points in the coordinates of the plurality of human body key points; and performing face desensitization processing based on the coordinates of the head key points of the at least one abnormal image frame to obtain at least one corresponding target image. According to the embodiment of the invention, abnormal detection and face desensitization outside the vehicle can be realized only through one model for detecting the human body key points, compared with the existing method for realizing the method by using independent models, the method has the advantages that the number of the models is reduced, the computing power consumption of the vehicle is reduced, and the accuracy is improved by performing human body detection through the human body key points.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of image processing technology, and in particular to an image processing method, device, equipment and medium. Background Art

[0002] In the vehicle sentry mode anomaly detection function, it is necessary to use cameras and human body detection models to detect the human bodies around the vehicle in real time. If an abnormality occurs, such as the distance between the surrounding human bodies and the vehicle is less than the preset threshold and exceeds a certain time, an alarm can be triggered, and then the video shot by the camera in the time period near the alarm time can be recorded. In the sentry mode owner remote viewing function, the recorded video can be transmitted after desensitization processing, and the license plate detection model is used to detect the license plate in the video screen, and the human key point detection model / face detection model is used to detect the face in the video screen, etc., and then the license plate, face and other data are desensitized. However, the accuracy of human body detection in the above scheme is low, and it requires the processing of multiple models, which consumes a lot of vehicle computing power and has high computing performance requirements, and needs to be improved. Summary of the invention

[0003] In order to solve the above technical problems or at least partially solve the above technical problems, the present disclosure provides an image processing method, apparatus, device and medium.

[0004] The present disclosure provides an image processing method, the method comprising:

[0005] Acquire a target video outside the vehicle, wherein the target video includes a plurality of image frames;

[0006] Performing human body key point detection on each of the image frames to determine the coordinates of multiple human body key points;

[0007] Determine at least one abnormal image frame among the multiple image frames based on the coordinates of the foot key points among the coordinates of the multiple human body key points;

[0008] Face desensitization processing is performed based on the coordinates of the head key points of the at least one abnormal image frame to obtain at least one corresponding target image.

[0009] The present disclosure also provides an image processing device, the device comprising:

[0010] An acquisition module, used for acquiring a target video outside the vehicle, wherein the target video includes a plurality of image frames;

[0011] A detection module, used to detect human key points on each of the image frames and determine the coordinates of multiple human key points;

[0012] an abnormality determination module, configured to determine at least one abnormal image frame among the plurality of image frames based on the coordinates of the foot key points among the coordinates of the plurality of human body key points;

[0013] The desensitization module is used to perform face desensitization processing based on the coordinates of the head key points of the at least one abnormal image frame to obtain at least one corresponding target image.

[0014] An embodiment of the present disclosure also provides an electronic device, which includes: a processor; a memory for storing executable instructions of the processor; the processor is used to read the executable instructions from the memory and execute the instructions to implement the image processing method provided by the embodiment of the present disclosure.

[0015] The embodiment of the present disclosure further provides a computer-readable storage medium, wherein the storage medium stores a computer program, and the computer program is used to execute the image processing method provided by the embodiment of the present disclosure.

[0016] The technical solution provided by the embodiment of the present disclosure has the following advantages over the prior art: the image processing solution provided by the embodiment of the present disclosure obtains a target video outside the vehicle, wherein the target video includes multiple image frames; performs human key point detection on each image frame to determine the coordinates of multiple human key points; determines at least one abnormal image frame in the multiple image frames based on the coordinates of the foot key points in the coordinates of the multiple human key points; performs face desensitization processing based on the coordinates of the head key points of at least one abnormal image frame to obtain at least one corresponding target image. By adopting the above technical solution, human key point detection is performed on each image frame of the video outside the vehicle, and the abnormal image frame can be determined based on the coordinates of the human key points, and then the coordinates of the head key points in the human key points can be reused for face desensitization processing, so that only one model of human key point detection can be used to realize abnormal detection and face desensitization of the vehicle's exterior. Compared with the existing implementation using separate models, the number of models is reduced, the computing power consumption of the vehicle is reduced, and human detection is performed through human key points to improve the accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0018] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0019] Figure 1 A flowchart of an image processing method provided by an embodiment of the present disclosure;

[0020] Figure 2 A schematic diagram of image processing provided by an embodiment of the present disclosure;

[0021] Figure 3 A flowchart of another image processing method provided by an embodiment of the present disclosure;

[0022] Figure 4 A schematic diagram of the structure of an image processing device provided by an embodiment of the present disclosure;

[0023] Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0024] 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.

[0025] 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.

[0026] In order to solve the problems of low accuracy and high computing power consumption in vehicle external human body detection in the related art, the present disclosure provides an image processing method, which is introduced below in conjunction with a specific embodiment.

[0027] Figure 1 The following is a flow chart of an image processing method provided by an embodiment of the present disclosure. The method can be executed by an image processing device, wherein the device can be implemented by software and / or hardware and can generally be integrated in an electronic device. Figure 1 As shown, the method includes:

[0028] Step 101: Acquire a target video outside a vehicle, wherein the target video includes a plurality of image frames.

[0029] The vehicle may be able to monitor the vehicle's surroundings through an on-board camera and sensors. When the vehicle is hit, moved, or pedestrians are too close to the vehicle, the recorded video can be sent to the owner. This vehicle safety function is called a vehicle sentry mode. The vehicle of the embodiment of the present disclosure may have a vehicle sentry mode. The target video may be a video obtained by shooting the outside of the vehicle through the on-board camera. The target video may include multiple image frames, and an image frame may be the smallest component unit of the video.

[0030] The image processing method of the embodiment of the present disclosure may be executed by a controller of a vehicle, that is, the image processing device may be disposed in the controller of the vehicle.

[0031] Step 102: Detect human key points on each image frame to determine the coordinates of multiple human key points.

[0032] The key points of the human body may include the head, neck, shoulder, elbow, hand, hip, knee, foot, etc. When the behavior of the human body is abnormal, the positions of the key points of the human body will be significantly different. By analyzing the key points of the human body, it can be determined whether the behavior of the human body is abnormal. The coordinates of the key points of the human body can be the coordinates of the key points of the human body in a specific image frame.

[0033] Specifically, the image processing device can input each image frame into the human key point detection model, and output the coordinates of multiple human key points and the confidence of the coordinates of each human key point. For example, the coordinates of multiple human key points can be expressed as P = (p1, p2, p3, ..., pn), and the corresponding confidence can be expressed as C = (c1, c2, c3, ..., cn), where p1-pn are the two-dimensional coordinates of the human key points in the image frame, and c1-cn are the confidences of the corresponding human key points, with a value range of 0-1. Among them, the human key point detection model can be obtained by training a neural network model based on deep learning with training data marked with the coordinates of the human key points. The specific neural network model is not limited and can be determined according to actual conditions.

[0034] Step 103: Determine at least one abnormal image frame among the multiple image frames based on the coordinates of the foot key points among the coordinates of the multiple human body key points.

[0035] The foot key points may include left foot key points and right foot key points. The abnormal image frames may be image frames with a human body and abnormal human behavior, and the number of abnormal image frames is not limited.

[0036] Specifically, for each image frame, the image processing device can determine whether the image frame is an abnormal image frame based on the comparison between the coordinates of the foot key point among multiple human key points corresponding to the image frame and the abnormal area, and further determine at least one abnormal image frame among the multiple image frames.

[0037] In some embodiments, at least one abnormal image frame among multiple image frames is determined based on the coordinates of foot key points among the coordinates of multiple human body key points, including: for each of the image frames, extracting the coordinates of multiple foot key points, extracting valid foot key point pairs based on the confidence levels of the multiple foot key points; and extracting at least one abnormal image frame from the multiple image frames based on the relationship between the coordinates of the valid foot key point pairs and the boundary line of the abnormal area.

[0038] Among them, the confidence of the foot key point can be the reliability of the human body key point model in determining the coordinates of the foot key point. The higher the confidence, the higher the reliability of the coordinates of the foot key point. The valid foot key point pair can be a combination of a left valid foot key point and a right valid foot key point with a higher reliability among multiple foot key points, that is, the valid foot key point pair includes a left valid foot key point and a right valid foot key point, and the number of valid foot key point pairs can be at least one. The abnormal area can be an area set outside the vehicle. When part or all of the human body enters the abnormal area, it means that the human body is too close to the vehicle and an abnormal situation can be determined.

[0039] Specifically, the image processing device extracts the coordinates of multiple foot key points from the coordinates of multiple human body key points for each image frame, the multiple foot key points include multiple foot key point pairs, each foot key point pair includes a left foot key point and a right foot key point, and for each foot key point pair, the average value of the two corresponding confidences is calculated, and when the average value is greater than or equal to the preset confidence, it is determined that the foot key point pair is a valid foot key point pair.

[0040] Then, at least one abnormal image frame is extracted from multiple image frames based on the relationship between the coordinates of the valid foot key point pairs and the boundary line of the abnormal area. Specifically, it may include: determining the coordinates of the center points of each valid foot key point pair based on the coordinates of the valid foot key point pairs, and determining the image frame in which the coordinates of the center point of at least one valid foot key point pair in the multiple image frames are inside the boundary line of the abnormal area as an abnormal image frame, to obtain at least one abnormal image frame; or, determining the image frame in which the coordinates of the left valid foot key point and / or the right valid foot key point of at least one valid foot key point pair in the multiple image frames are inside the boundary line of the abnormal area as an abnormal image frame, to obtain at least one abnormal image frame.

[0041] For each image frame, whether it is an abnormal image frame is determined based on the relationship between the coordinates of each valid foot key point pair of the image frame and the boundary line of the abnormal area. The coordinate averages of the left valid foot key point and the right valid foot key point in each valid foot key point pair can be calculated to obtain the center point coordinates. When there is a foot key point pair with a center point coordinate inside the boundary line of the abnormal area, it means that there is a foot key point of the foot key point pair with a coordinate inside the boundary line of the abnormal area or the coordinates of both foot key points are inside the boundary line of the abnormal area, which means that there is an abnormality in the human body corresponding to the foot key point pair, and the image frame is determined to be an abnormal image frame. After the judgment of each image frame is completed, at least one abnormal image frame can be determined.

[0042] For example, Figure 2 A schematic diagram of image processing provided by an embodiment of the present disclosure is shown in FIG. Figure 2 As shown, the figure shows an exemplary image frame 200, which includes two human bodies, including human body 201 and human body 202 in the figure, the black dots on the human bodies are human body key points, and the dotted rectangular frame of the human body's feet in the figure selects two valid foot key point pairs. By judging whether the center point coordinates of the two valid foot key point pairs in the figure are inside the boundary line of the abnormal area, the center point coordinates of the valid foot key point pair of human body 201 in the figure are inside the boundary line of the abnormal area, and the center point coordinates of the valid foot key point pair of human body 202 are outside the boundary line of the abnormal area, it is determined that the image frame is an abnormal image frame.

[0043] In the above scheme, human body detection and anomaly detection are performed through the body key point detection model, which reduces false positives and missed positives during anomaly detection in sentinel mode and improves the accuracy of vehicle anomaly detection.

[0044] Step 104: Perform face desensitization processing based on the coordinates of the head key points of at least one abnormal image frame to obtain at least one corresponding target image.

[0045] The face desensitization process may be a process of removing or replacing the face part in the image to prevent unauthorized face recognition and tracking, etc. The target image may be an image obtained after the face desensitization process is performed on the abnormal image frame.

[0046] Specifically, the image processing device can perform face desensitization processing on the above-mentioned at least one abnormal image frame. Specifically, it can reuse the coordinates of the head key points of multiple human body key points of the above-mentioned abnormal image frame, determine the head detection frame according to the coordinates of the head key points of each abnormal image frame, perform face desensitization processing on the head detection frame, obtain the corresponding target image, and then obtain at least one target image.

[0047] For example, Figure 3A flowchart of another image processing method provided by an embodiment of the present disclosure is shown in FIG. Figure 3 As shown, in a feasible implementation manner, the above step 104 may include the following steps:

[0048] Step 301: Determine a target head detection frame of each abnormal image frame based on the coordinates of the head key points of at least one abnormal image frame.

[0049] Among them, the target head detection frame can be a head detection frame determined after the abnormal image frame is processed through missed detection, which has higher accuracy than related technologies.

[0050] In some embodiments, determining a target head detection frame of each abnormal image frame based on the coordinates of the head key points of at least one abnormal image frame may include: determining an initial head detection frame by calculating a minimum circumscribed rectangle based on the coordinates of the head key points of each abnormal image frame; determining each abnormal image frame as a current frame, and judging whether the current frame is a missed detection frame based on the intersection and union ratio of the initial head detection frames of the previous frame and the next frame of the current frame; if the current frame is determined to be a missed detection frame, determining a corresponding missed detection head detection frame based on the average value of the four corner point coordinates of the initial head detection frames of the previous frame and the next frame of the current frame, and determining the initial head detection frame of the current frame and the missed detection head detection frame as the target head detection frame; otherwise, determining the initial head detection frame of the current frame as the target head detection frame.

[0051] Among them, the initial head detection frame can be a head detection frame determined based on the coordinates of the head key points of the abnormal image frame, which has not been processed for missed detection. The missed detection frame can be an abnormal image frame in which a human head is missed, that is, there is a human head in the missed detection frame but no corresponding head detection frame is determined. The missed detection head detection frame can be the missed head detection frame determined by calculation in the missed detection frame. The intersection-union ratio can represent the degree of overlap of two detection frames, specifically, it can be the ratio of the intersection area of ​​the two detection frames to the union area of ​​the two detection frames, and the two detection frames can be two initial head detection frames.

[0052] Specifically, the image processing device can, for each abnormal image frame, select the coordinates of multiple human key points that are the same as the timestamp from the stored data of the coordinates of the human key points based on the timestamp of the abnormal image frame, extract multiple head key points therein, and extract valid head key points from the multiple head key points, and divide the multiple head key points into multiple groups based on the head as a unit, calculate the maximum and minimum values ​​of the horizontal and vertical coordinates of the multiple head key points included in each group, and then determine the minimum enclosing rectangle, and determine the minimum enclosing rectangle as the initial head detection frame.

[0053] Afterwards, the image processing device can determine each abnormal image frame as the current frame, and use the above method to determine the initial head detection frames of the previous frame and the next frame of the current frame. After that, the intersection and union ratio of the corresponding initial head detection frames of the previous frame and the next frame can be calculated, and it is judged whether the current frame is a missed detection frame according to the intersection and union ratio. If so, two initial head detection frames whose intersection and union ratio of the previous frame and the next frame is greater than the first threshold can be extracted as two consecutive head detection frames, and the average value of the four corner point coordinates of the two consecutive head detection frames is determined as the four corner point coordinates of the missed detection head detection frame, that is, the missed detection head detection frame in the current frame is obtained, and the initial head detection frame of the current frame and the missed detection head detection frame are determined as the target head detection frame; if it is determined that the current frame is not a missed detection frame, the initial head detection frame of the current frame can be directly determined as the target head detection frame.

[0054] The above process of extracting valid head key points from multiple head key points may include: calculating the average confidence value for all head key points included in each head in units of heads, and if the average confidence value is greater than or equal to a preset confidence value, determining that all head key points of the head are valid head key points.

[0055] Optionally, judging whether the current frame is a missed detection frame based on the intersection-and-union ratio of the initial head detection frames of the previous frame and the next frame of the current frame includes: extracting two initial head detection frames whose intersection-and-union ratios are greater than a first threshold in the previous frame and the next frame of the current frame as two consecutive head detection frames, and determining the center coordinates of the two consecutive head detection frames; determining the first initial head detection frame with the smallest distance from the center coordinates in the current frame, and determining two intersection-and-union ratios of the first initial head detection frame and the two consecutive head detection frames respectively; if both intersection-and-union ratios are less than the second threshold, determining that the current frame is a missed detection frame; otherwise, determining that the current frame is not a missed detection frame.

[0056] The first threshold may be a minimum value set for the intersection-and-union ratio of two initial head detection frames, and the second threshold may be a maximum value set for the two intersection-and-union ratios of the first initial head detection frame and the two consecutive head detection frames, respectively. The first threshold and the second threshold may be set according to actual conditions, for example, the first threshold may be set to the same value as the second threshold. The two consecutive head detection frames may be two initial head detection frames corresponding to the same human head in the previous frame and the next frame of the current frame.

[0057] When the image processing device determines whether the current frame is a missed detection frame based on the intersection-and-union ratio of the initial head detection frames of the previous frame and the next frame of the current frame, the image processing device can first extract two initial head detection frames whose intersection-and-union ratio of the previous frame and the next frame is greater than a first threshold as two consecutive head detection frames, and then calculate the average value of the center coordinates of the two consecutive head detection frames as the center coordinates of the two consecutive head detection frames; then determine the distance between each initial head detection frame in the current frame and the center coordinate, extract the initial head detection frame with the smallest distance from the center coordinate as the first initial head detection frame, and calculate two intersection-and-union ratios of the first initial head detection frame and the two consecutive head detection frames respectively, compare the two intersection-and-union ratios with the second threshold, if the two intersection-and-union ratios are both less than the second threshold, it is determined that the human head corresponding to the two consecutive head detection frames in the current frame is missed, and the current frame is a missed detection frame; otherwise, it is determined that the current frame is not a missed detection frame.

[0058] In the above scheme, when determining the head detection frame in the abnormal image frame, the detection results of the human body key points of the entire video are used. By increasing the missed detection judgment and processing in the time direction, the missed detection is reduced, and the accuracy of the head detection frame determination is improved, which is beneficial to improve the accuracy of subsequent face desensitization and enhance the security of the desensitized image.

[0059] Step 302: Perform face desensitization processing based on the target head detection frame of each abnormal image frame to obtain at least one corresponding target image.

[0060] After determining the target head detection frame of each abnormal image frame, the image processing device can perform face desensitization processing on the area of ​​the target head detection frame in each abnormal image frame to obtain a target image, and then obtain at least one target image. The face desensitization processing here can be implemented by at least one of mosaic covering, pixelation processing, blurring of facial feature points, and deep learning model, which is determined according to actual conditions.

[0061] Optionally, for at least one abnormal image frame, a license plate detection model may be used to detect a license plate detection frame in each abnormal image frame, and license plate desensitization processing may be performed on each abnormal image frame based on the license plate detection frame to obtain at least one corresponding target image. The license plate desensitization processing may be implemented by at least one of pixel interference, information hiding, data encryption, etc., without limitation.

[0062] The image processing scheme provided by the disclosed embodiment obtains a target video outside the vehicle, wherein the target video includes multiple image frames; performs human key point detection on each image frame to determine the coordinates of multiple human key points; determines at least one abnormal image frame in the multiple image frames based on the coordinates of the foot key points in the coordinates of the multiple human key points; performs face desensitization processing based on the coordinates of the head key points of at least one abnormal image frame to obtain at least one corresponding target image. The above technical scheme is adopted to perform human key point detection on each image frame of the video outside the vehicle, and the abnormal image frame can be determined based on the coordinates of the human key points. The coordinates of the head key points in the human key points can then be reused to perform face desensitization processing, thereby realizing that abnormal detection and face desensitization of the vehicle's exterior can be realized only through a model of human key point detection. Compared with the existing implementation using separate models, the number of models is reduced, the computing power consumption of the vehicle is reduced, and human detection is performed through human key points to improve the accuracy.

[0063] In some embodiments, the image processing method of the embodiment of the present disclosure may further include: when the number of consecutive frames of at least one abnormal image frame in the target video is greater than a preset number threshold, performing an alarm operation.

[0064] Among them, the continuous frames may include multiple abnormal image frames in which at least one abnormal image frame is played continuously in the target video. The preset number threshold can be set according to the actual situation, for example, the preset number threshold can be 10. After determining at least one abnormal image frame among the multiple image frames, the image processing device can determine the continuous frames in which at least one abnormal image frame is played continuously in the target video, and judge whether the number of the continuous frames is greater than the preset number threshold. If so, it is determined that there is an abnormal situation, and an alarm operation can be performed. The alarm operation may include displaying an alarm prompt, playing an alarm audio, sending an alarm message to the car owner, etc., which is specifically set according to the actual situation. In the above scheme, an alarm is issued when the number of continuous abnormal image frames exceeds the threshold, which can help the car owner to understand the safety status of the vehicle in a timely manner and protect the safety of the vehicle.

[0065] Figure 4 The structure diagram of an image processing device provided by an embodiment of the present disclosure is shown in FIG. 1 , which can be implemented by software and / or hardware and can generally be integrated into an electronic device. Figure 4 As shown, the device comprises:

[0066] An acquisition module 401 is used to acquire a target video outside the vehicle, wherein the target video includes a plurality of image frames;

[0067] A detection module 402 is used to detect human key points on each of the image frames to determine the coordinates of multiple human key points;

[0068] An abnormality determination module 403 is used to determine at least one abnormal image frame among the multiple image frames based on the coordinates of the foot key points among the coordinates of the multiple human body key points;

[0069] The desensitization module 404 is used to perform face desensitization processing based on the coordinates of the head key points of the at least one abnormal image frame to obtain at least one corresponding target image.

[0070] Optionally, the detection module 402 is used to:

[0071] Each of the image frames is input into a human body key point detection model, and the coordinates of a plurality of human body key points are obtained as output.

[0072] Optionally, the abnormality determination module 403 is used to:

[0073] For each of the image frames, extract coordinates of a plurality of foot key points, and extract valid foot key point pairs based on the confidence levels of the plurality of foot key points;

[0074] At least one abnormal image frame is extracted from the multiple image frames based on the relationship between the coordinates of the valid foot key point pair and the boundary line of the abnormal area.

[0075] Optionally, the device further comprises an alarm module, which is used to:

[0076] When the number of consecutive frames of the at least one abnormal image frame in the target video is greater than a preset number threshold, an alarm operation is performed.

[0077] Optionally, the desensitization module 404 includes:

[0078] A first unit is used to determine a target head detection frame of each abnormal image frame based on the coordinates of the head key points of the at least one abnormal image frame;

[0079] The second unit is used to perform face desensitization processing based on the target head detection frame of each abnormal image frame to obtain at least one corresponding target image.

[0080] Optionally, the first unit includes:

[0081] An initial subunit, configured to determine an initial head detection frame by calculating a minimum circumscribed rectangle based on the coordinates of the head key points of each of the abnormal image frames;

[0082] A missed detection subunit, configured to determine each of the abnormal image frames as a current frame, and determine whether the current frame is a missed detection frame based on an intersection-and-union ratio of initial head detection frames of a previous frame and a subsequent frame of the current frame;

[0083] A determination subunit is used to determine the corresponding missed-detection head detection frame based on the average values ​​of the four corner point coordinates of the initial head detection frames of the previous frame and the next frame of the current frame if it is determined that the current frame is a missed-detection frame, and determine the initial head detection frame of the current frame and the missed-detection head detection frame as target head detection frames; otherwise, determine the initial head detection frame of the current frame as the target head detection frame.

[0084] Optionally, the missed detection subunit is used for:

[0085] Extracting two initial head detection frames whose intersection-over-union ratio is greater than a first threshold in a frame before and a frame after the current frame as two continuous head detection frames, and determining the center coordinates of the two continuous head detection frames;

[0086] Determine a first initial head detection frame having the shortest distance from the center coordinates in the current frame, and determine two intersection-and-union ratios of the first initial head detection frame and the two consecutive head detection frames respectively;

[0087] If the two intersection-and-union ratios are both smaller than the second threshold, it is determined that the current frame is a missed-detection frame; otherwise, it is determined that the current frame is not a missed-detection frame.

[0088] The image processing device provided in the embodiments of the present disclosure can execute the image processing method provided in any embodiment of the present disclosure, and has the corresponding functional modules and beneficial effects of the execution method.

[0089] Figure 5 The structure diagram of an electronic device provided by the embodiment of the present disclosure is shown in FIG. Figure 5 As shown, the electronic device 500 includes one or more processors 501 and a memory 502 .

[0090] The processor 501 may be a central processing unit (CPU) or other forms of processing units having data processing capabilities and / or instruction execution capabilities, and may control other components in the electronic device 500 to perform desired functions.

[0091] The memory 502 may include one or more computer program products, and the computer program product may include various forms of computer-readable storage media, such as volatile memory and / or non-volatile memory. The volatile memory may include, for example, a random access memory (RAM) and / or a cache memory (cache), etc. The non-volatile memory may include, for example, a read-only memory (ROM), a hard disk, a flash memory, etc. One or more computer program instructions may be stored on the computer-readable storage medium, and the processor 501 may run the program instructions to implement the image processing method of the embodiment of the present disclosure described above and / or other desired functions. Various contents such as input signals, signal components, noise components, etc. may also be stored in the computer-readable storage medium.

[0092] In one example, the electronic device 500 may further include: an input device 503 and an output device 504 , and these components are interconnected via a bus system and / or other forms of connection mechanisms (not shown).

[0093] In addition, the input device 503 may also include, for example, a keyboard, a mouse, and the like.

[0094] The output device 504 can output various information to the outside, including the determined distance information, direction information, etc. The output device 504 can include, for example, a display, a speaker, a printer, a communication network and a remote output device connected thereto, and the like.

[0095] Of course, to simplify, Figure 5 Only some of the components related to the present disclosure in the electronic device 500 are shown, and components such as a bus, an input / output interface, etc. are omitted. In addition, according to specific application situations, the electronic device 500 may also include any other appropriate components.

[0096] In addition to the above-mentioned method and device, the embodiment of the present disclosure may also be a computer program product, which includes computer program instructions, and when the computer program instructions are executed by a processor, the processor executes the image processing method provided by the embodiment of the present disclosure.

[0097] The computer program product may be written in any combination of one or more programming languages ​​to write program code for performing the operations of the disclosed embodiments, including object-oriented programming languages ​​such as Java, C++, etc., and conventional procedural programming languages ​​such as "C" or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as a separate software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server.

[0098] In addition, the embodiment of the present disclosure may also be a computer-readable storage medium on which computer program instructions are stored. When the computer program instructions are executed by a processor, the processor executes the image processing method provided by the embodiment of the present disclosure.

[0099] The computer readable storage medium can adopt any combination of one or more readable media. The readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can include, for example, but is not limited to, a system, device or device of electricity, magnetism, light, electromagnetic, infrared, or semiconductor, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.

[0100] 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 terms "include", "comprise" or any other variants thereof are 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 "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0101] The above description is only a specific embodiment of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure will not be limited to the embodiments described herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. An image processing method, characterized in that: include: Acquire a target video outside the vehicle, wherein the target video includes a plurality of image frames; Performing human body key point detection on each of the image frames to determine the coordinates of multiple human body key points; Determine at least one abnormal image frame among the multiple image frames based on the coordinates of the foot key points among the coordinates of the multiple human body key points; Face desensitization processing is performed based on the coordinates of the head key points of the at least one abnormal image frame to obtain at least one corresponding target image.

2. The method according to claim 1, characterized in that Performing human body key point detection on each of the image frames to determine the coordinates of multiple human body key points includes: Each of the image frames is input into a human body key point detection model, and the coordinates of a plurality of human body key points are obtained as output.

3. The method according to claim 1, characterized in that: Determining at least one abnormal image frame among the multiple image frames based on the coordinates of the foot key points among the coordinates of the multiple human body key points includes: For each of the image frames, extract coordinates of a plurality of foot key points, and extract valid foot key point pairs based on the confidence levels of the plurality of foot key points; At least one abnormal image frame is extracted from the multiple image frames based on the relationship between the coordinates of the valid foot key point pair and the boundary line of the abnormal area.

4. The method according to claim 1, characterized in that The method further comprises: When the number of consecutive frames of the at least one abnormal image frame in the target video is greater than a preset number threshold, an alarm operation is performed.

5. The method according to claim 1, characterized in that Performing face desensitization processing based on the coordinates of the head key points of the at least one abnormal image frame to obtain at least one corresponding target image includes: Determine a target head detection frame of each abnormal image frame based on the coordinates of the head key points of the at least one abnormal image frame; A face desensitization process is performed based on the target head detection frame of each abnormal image frame to obtain at least one corresponding target image.

6. The method according to claim 5, characterized in that Determining a target head detection frame of each abnormal image frame based on the coordinates of the head key points of the at least one abnormal image frame includes: Determine an initial head detection frame by calculating a minimum circumscribed rectangle based on the coordinates of the head key points of each abnormal image frame; Determine each abnormal image frame as a current frame, and determine whether the current frame is a missed detection frame based on an intersection-over-union ratio of initial head detection frames of a previous frame and a subsequent frame of the current frame; If it is determined that the current frame is a missed detection frame, the corresponding missed detection head detection frame is determined based on the average value of the four corner point coordinates of the initial head detection frames of the previous frame and the next frame of the current frame, and the initial head detection frame of the current frame and the missed detection head detection frame are determined as target head detection frames; otherwise, the initial head detection frame of the current frame is determined as the target head detection frame.

7. The method according to claim 6, characterized in that Determining whether the current frame is a missed detection frame based on an intersection-over-union ratio of initial head detection frames of a previous frame and a subsequent frame of the current frame includes: Extracting two initial head detection frames whose intersection-over-union ratio is greater than a first threshold in a frame before and a frame after the current frame as two continuous head detection frames, and determining the center coordinates of the two continuous head detection frames; Determine a first initial head detection frame having the shortest distance from the center coordinates in the current frame, and determine two intersection-and-union ratios of the first initial head detection frame and the two consecutive head detection frames respectively; If the two intersection-and-union ratios are both smaller than the second threshold, it is determined that the current frame is a missed-detection frame; otherwise, it is determined that the current frame is not a missed-detection frame.

8. An image processing device, characterized in that: include: An acquisition module, used for acquiring a target video outside the vehicle, wherein the target video includes a plurality of image frames; A detection module, used to detect human key points on each of the image frames and determine the coordinates of multiple human key points; an abnormality determination module, configured to determine at least one abnormal image frame among the plurality of image frames based on the coordinates of the foot key points among the coordinates of the plurality of human body key points; The desensitization module is used to perform face desensitization processing based on the coordinates of the head key points of the at least one abnormal image frame to obtain at least one corresponding target image.

9. An electronic device, characterized in that: The electronic device comprises: processor; a memory for storing instructions executable by the processor; The processor is used to read the executable instructions from the memory and execute the instructions to implement the image processing method described in any one of claims 1-7.

10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, and the computer program is used to execute the image processing method described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • Face-tracking method and device

    CN109344789A

  • Video fence based on human body posture evaluation and early warning method

    CN110796032A

  • Video-based license plate data desensitization method, storage medium and server

    CN112347853A

  • Face desensitization method, storage medium, electronic equipment and vehicle

    CN117910040A

  • Suggestion method and device, storage medium, and electronic apparatus

    WO2021147648A1