Face recognition method and system and storage medium
By combining the use of color RGB and infrared IR video streams in the face recognition system, the problem of inaccurate face recognition in the dark environment of the existing technology is solved, and effective face recognition in low-illumination environments is achieved, improving Passive efficiency.
Patent Information
- Application Number
- CN202411036069.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-31
- Publication Date
- 2024-11-29
AI Technical Summary
Existing binocular face recognition devices are susceptible to the environment in dark environments at night. If a camera fails or the conditions do not meet the requirements, the face cannot be correctly recognized, resulting in poor face passing experience.
Two face recognition methods are adopted in color RGB video stream and infrared IR video stream, and color RGB video stream is preferred for face recognition. Only when color RGB video stream recognition is unsuccessful, infrared IR video stream is enabled for recognition. Video streams perform effective face recognition in low-illumination environments.
Improves personnel traffic efficiency and ensures accurate facial recognition can be achieved even in the case of poorer ambient illumination.
Smart Images

Figure CN119049103A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of face recognition technology, and in particular to a face recognition method, system and storage medium. Background Art
[0002] The common binocular face recognition devices on the market currently have one camera for liveness detection and the other for face recognition. The two cameras need to work together to correctly recognize faces and pass through. This method is easily affected by the environment, and if one camera fails or the working conditions do not meet the requirements, it is easy to fail to correctly recognize faces, especially in dark environments at night, resulting in a poor face passage experience. Summary of the invention
[0003] In view of this, an object of the present invention is to provide a face recognition method, system and storage medium.
[0004] In order to achieve the above object, the technical solution adopted by the present invention is: A face recognition method comprises the following steps: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
[0005] Furthermore, step S1 specifically includes: S11, obtaining a color RGB video stream, extracting data corresponding to preset key points in face data from the color RGB video stream, and calculating a corresponding first key point extraction score based on the data; S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; S13, performing angle detection on the face data to obtain a corresponding first face angle value; S14, determining whether the first face angle value is greater than a second preset threshold, if so, executing step S15; S15, performing blur detection on the face data to obtain a corresponding first face blur score; S16, determining whether the blurriness score of the first face is less than a third preset threshold, if so, executing step S17; S17, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than a fourth preset threshold, if yes, executing step S18; S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
[0006] Furthermore, step S3 specifically includes: S31, obtaining an infrared IR video stream, extracting data corresponding to preset key points in face data from the infrared IR video stream, and calculating a corresponding second key point extraction score based on the data; S32, determining whether the second key point extraction score is greater than a fifth preset threshold, if so, executing step S33; S33, performing angle detection on the face data to obtain a corresponding second face angle value; S34, determining whether the second face angle value is greater than a sixth preset threshold, if so, executing step S35; S35, performing blur detection on the face data to obtain a corresponding second face blur score; S36, determining whether the blur score of the second face is less than a seventh preset threshold, if so, executing step S37; S37, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than an eighth preset threshold, if so, executing step S38; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
[0007] Furthermore, step S37 also includes: If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained, and it is determined whether the face liveness score is greater than the ninth preset threshold. If so, video feature data is extracted and it is determined whether the face threshold is greater than the eighth preset threshold. If so, step S38 is executed.
[0008] A face recognition system includes a processor and a memory, wherein the memory stores a program or an instruction, and when the program or the instruction is executed by the processor, the following steps are implemented: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
[0009] Furthermore, when the program or instruction is executed by the processor, the following steps are specifically implemented: S11, obtaining a color RGB video stream, extracting data corresponding to preset key points in face data from the color RGB video stream, and calculating a corresponding first key point extraction score based on the data; S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; S13, performing angle detection on the face data to obtain a corresponding first face angle value; S14, determining whether the first face angle value is greater than a second preset threshold, if so, executing step S15; S15, performing blur detection on the face data to obtain a corresponding first face blur score; S16, determining whether the blurriness score of the first face is less than a third preset threshold, if so, executing step S17; S17, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than a fourth preset threshold, if yes, executing step S18; S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
[0010] Furthermore, when the program or instruction is executed by the processor, the following steps are specifically implemented: S31, obtaining an infrared IR video stream, extracting data corresponding to preset key points in face data from the infrared IR video stream, and calculating a corresponding second key point extraction score based on the data; S32, determining whether the second key point extraction score is greater than a fifth preset threshold, if so, executing step S33; S33, performing angle detection on the face data to obtain a corresponding second face angle value; S34, determining whether the second face angle value is greater than a sixth preset threshold, if so, executing step S35; S35, performing blur detection on the face data to obtain a corresponding second face blur score; S36, determining whether the blur score of the second face is less than a seventh preset threshold, if so, executing step S37; S37, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than an eighth preset threshold, if so, executing step S38; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
[0011] Furthermore, when the program or instruction is executed by the processor, the following steps are also implemented: If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained, and it is determined whether the face liveness score is greater than the ninth preset threshold. If so, video feature data is extracted and it is determined whether the face threshold is greater than the eighth preset threshold. If so, step S38 is executed.
[0012] A computer storage medium comprises: a readable storage medium and a computer program, wherein the computer program is used to implement the face recognition method.
[0013] The beneficial effects of the present invention are: The present invention provides a face recognition method, system and storage medium, which use an infrared IR video stream that was originally only used for liveness detection for face recognition, thereby realizing a two-way face recognition mode of a color RGB video stream and an infrared IR video stream, and preferentially using the color RGB video stream for face recognition. Only when the face recognition of the color RGB video stream is unsuccessful, that is, no face data is recognized, is the infrared IR video stream enabled for face recognition. Since the infrared IR video stream can perform effective face recognition under conditions of worse ambient illumination, the efficiency of personnel passage is improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] Figure 1 Shown is a flow chart of steps of a face recognition method of the present invention; Figure 2 Shown is a structural block diagram of a face recognition system of the present invention; Description of Figure Numbers: 1-Processor; 2-Memory. DETAILED DESCRIPTION
[0015] The present invention is further described below in conjunction with the accompanying drawings and specific embodiments: like Figure 1 As shown, the present invention provides a face recognition method, comprising the following steps: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
[0016] From the above description, it can be seen that the present invention has the following beneficial effects: The present invention provides a face recognition method, which uses an infrared IR video stream that was originally only used for liveness detection for face recognition, thereby realizing a two-way face recognition method of a color RGB video stream and an infrared IR video stream, and preferentially uses the color RGB video stream for face recognition. Only when the face recognition of the color RGB video stream is unsuccessful, that is, no face data is recognized, is the infrared IR video stream enabled for face recognition. Since the infrared IR video stream can perform effective face recognition under conditions of worse ambient illumination, the efficiency of personnel passage is improved.
[0017] Furthermore, step S1 specifically includes: S11, obtaining a color RGB video stream, extracting data corresponding to preset key points in face data from the color RGB video stream, and calculating a corresponding first key point extraction score based on the data; S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; S13, performing angle detection on the face data to obtain a corresponding first face angle value; S14, determining whether the first face angle value is greater than a second preset threshold, if so, executing step S15; S15, performing blur detection on the face data to obtain a corresponding first face blur score; S16, determining whether the blurriness score of the first face is less than a third preset threshold, if so, executing step S17; S17, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than a fourth preset threshold, if yes, executing step S18; S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
[0018] From the above description, it can be seen that the specific process of color RGB face recognition is realized through the above method, which includes key point extraction, angle detection, fuzzy detection and face threshold judgment. Through this series of judgments, face data with a high face recognition success rate is screened out, thereby improving the efficiency of personnel passage.
[0019] Furthermore, step S3 is specifically as follows: S31, obtaining an infrared IR video stream, extracting data corresponding to preset key points in face data from the infrared IR video stream, and calculating a corresponding second key point extraction score based on the data; S32, determining whether the second key point extraction score is greater than a fifth preset threshold, if so, executing step S33; S33, performing angle detection on the face data to obtain a corresponding second face angle value; S34, determining whether the second face angle value is greater than a sixth preset threshold, if so, executing step S35; S35, performing blur detection on the face data to obtain a corresponding second face blur score; S36, determining whether the blur score of the second face is less than a seventh preset threshold, if so, executing step S37; S37, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than an eighth preset threshold, if so, executing step S38; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
[0020] From the above description, it can be seen that the specific process of infrared IR face recognition is realized through the above method, which includes key point extraction, angle detection, fuzzy detection and face threshold judgment. Through this series of judgments, face data with a high face recognition success rate is screened out, thereby improving the efficiency of personnel passage.
[0021] Furthermore, step S37 also includes: If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained, and it is determined whether the face liveness score is greater than the ninth preset threshold. If so, video feature data is extracted and it is determined whether the face threshold is greater than the eighth preset threshold. If so, step S38 is executed.
[0022] From the above description, it can be seen that the face liveness detection function is realized through the above method.
[0023] See also Figure 2 The present invention also provides a face recognition system, including a processor and a memory, wherein the memory stores a program or instruction, and when the program or instruction is executed by the processor, the following steps are implemented: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
[0024] From the above description, it can be seen that the present invention has the following beneficial effects: The present invention provides a face recognition system, which uses an infrared IR video stream that was originally only used for liveness detection for face recognition, thereby realizing a two-way face recognition method of a color RGB video stream and an infrared IR video stream, and preferentially uses the color RGB video stream for face recognition. Only when the face recognition of the color RGB video stream is unsuccessful, that is, no face data is recognized, is the infrared IR video stream enabled for face recognition. Since the infrared IR video stream can perform effective face recognition under conditions of worse ambient illumination, the efficiency of personnel passage is improved.
[0025] Furthermore, when the program or instruction is executed by the processor, the following steps are specifically implemented: S11, obtaining a color RGB video stream, extracting data corresponding to preset key points in face data from the color RGB video stream, and calculating a corresponding first key point extraction score based on the data; S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; S13, performing angle detection on the face data to obtain a corresponding first face angle value; S14, determining whether the first face angle value is greater than a second preset threshold, if so, executing step S15; S15, performing blur detection on the face data to obtain a corresponding first face blur score; S16, determining whether the blurriness score of the first face is less than a third preset threshold, if so, executing step S17; S17, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than a fourth preset threshold, if yes, executing step S18; S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
[0026] From the above description, it can be seen that the specific process of color RGB face recognition is realized through the above method, which includes key point extraction, angle detection, fuzzy detection and face threshold judgment. Through this series of judgments, face data with a high face recognition success rate is screened out, thereby improving the efficiency of personnel passage.
[0027] Furthermore, when the program or instruction is executed by the processor, the following steps are specifically implemented: S31, obtaining an infrared IR video stream, extracting data corresponding to preset key points in face data from the infrared IR video stream, and calculating a corresponding second key point extraction score based on the data; S32, determining whether the second key point extraction score is greater than a fifth preset threshold, if so, executing step S33; S33, performing angle detection on the face data to obtain a corresponding second face angle value; S34, determining whether the second face angle value is greater than a sixth preset threshold, if so, executing step S35; S35, performing blur detection on the face data to obtain a corresponding second face blur score; S36, determining whether the blur score of the second face is less than a seventh preset threshold, if so, executing step S37; S37, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than an eighth preset threshold, if so, executing step S38; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
[0028] From the above description, it can be seen that the specific process of face recognition is realized through the above method, which includes key point extraction, angle detection, fuzzy detection and face threshold judgment. Through this series of judgments, face data with a high face recognition success rate is screened out, thereby improving the efficiency of personnel passage.
[0029] Furthermore, when the program or instruction is executed by the processor, the following steps are also implemented: If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained, and it is determined whether the face liveness score is greater than the ninth preset threshold. If so, video feature data is extracted and it is determined whether the face threshold is greater than the eighth preset threshold. If so, step S38 is executed.
[0030] From the above description, it can be seen that the face liveness detection function is realized through the above method.
[0031] A computer storage medium comprises: a readable storage medium and a computer program, wherein the computer program is used to implement the face recognition method.
[0032] Several preferred embodiments or application examples are listed below to help those skilled in the art better understand the technical content of the present invention and the technical contribution made by the present invention relative to the prior art: Preferred embodiment one: This embodiment is mainly used in the entrance and exit access control products of the smart home system, especially in the application of the stair entrance machine of the smart home system unit or the entrance area machine of the community. The binocular face recognition device has one camera as a color RGB camera for obtaining a color RGB video stream, and the other camera as an infrared IR camera for obtaining an infrared IR video stream.
[0033] like Figure 1 As shown, the present invention provides a face recognition method, comprising the following steps: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; Specifically including S11-S18: S11, obtain a color RGB video stream, extract data corresponding to preset key points in the face data from the color RGB video stream, and calculate the corresponding first key point extraction score based on the data; wherein, the number of preset key points is 72, and the key point extraction score is the ratio of the number of key points extracted to the number of preset key points as the score of the face key points, so the range of the score is [0-1], the larger the score, the higher the credibility of the face, and the fifth preset threshold is set to 0.8. Of course, other algorithms can also be used to implement it.
[0034] S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; wherein the first preset threshold is set to 0.8; S13. Perform angle detection on the face data to obtain a corresponding first face angle value; wherein the angle detection is implemented using the Baidu face algorithm library, that is, it is implemented using existing technology, which will not be repeated here.
[0035] S14. Determine whether the first face angle value is greater than a second preset threshold. If so, execute step S15; wherein the second preset threshold is set to 20°.
[0036] S15, perform blur detection on the face data to obtain a corresponding first face blur score; wherein the blur detection is also implemented using the Baidu face algorithm library, that is, using the existing technology, which will not be repeated here. It should be noted that the range of the face blur score is [0-1], and the larger the score, the blurrier the face.
[0037] S16, determining whether the blur score of the first face is less than a third preset threshold value, if so, executing step S17; wherein the third preset threshold value is set to 0.8; S17, determine whether to enable liveness detection, if not, extract video feature data and determine whether the face threshold is greater than the fourth preset threshold, if so, execute step S18; wherein, feature comparison is implemented using Baidu face algorithm library, that is, it is implemented using existing technology, which will not be repeated here. This is to determine the feature data comparison similarity score and the preset face recognition threshold, the similarity range is [0-1], the larger the value, the more similar it is. Among them, the fourth preset threshold is set to 0.8.
[0038] S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
[0039] S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
[0040] Specifically including S31-S38: S31, obtain the infrared IR video stream, extract the data corresponding to the preset key points in the face data, and calculate the corresponding key point extraction score according to the data; wherein, the number of preset key points is 72, and the key point extraction score is the ratio of the number of key points extracted to the number of preset key points as the score of the face key points, so the range of the score is [0-1], the larger the score, the higher the credibility of the face, and the fifth preset threshold is set to 0.8. Of course, other algorithms can also be used to implement it.
[0041] S32, determining whether the key point extraction score is greater than a fifth preset threshold, if so, executing step S33; wherein the fifth preset threshold is set to 0.8; if not, returning to step S31; S33. Perform angle detection on the face data to obtain the corresponding face angle value; wherein, the angle detection is implemented using the Baidu face algorithm library, that is, it is implemented using existing technology, which will not be repeated here.
[0042] S34, determining whether the face angle value is greater than a sixth preset threshold value, if so, executing step S35; wherein the sixth preset threshold value is set to 20°; if not, returning to step S31; S35, perform blur detection on the face data to obtain the corresponding face blur score; wherein, blur detection is also implemented by using Baidu face algorithm library, that is, it is implemented by using existing technology, which will not be repeated here. It should be noted that the range of face blur score is [0-1], and the larger the score, the blurrier the face.
[0043] S36, determining whether the face blur score is less than a seventh preset threshold value, if so, executing step S37; wherein the seventh preset threshold value is set to 0.8; if not, returning to step S31; S37, determining whether to enable liveness detection; If liveness detection is not enabled, extract the video feature data and determine whether the face threshold is greater than the eighth preset threshold; if so, execute step S38; if the face threshold is not greater than the eighth preset threshold, return to step S31; wherein, feature comparison is implemented using Baidu face algorithm library, that is, using existing technology to achieve, no further description here. This is to determine the feature data comparison similarity score and the preset face recognition threshold, the similarity range is [0-1], the larger the value, the more similar it is.
[0044] If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained to determine whether the face liveness score is greater than the ninth preset threshold; the liveness score of a single face ranges from [0,1], the closer it is to 1, the higher the probability of a real person being alive, and the closer it is to 0, the higher the probability of a fake attack.
[0045] If the face liveness score is greater than the ninth preset threshold, extract the video feature data and determine whether the face threshold is greater than the eighth preset threshold. If the face threshold is greater than the eighth preset threshold, execute step S38; if the face threshold is not greater than the eighth preset threshold, return to step S31; If the face liveness score is not greater than the ninth preset threshold, return to step S31; Wherein, the eighth preset threshold and the ninth preset threshold are both set to 0.8; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
[0046] Through the above method, the specific process of face recognition is realized, which includes key point extraction, angle detection, fuzzy detection and face threshold judgment. Through this series of judgments, face data with a high face recognition success rate is screened out, thereby improving the efficiency of personnel passage.
[0047] Preferred embodiment 2: See also Figure 2 The present invention also provides a face recognition system, including a processor 1 and a memory 2, wherein the memory 2 stores a program or instruction, and when the program or instruction is executed by the processor 1, the following steps are implemented: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
[0048] Furthermore, when the program or instruction is executed by the processor, the following steps are specifically implemented: S11, obtaining a color RGB video stream, extracting data corresponding to preset key points in face data from the color RGB video stream, and calculating a corresponding first key point extraction score based on the data; S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; S13, performing angle detection on the face data to obtain a corresponding first face angle value; S14, determining whether the first face angle value is greater than a second preset threshold, if so, executing step S15; S15, performing blur detection on the face data to obtain a corresponding first face blur score; S16, determining whether the blurriness score of the first face is less than a third preset threshold, if so, executing step S17; S17, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than a fourth preset threshold, if yes, executing step S18; S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
[0049] Furthermore, when the program or instruction is executed by the processor, the following steps are specifically implemented: S31, obtaining an infrared IR video stream, extracting data corresponding to preset key points in face data from the infrared IR video stream, and calculating a corresponding second key point extraction score based on the data; S32, determining whether the second key point extraction score is greater than a fifth preset threshold, if so, executing step S33; S33, performing angle detection on the face data to obtain a corresponding second face angle value; S34, determining whether the second face angle value is greater than a sixth preset threshold, if so, executing step S35; S35, performing blur detection on the face data to obtain a corresponding second face blur score; S36, determining whether the blur score of the second face is less than a seventh preset threshold, if so, executing step S37; S37, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than an eighth preset threshold, if so, executing step S38; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
[0050] Furthermore, when the program or instruction is executed by the processor, the following steps are also implemented: If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained, and it is determined whether the face liveness score is greater than the ninth preset threshold. If so, video feature data is extracted and it is determined whether the face threshold is greater than the eighth preset threshold. If so, step S38 is executed.
[0051] Preferred embodiment three: A computer storage medium comprises: a readable storage medium and a computer program, wherein the computer program is used to implement the face recognition method.
[0052] The present invention has been described by the above-mentioned relevant embodiments and drawings, but the above-mentioned embodiments are only examples for implementing the present invention. It must be pointed out that the disclosed embodiments do not limit the scope of the present invention. On the contrary, modifications and equivalent settings included in the spirit and scope of the claims are all included in the scope of the present invention.
Claims
1. A face recognition method, characterized in that: The following steps are involved: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
2. A face recognition method according to claim 1, characterized in that: Step S1 specifically includes: S11, obtaining a color RGB video stream, extracting data corresponding to preset key points in face data from the color RGB video stream, and calculating a corresponding first key point extraction score based on the data; S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; S13, performing angle detection on the face data to obtain a corresponding first face angle value; S14, determining whether the first face angle value is greater than a second preset threshold, if so, executing step S15; S15, performing blur detection on the face data to obtain a corresponding first face blur score; S16, determining whether the blurriness score of the first face is less than a third preset threshold, if so, executing step S17; S17, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than a fourth preset threshold, if yes, executing step S18; S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
3. A face recognition method according to claim 2, characterized in that: Step S3 specifically includes: S31, obtaining an infrared IR video stream, extracting data corresponding to preset key points in face data from the infrared IR video stream, and calculating a corresponding second key point extraction score based on the data; S32, determining whether the second key point extraction score is greater than a fifth preset threshold, if so, executing step S33; S33, performing angle detection on the face data to obtain a corresponding second face angle value; S34, determining whether the second face angle value is greater than a sixth preset threshold, if so, executing step S35; S35, performing blur detection on the face data to obtain a corresponding second face blur score; S36, determining whether the blur score of the second face is less than a seventh preset threshold, if so, executing step S37; S37, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than an eighth preset threshold, if so, executing step S38; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
4. A face recognition method according to claim 3, characterized in that: Step S37 also includes: If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained, and it is determined whether the face liveness score is greater than the ninth preset threshold. If so, video feature data is extracted and it is determined whether the face threshold is greater than the eighth preset threshold. If so, step S38 is executed.
5. A face recognition system, characterized in that: The system comprises a processor and a memory, wherein the memory stores a program or an instruction, and when the program or the instruction is executed by the processor, the following steps are implemented: S1. Obtain a color RGB video stream, and perform face recognition through the color RGB video stream to obtain a face recognition result; S2, determining whether the face recognition result recognizes face data, if not, proceeding to step S3; S3. Obtain an infrared IR video stream and perform face recognition through the infrared IR video stream.
6. A face recognition system according to claim 5, characterized in that: When the program or instruction is executed by the processor, the following steps are specifically implemented: S11, obtaining a color RGB video stream, extracting data corresponding to preset key points in face data from the color RGB video stream, and calculating a corresponding first key point extraction score based on the data; S12, determining whether the first key point extraction score is greater than a first preset threshold, if so, executing step S13; S13, performing angle detection on the face data to obtain a corresponding first face angle value; S14, determining whether the first face angle value is greater than a second preset threshold, if so, executing step S15; S15, performing blur detection on the face data to obtain a corresponding first face blur score; S16, determining whether the blurriness score of the first face is less than a third preset threshold, if so, executing step S17; S17, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than a fourth preset threshold, if yes, executing step S18; S18. Obtain the personnel information corresponding to the facial data, complete the facial recognition, and obtain the corresponding facial recognition result.
7. A face recognition system according to claim 6, characterized in that: When the program or instruction is executed by the processor, the following steps are specifically implemented: S31, obtaining an infrared IR video stream, extracting data corresponding to preset key points in face data from the infrared IR video stream, and calculating a corresponding second key point extraction score based on the data; S32, determining whether the second key point extraction score is greater than a fifth preset threshold, if so, executing step S33; S33, performing angle detection on the face data to obtain a corresponding second face angle value; S34, determining whether the second face angle value is greater than a sixth preset threshold, if so, executing step S35; S35, performing blur detection on the face data to obtain a corresponding second face blur score; S36, determining whether the blur score of the second face is less than a seventh preset threshold, if so, executing step S37; S37, determining whether liveness detection is enabled, if not, extracting video feature data and determining whether the face threshold is greater than an eighth preset threshold, if so, executing step S38; S38. Obtain the personnel information corresponding to the facial data and complete the facial recognition.
8. A face recognition system according to claim 7, characterized in that: When the program or instruction is executed by the processor, the following steps are also implemented: If liveness detection is enabled, liveness detection is performed and the face liveness score is obtained, and it is determined whether the face liveness score is greater than the ninth preset threshold. If so, video feature data is extracted and it is determined whether the face threshold is greater than the eighth preset threshold. If so, step S38 is executed.
9. A computer storage medium, characterized in that include: A readable storage medium and a computer program, wherein the computer program is used to implement the face recognition method according to any one of claims 1 to 4.
