Low-power-consumption lightweight face detection tracking method and system

By dynamically adjusting the frame rate and resolution of the adaptive strategy, it solves the problem of balancing high accuracy and low power consumption in face recognition and tracking methods in the existing technology, achieving fast and accurate face detection and tracking, and reducing Reduces hardware cost and maintenance difficulty, and adapts to different environmental conditions.

CN118570261AInactive Publication Date: 2024-08-30GUANGDONG IND TECHN COLLEGE
View PDF 0 Cites 4 Cited by

Patent Information

Application Number
CN202410658820.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-27
Publication Date
2024-08-30
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Existing face recognition tracking methods are difficult to balance between maintaining high accuracy and low power consumption, and are easily affected by environmental factors and computing resource limitations, resulting in recognition delays and accuracy problems.

Method used

By dynamically adjusting frame rate and resolution, using face detection models and tracking algorithms, we adaptively optimize computing resources, reduce unnecessary energy consumption and hardware requirements, and improve response speed and system robustness.

Benefits of technology

It achieves fast and accurate face detection and tracking under low power consumption, reduces response time delays and hardware costs, improves the applicability and maintainability of the system, and adapts to different environmental conditions and face changes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118570261A
    Figure CN118570261A
Patent Text Reader

Abstract

The invention relates to a low-power-consumption lightweight face detection tracking method and system, and the method comprises the steps: S1, collecting a face image through a camera, and initializing a high resolution and a frame rate; s2, adaptively adjusting the resolution of the collected face image, processing the face image through a face detection model, recognizing a face in the image through the face detection model, and outputting a face detection confidence coefficient and a face detection frame; s3, adjusting the resolution according to the face confidence; s4, performing continuous frame tracking on the detected face by using a face detection tracking algorithm; s5, analyzing a face tracking result, and performing frame rate adaptive adjustment; and S6, outputting the adjusted frame rate to a camera to collect a face image, and circularly executing the steps S2 to S5 to realize adaptive adjustment of the resolution and the frame rate. According to the method, the frame rate and the resolution are adaptively adjusted, so that the use of computing resources is optimized, unnecessary energy consumption is reduced, the response speed is increased, and the hardware and maintenance cost is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer science and technology, and in particular to a low-power and lightweight face detection and tracking method and system. Background Art

[0002] With the development of computer science and technology, technological innovations in computer vision, image processing, and artificial intelligence have developed rapidly. In the current face recognition and tracking methods, such as the "Low-power Face Recognition Method and System" with application number: CN201811243235.8, this method reduces power consumption by reducing the use of hardware and software, but this method requires multiple judgments before detecting a living target, which may lead to time delays in the entire process from detecting a living target to completing face recognition in practical applications. In addition, this method is easily affected by environmental factors, such as changes in ambient light, changes in expression and posture, and possible face recognition errors. Due to differences in each person's facial features, such as skin color, facial hair, or whether glasses are worn, errors in the recognition system may occur. The "lightweight face detection and tracking method" with application number: CN202111310370.1 uses the combination of low-resolution thermal infrared images and high-resolution visible light to improve the accuracy and efficiency of face detection, while reducing the computing resources required for processing. However, the coordinate conversion from thermal infrared images to visible light images may introduce errors, especially when the calibration of the two images is inaccurate, and the effect of this method requires high quality of visible light images. Therefore, under poor lighting conditions or large environmental changes, the accuracy of face detection and tracking may be affected. Since this method requires the combination of thermal infrared and visible light image data, additional equipment and steps may be required in data acquisition and processing, increasing the complexity of the system. The "face tracking method, device and terminal" with application number: CN201810939574.3 reduces the number of faces to be recognized in each video frame, that is, after the initial recognition, only faces with high similarity are tracked, reducing the need to re-recognize and match all faces in each frame of the entire video sequence. However, if the face recognition accuracy in the initial video frame is not high, the subsequent tracking accuracy will also be affected. Face tracking in large-scale video streams may require a lot of computing resources, so there may be limitations in real-time performance. In addition, if there is an image area to be detected with a similarity greater than a preset threshold, the image area to be detected in the subsequent video frame image will be visually marked. However, this method may be affected by environmental noise, lighting changes or other interference factors, thereby affecting the accuracy of marking and the stability of tracking.

[0003] It can be seen that the existing face recognition and tracking methods need to be further improved, and there is an urgent need to find a method that maintains high accuracy and low power consumption to meet the face recognition and tracking process. Summary of the invention

[0004] In order to solve the technical problems existing in the prior art, the present invention provides a low-power lightweight face detection and tracking method and system, which aims to maintain high accuracy and low power consumption at the same time, and optimize the use of computing resources by adaptively adjusting the frame rate and resolution, thereby reducing unnecessary energy consumption, improving the response speed, and reducing hardware and maintenance costs.

[0005] The method of the present invention is implemented by the following technical solution: a low-power lightweight face detection and tracking method, comprising the following steps:

[0006] S1, using the camera to collect face images, and initialize the highest resolution and frame rate;

[0007] S2, adaptively adjust the resolution of the collected face image, process it through the face detection model, identify the face in the image through the face detection model, and output the face detection confidence and face detection frame;

[0008] S3, adjusting the resolution according to the face confidence; if the confidence is high, the face detection is accurate and the resolution is reduced; otherwise, the resolution is increased to ensure accurate detection;

[0009] S4, using a face detection and tracking algorithm to track the detected face in consecutive frames;

[0010] S5, analyzing the face tracking results and making adaptive adjustments to the frame rate; if the face moves slowly or is prohibited, the frame rate will be reduced; if the face changes between frames or is not tracked, the frame rate will be increased;

[0011] S6. Output the adjusted frame rate to the camera to collect the face image, and execute steps S2 to S5 in a loop to achieve adaptive adjustment of the resolution and frame rate.

[0012] The system of the present invention adopts the following technical solutions to achieve: a low-power lightweight face detection and tracking system, comprising:

[0013] Initialization module: collects face images using the camera and initializes the high resolution and frame rate;

[0014] Resolution adaptive adjustment module: used to perform resolution adaptive adjustment on the collected face images, process them through the face detection model, identify the faces in the images through the face detection model, and output the face detection confidence and face detection frame;

[0015] Face confidence adjustment module: adjusts the resolution according to the face confidence; if the confidence is high, the face detection is accurate and the resolution is reduced; otherwise, the resolution is increased to ensure accurate detection;

[0016] Tracking module: Tracks the detected face in consecutive frames by using face detection and tracking algorithm;

[0017] Analysis module: used to analyze face tracking results and perform adaptive frame rate adjustment; if the face moves slowly or is prohibited, the frame rate will be reduced; if the face changes between frames or is not tracked, the frame rate will be increased;

[0018] Output module: used to output the adjusted frame rate to the camera to collect face images, and cyclically execute the resolution adaptive adjustment module and analysis module to achieve adaptive adjustment of resolution and frame rate.

[0019] Compared with the prior art, the present invention has the following advantages and beneficial effects:

[0020] 1. The present invention reduces unnecessary judgment steps in the process of living body detection and face recognition by dynamically adjusting the frame rate and resolution, thereby reducing the response time delay, and can speed up the entire process from detecting a living target to completing face recognition, thereby improving the user experience in practical applications.

[0021] 2. The present invention does not rely on specific hardware such as flat-panel radar to determine living targets, but dynamically adjusts processing parameters through intelligent software algorithms, thereby reducing the impact of environmental factors and improving the applicability and robustness of the system.

[0022] 3. The present invention aims to reduce the overall hardware cost by optimizing software algorithms instead of relying on expensive hardware, such as thermal infrared and high-resolution visible light camera systems; at the same time, by reducing the complexity of the system, the present invention also helps to reduce the difficulty and cost of maintenance.

[0023] 4. The present invention uses an adaptive adjustment strategy to adjust the frame rate and resolution according to actual conditions while maintaining low power consumption, thereby ensuring the accuracy of face detection and tracking. This method is superior to methods that rely on fixed algorithms and hardware settings, and can better adapt to different environmental conditions and face changes.

[0024] 5. The adaptive adjustment mechanism of the present invention can dynamically optimize the recognition and tracking strategies in the entire video sequence and maintain a high tracking accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0025] Figure 1 It is a flow chart of the method of the present invention. DETAILED DESCRIPTION

[0026] The present invention is further described in detail below in conjunction with embodiments and drawings, but the embodiments of the present invention are not limited thereto.

[0027] Example

[0028] like Figure 1 As shown, this embodiment provides a low-power lightweight face detection and tracking method, comprising the following steps:

[0029] S1, using the camera to collect face images, and initialize the high resolution and frame rate;

[0030] S2, adaptively adjust the resolution of the collected face image, process it through the face detection model, identify the face in the image through the face detection model, and output the face detection confidence and face detection frame;

[0031] S3, adjusting the resolution according to the face confidence; if the confidence is high, the face detection is accurate and the resolution is reduced; otherwise, the resolution is increased to ensure accurate detection;

[0032] S4, using a face detection and tracking algorithm to track the detected face in consecutive frames;

[0033] S5, analyzing the face tracking results and making adaptive adjustments to the frame rate; if the face moves slowly or is prohibited, the frame rate will be reduced; if the face changes between frames or is not tracked, the frame rate will be increased;

[0034] S6. Output the adjusted frame rate to the camera to collect the face image, and execute steps S2 to S5 in a loop to achieve adaptive adjustment of the resolution and frame rate.

[0035] Specifically, in this embodiment, the process of adaptively adjusting the resolution in step S2 is as follows:

[0036] S21, set the initial high resolution r0, collect face images through the camera, and output the confidence C through the face detection model t , which indicates the accuracy of face detection in the current frame. The Kalman filter gain E is introduced in the face detection process. t , improve the accuracy of resolution adjustment, set r t For the adjusted resolution, adjust according to formula (1):

[0037]

[0038] Among them, r t-1 is the resolution of the previous frame; β is the adjustment factor used to control the confidence C t and Kalman filter gain E t The degree of impact on resolution adjustment;

[0039] S22, according to the confidence C t and Kalman filter gain E t Adjust the resolution if the resolution decays over time If it is greater than the initial resolution r0, it is set to the upper limit, which cannot be exceeded; if the attenuated resolution is less than 0.125r0, one eighth of the initial resolution r0, it is set to the lower limit, which cannot be lower than this lower limit; in other cases, the resolution continues to decay gradually.

[0040] Specifically, the face detection model in step S2 is a lightweight face detection neural network trained based on the lightweight deep learning framework Caffe, and network lightweight operation based on embedded devices is achieved by pruning the network and designing a dropout layer.

[0041] Specifically, in this embodiment, the process of adaptively adjusting the frame rate in step S5 is as follows:

[0042] S51. Design a mathematical model of the time-based attenuation function and set the initial maximum frame rate fps o , initial maximum frame rate fps o Multiply by the decay factor, over time, the frame rate fps t Adjust according to formula (2):

[0043]

[0044] Among them, K is the preset minimum frame rate; fps t0 is the initial value that the frame rate maintains when there is no significant movement or change; x t and x t-1 is the x coordinate of the face center point of the current frame and the previous frame; y t and t-1 is the y coordinate of the face center point in the current frame and the previous frame; δ1 is the preset threshold of the change in the face center point coordinate, used to determine whether the face has moved significantly; w t and w t-1 is the width of the detection frame of the current frame and the previous frame; δ2 is the preset threshold of the change in face width, which is used to determine whether the face width has changed significantly; h t and h t-1 is the height of the face detection frame of the current frame and the previous frame; δ3 is the preset threshold of the face height change, which is used to determine whether the face height has changed significantly;

[0045] S52, if the face center coordinates (x t ,y t) exceeds the preset threshold δ1, it indicates that the face has moved significantly, and the frame rate is immediately adjusted back to the initial maximum frame rate fps o ; If the face detection frame width w of the current frame t t or height h t If the change from the previous frame t-1 exceeds the preset threshold δ2 or δ3, it also means that the face has changed significantly. Similarly, the frame rate is immediately adjusted back to the initial maximum frame rate fps. o ; In other cases, the frame rate gradually decreases according to the attenuation function, from the initial highest frame rate fps o , attenuation coefficient α and time t. As time increases, the frame rate gradually converges to the preset minimum frame rate K value.

[0046] Based on the same inventive concept, the present invention also provides a low-power lightweight face detection and tracking system, comprising:

[0047] Initialization module: collects face images using the camera and initializes the high resolution and frame rate;

[0048] Resolution adaptive adjustment module: used to perform resolution adaptive adjustment on the collected face images, process them through the face detection model, identify the faces in the images through the face detection model, and output the face detection confidence and face detection frame;

[0049] Face confidence adjustment module: adjusts the resolution according to the face confidence; if the confidence is high, the face detection is accurate and the resolution is reduced; otherwise, the resolution is increased to ensure accurate detection;

[0050] Tracking module: Tracks the detected face in consecutive frames by using face detection and tracking algorithm;

[0051] Analysis module: used to analyze face tracking results and perform adaptive frame rate adjustment; if the face moves slowly or is prohibited, the frame rate will be reduced; if the face changes between frames or is not tracked, the frame rate will be increased;

[0052] Output module: used to output the adjusted frame rate to the camera to collect face images, and cyclically execute the resolution adaptive adjustment module and analysis module to achieve adaptive adjustment of resolution and frame rate.

[0053] Specifically, in this embodiment, the implementation process of the resolution adaptive adjustment in the resolution adaptive adjustment module is as follows:

[0054] Set the initial high resolution r0, collect face images through the camera, and output the confidence C through the face detection model t , which indicates the accuracy of face detection in the current frame. The Kalman filter gain E is introduced in the face detection process. t, improve the accuracy of resolution adjustment, set r t For the adjusted resolution, adjust according to formula (1):

[0055]

[0056] Among them, r t-1 is the resolution of the previous frame; β is the adjustment factor used to control the confidence C t and Kalman filter gain E t The degree of impact on resolution adjustment;

[0057] According to the confidence level C t and Kalman filter gain E t Adjust the resolution if the resolution decays over time If it is greater than the initial resolution r0, it is set to the upper limit, which cannot be exceeded; if the attenuated resolution is less than 0.125r0, one eighth of the initial resolution r0, it is set to the lower limit, which cannot be lower than this lower limit; in other cases, the resolution continues to decay gradually.

[0058] Specifically, in this embodiment, the face detection model in the resolution adaptive adjustment module is a lightweight face detection neural network trained based on the lightweight deep learning framework Caffe, and network lightweight operation based on embedded devices is achieved by pruning the network and designing a dropout layer.

[0059] Specifically, in this embodiment, the implementation process of the frame rate adaptive adjustment in the analysis module is:

[0060] S51. Design a mathematical model of the time-based attenuation function and set the initial maximum frame rate fps o , initial maximum frame rate fps o Multiply by the decay factor, over time, the frame rate fps t Adjust according to formula (2):

[0061]

[0062] Among them, K is the preset minimum frame rate; fps t0 is the initial value that the frame rate maintains when there is no significant movement or change; x t and x t-1 is the x coordinate of the face center point of the current frame and the previous frame; y t and t-1 is the y coordinate of the face center point in the current frame and the previous frame; δ1 is the preset threshold of the change in the face center point coordinate, used to determine whether the face has moved significantly; w t and w t-1is the width of the detection frame of the current frame and the previous frame; δ2 is the preset threshold of the change in face width, which is used to determine whether the face width has changed significantly; h t and h t-1 is the height of the face detection frame of the current frame and the previous frame; δ3 is the preset threshold of the face height change, which is used to determine whether the face height has changed significantly;

[0063] S52, if the face center coordinates (x t ,y t ) exceeds the preset threshold δ1, it indicates that the face has moved significantly, and the frame rate is immediately adjusted back to the initial maximum frame rate fps o ; If the face detection frame width w of the current frame t t or height h t If the change from the previous frame t-1 exceeds the preset threshold δ2 or δ3, it also means that the face has changed significantly. Similarly, the frame rate is immediately adjusted back to the initial maximum frame rate fps. o ; In other cases, the frame rate gradually decreases according to the attenuation function, from the initial highest frame rate fps o , attenuation coefficient α and time t. As time increases, the frame rate gradually converges to the preset minimum frame rate K value.

[0064] The above embodiments are preferred implementation modes of the present invention, but the implementation modes of the present invention are not limited to the above embodiments. Any other changes, modifications, substitutions, combinations, and simplifications that do not deviate from the spirit and principles of the present invention should be equivalent replacement methods and are included in the protection scope of the present invention.

Claims

1. A low-power and lightweight face detection and tracking method, characterized in that: The following steps are involved: S1, using the camera to collect face images, and initialize the high resolution and frame rate; S2, adaptively adjust the resolution of the collected face image, process it through the face detection model, identify the face in the image through the face detection model, and output the face detection confidence and face detection frame; S3, adjusting the resolution according to the face confidence; if the confidence is high, the face detection is accurate and the resolution is reduced; otherwise, the resolution is increased to ensure accurate detection; S4, using a face detection and tracking algorithm to track the detected face in consecutive frames; S5, analyzing the face tracking results and performing adaptive frame rate adjustment; If the face moves slowly or is prohibited, the frame rate will be reduced. If the face changes between frames or is not tracked, the frame rate will be increased. S6. Output the adjusted frame rate to the camera to collect the face image, and execute steps S2 to S5 in a loop to achieve adaptive adjustment of the resolution and frame rate.

2. A low-power lightweight face detection and tracking method according to claim 1, characterized in that: The process of adaptive resolution adjustment in step S2 is as follows: S21, set the initial high resolution r0, collect face images through the camera, and output the confidence C through the face detection model t , which indicates the accuracy of face detection in the current frame. The Kalman filter gain E is introduced in the face detection process. t , improve the accuracy of resolution adjustment, set r t For the adjusted resolution, adjust according to formula (1): Among them, r t-1 is the resolution of the previous frame; β is the adjustment factor used to control the confidence C t and Kalman filter gain E t The degree of impact on resolution adjustment; S22, according to the confidence C t and Kalman filter gain E t Adjust the resolution if the resolution decays over time If it is greater than the initial resolution r0, it is set to the upper limit, which cannot be exceeded; if the attenuated resolution is less than 0.125r0, one eighth of the initial resolution r0, it is set to the lower limit, which cannot be lower than this lower limit; in other cases, the resolution continues to decay gradually.

3. A low-power lightweight face detection and tracking method according to claim 1, characterized in that: The face detection model in step S2 is a lightweight face detection neural network trained based on the lightweight deep learning framework Caffe. By pruning the network and designing the dropout layer, lightweight network operation based on embedded devices is achieved.

4. The low-power lightweight face detection and tracking method according to claim 1, characterized in that: The process of frame rate adaptive adjustment in step S5 is specifically as follows: S51. Design a mathematical model of the time-based attenuation function and set the initial maximum frame rate fps o , initial maximum frame rate fps o Multiply by the decay factor, over time, the frame rate fps t Adjust according to formula (2): Among them, K is the preset minimum frame rate; fps t0 is the initial value that the frame rate maintains when there is no significant movement or change; x t and x t-1 is the x coordinate of the face center point of the current frame and the previous frame; y t and t-1 is the y coordinate of the face center point in the current frame and the previous frame; δ1 is the preset threshold of the change in the face center point coordinate, used to determine whether the face has moved significantly; w t and w t-1 is the width of the detection frame of the current frame and the previous frame; δ t is the preset threshold of the face width change, used to determine whether the face width has changed significantly; h t and h t-1 is the height of the face detection frame of the current frame and the previous frame; δ3 is the preset threshold of the face height change, which is used to determine whether the face height has changed significantly; S52, if the face center coordinates (x t ,y t ) exceeds the preset threshold δ1, it indicates that the face has moved significantly, and the frame rate is immediately adjusted back to the initial maximum frame rate fps o ; If the face detection frame width w of the current frame t t or height h t If the change from the previous frame t-1 exceeds the preset threshold δ2 or δ3, the face has changed significantly, and the frame rate is immediately adjusted back to the initial maximum frame rate fps. o ; In other cases, the frame rate gradually decreases according to the attenuation function, from the initial highest frame rate fps o , attenuation coefficient α and time t. As time increases, the frame rate gradually converges to the preset minimum frame rate K value.

5. A low-power lightweight face detection and tracking system, characterized in that: include: Initialization module: collects face images using the camera and initializes the high resolution and frame rate; Resolution adaptive adjustment module: used to perform resolution adaptive adjustment on the collected face images, process them through the face detection model, identify the faces in the images through the face detection model, and output the face detection confidence and face detection frame; Face confidence adjustment module: adjusts the resolution according to the face confidence; if the confidence is high, the face detection is accurate and the resolution is reduced; otherwise, the resolution is increased to ensure accurate detection; Tracking module: Tracks the detected face in consecutive frames by using face detection and tracking algorithm; Analysis module: used to analyze face tracking results and perform adaptive frame rate adjustment; If the face moves slowly or is prohibited, the frame rate will be reduced. If the face changes between frames or is not tracked, the frame rate will be increased. Output module: used to output the adjusted frame rate to the camera to collect face images, and cyclically execute the resolution adaptive adjustment module and analysis module to achieve adaptive adjustment of resolution and frame rate.

6. A low-power, lightweight face detection and tracking system according to claim 5, characterized in that: The implementation process of resolution adaptive adjustment in the resolution adaptive adjustment module is as follows: Set the initial high resolution r0, collect face images through the camera, and output the confidence C through the face detection model t , which indicates the accuracy of face detection in the current frame. The Kalman filter gain E is introduced in the face detection process. t , improve the accuracy of resolution adjustment, r t For the adjusted resolution, adjust according to formula (1): Among them, r t-1 is the resolution of the previous frame; β is the adjustment factor used to control the confidence C t and Kalman filter gain E t The degree of impact on resolution adjustment; According to the confidence level C t and Kalman filter gain E t Adjust the resolution if the resolution decays over time If it is greater than the initial resolution r0, it is set to the upper limit, which cannot be exceeded; if the attenuated resolution is less than 0.125r0, one eighth of the initial resolution r0, it is set to the lower limit, which cannot be lower than this lower limit; in other cases, the resolution continues to decay gradually.

7. A low-power, lightweight face detection and tracking system according to claim 5, characterized in that: The face detection model in the resolution adaptive adjustment module is a lightweight face detection neural network trained based on the lightweight deep learning framework Caffe. By pruning the network and designing the dropout layer, lightweight network operation based on embedded devices is achieved.

8. The low-power lightweight face detection and tracking system according to claim 5, characterized in that: The implementation process of frame rate adaptive adjustment in the analysis module is as follows: S51. Design a mathematical model of the time-based attenuation function and set the initial maximum frame rate fps o , initial maximum frame rate fps o Multiply by the decay factor, over time, the frame rate fps t Adjust according to formula (2): Among them, K is the preset minimum frame rate; fps t0 is the initial value that the frame rate maintains when there is no significant movement or change; x t and x t-1 is the x coordinate of the face center point of the current frame and the previous frame; y t and t-1 is the y coordinate of the face center point in the current frame and the previous frame; δ1 is the preset threshold of the change in the face center point coordinate, used to determine whether the face has moved significantly; w t and w t-1 is the width of the detection frame of the current frame and the previous frame; δ2 is the preset threshold of the change in face width, which is used to determine whether the face width has changed significantly; h t and h t-1 is the height of the face detection frame of the current frame and the previous frame; δ3 is the preset threshold of the face height change, which is used to determine whether the face height has changed significantly; S52, if the face center coordinates (x t ,y t ) exceeds the preset threshold δ1, it indicates that the face has moved significantly, and the frame rate is immediately adjusted back to the initial maximum frame rate fps o ; If the face detection frame width w of the current frame t t or height h t If the change from the previous frame t-1 exceeds the preset threshold δ2 or δ3, the face has changed significantly, and the frame rate is immediately adjusted back to the initial maximum frame rate fps. o ; In other cases, the frame rate gradually decreases according to the attenuation function, from the initial highest frame rate fps o , attenuation coefficient α and time t. As time increases, the frame rate gradually converges to the preset minimum frame rate K value.

Citation Information

Cited By

  • Dense crowd face detection method in complex environment

    CN119206826A

  • Face detection method for dense crowd in complex environment

    CN119206826B

  • Face recognition tracking method based on video understanding

    CN119919985A

  • Digital multimeter reading identification method

    CN122157223A