Human face liveness detection method and device, storage medium, and electronic device

Through the multi-task depth model, the recognition and fusion calculation of face images is solved, and the problems of high cost and low accuracy in the existing face live detection technology are achieved, and efficient, real-time and low-cost face live detection are achieved.

CN113033409BActive Publication Date: 2025-02-28BOE TECHNOLOGY GROUP CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202110325197.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-03-26
Publication Date
2025-02-28
Estimated Expiration
2041-03-26

AI Technical Summary

Technical Problem

Existing facial live detection technology has challenges in terms of cost and accuracy, especially in silent facial live detection, which has low accuracy and difficulty in obtaining depth images and infrared images, resulting in high costs.

Method used

The multi-task depth model is used to identify the aligned face images, obtain face clarity information, face angle information and preliminary facial recognition information, and determine whether the face is a living body through fusion calculation.

Benefits of technology

Without increasing costs, accurate facial liveness detection is achieved, improving user experience and effectively reducing equipment costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113033409B_ABST
    Figure CN113033409B_ABST
Patent Text Reader

Abstract

The present invention discloses a method and device for face liveness detection, a computer-readable storage medium, and an electronic device, wherein the face liveness detection method comprises the following steps: determining an aligned face image; inputting the aligned face image into a multi-task deep model for recognition to obtain multiple face recognition parameters; performing fusion calculation on the multiple face recognition parameters to obtain a fusion calculation result; and detecting whether the current face is a live face according to the fusion calculation result. Thus, the face liveness detection method can accurately and real-time detect whether the current face image is live without increasing the cost, thereby effectively improving the user experience.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of information recognition technology, and in particular to a method for detecting liveness of a human face, a computer-readable storage medium, an electronic device, and a device for detecting liveness of a human face. Background Art

[0002] In today's information age, personal information is very important, and with the increasing maturity of recognition technologies such as fingerprint recognition and face recognition, people's lives are becoming more and more convenient. Among them, face liveness recognition mainly refers to judging whether the input face image is a real face or a fake face. Fake faces mainly refer to printed photos, video playbacks, 3D simulation masks, etc. At present, face liveness detection has very important practical significance, such as gates, express cabinets, face attendance machines, software logins, etc. If there is no face liveness detection function, users will be able to use photos, video playbacks, or 3D masks to attack the system, which will have very serious consequences.

[0003] In the related art, face liveness detection is mainly divided into two types: cooperative face liveness detection and silent face liveness detection. Among them, the first method, cooperative face liveness detection, requires the user to cooperate with the software or system to make some pre-defined actions, such as shaking the head left and right, nodding up and down, blinking, etc. At present, the face login function of many applications adopts cooperative face liveness detection. However, this liveness detection method has its own defects. It takes about 5-20 seconds for the user to cooperate, which is difficult to use in some scenarios with high real-time requirements, such as gates or express cabinets. In this case, the software or system needs to quickly determine whether the user is a real person, and the user is generally unwilling to waste time to do some actions. The second face liveness detection method is silent liveness detection, that is, the user does not need to cooperate with the system to make fixed actions. This method is easy to use and has high real-time performance. However, silent liveness detection also has its own shortcomings: low accuracy, and faces challenges in some scenarios with high accuracy requirements. Therefore, researchers proposed to use RGB images, depth images, and infrared images to combine with each other to improve the accuracy of silent face liveness detection. This method can effectively improve the performance of face liveness detection. However, it is generally difficult to obtain depth images and infrared images, and special depth cameras and infrared cameras are required. At present, the depth cameras and infrared cameras on the market are generally expensive, costing thousands or even tens of thousands, which poses a challenge to some products that require low costs, such as gates or express lockers. Summary of the invention

[0004] The present invention aims to solve at least one of the technical problems in the related art to a certain extent. To this end, the first purpose of the present invention is to provide a face liveness detection method that can accurately and real-time detect whether the current face image is alive without increasing the cost, thereby effectively improving the user experience.

[0005] A second object of the present invention is to provide a computer-readable storage medium.

[0006] A third objective of the present invention is to provide an electronic device.

[0007] A fourth objective of the present invention is to provide a face liveness detection device.

[0008] To achieve the above-mentioned objectives, the first aspect of the present invention proposes a method for face liveness detection, which includes the following steps: determining an aligned face image; inputting the aligned face image into a multi-task deep model for recognition to obtain multiple face recognition parameters; performing fusion calculation on the multiple face recognition parameters to obtain a fusion calculation result; and detecting whether the current face is a live face based on the fusion calculation result.

[0009] The face liveness detection method of the embodiment of the present invention first determines an aligned face image, then inputs the aligned face image into a multi-task deep model for recognition to obtain multiple face recognition parameters, and then fuses and calculates the obtained multiple face recognition parameters to obtain a fusion calculation result, so that it can detect whether the current face is a live face according to the fusion calculation result. Therefore, the face liveness detection method can accurately and real-time detect whether the current face image is live without increasing the cost, effectively improving the user experience.

[0010] In addition, the method for detecting liveness of a face according to the above embodiment of the present invention may also have the following additional technical features:

[0011] In some embodiments of the present invention, the multiple face recognition parameters include face clarity information, face angle information and preliminary face liveness recognition information.

[0012] In some embodiments of the present invention, inputting the aligned face images into a multi-task deep model for recognition includes: using a basic network structure to perform deep learning on the aligned face images to obtain face feature information; performing a first convolution calculation on the face feature information to obtain a first convolution calculation result, and performing a second convolution calculation on the first convolution calculation result to obtain the face clarity information, and performing a third convolution calculation on the first convolution calculation result to obtain the preliminary face liveness recognition information; performing a fourth convolution calculation on the face feature information to obtain the face angle information.

[0013] In some embodiments of the present invention, the multiple face recognition parameters are fused and calculated according to the following formula: Score = S_face + W1*S_quality + W2*S_angle, wherein Score represents the fusion calculation result, S_face represents the confidence level of whether the face corresponding to the preliminary face liveness recognition information is alive, S_quality represents the face clarity score, S_angle represents face angle information, and W1 and W2 represent weight coefficients.

[0014] In some embodiments of the present invention, the weight coefficients W1 and W2 are both negative values.

[0015] In some embodiments of the present invention, the weight coefficients W1 and W2 are determined according to the multi-task deep model learning.

[0016] In some embodiments of the present invention, determining an aligned facial image includes: acquiring a facial image; and preprocessing the facial image to obtain the aligned facial image.

[0017] In some embodiments of the present invention, preprocessing the facial image includes: detecting feature points on the facial image, and performing facial alignment based on the detected feature points to obtain the aligned facial image.

[0018] In some embodiments of the present invention, before preprocessing the facial image, the method further includes: performing face detection based on the facial image to determine whether the size of the facial image meets a preset standard.

[0019] In some embodiments of the present invention, the facial image is acquired through an RGB camera.

[0020] To achieve the above objectives, a second aspect of the present invention provides a computer-readable storage medium on which a face liveness detection program is stored. When the face liveness detection program is executed by a processor, the face liveness detection method as described in the above embodiment is implemented.

[0021] According to the computer-readable storage medium of the embodiment of the present invention, the processor executes the face liveness detection program stored on the storage medium, which can accurately and real-time detect whether the current face image is alive without increasing the cost, thereby effectively improving the user experience.

[0022] To achieve the above-mentioned purpose, an embodiment of the third aspect of the present invention proposes an electronic device, which includes a memory, a processor, and a face liveness detection program stored in the memory and executable on the processor. When the processor executes the face liveness detection program, the face liveness detection method as described in the above embodiment is implemented.

[0023] The electronic device of the embodiment of the present invention includes a memory and a processor. The processor executes a face liveness detection program stored in the memory, and can accurately and real-time detect whether the current face image is alive without increasing the cost, thereby effectively improving the user experience.

[0024] To achieve the above-mentioned purpose, the fourth aspect of the embodiment of the present invention proposes a face liveness detection device, which includes a determination module for determining an aligned face image; a recognition module for inputting the aligned face image into a multi-task deep model for recognition to obtain multiple face recognition parameters; a fusion calculation module for performing fusion calculation on the multiple face recognition parameters to obtain a fusion calculation result; and a face liveness detection module for detecting whether the current face is a live face based on the fusion calculation result.

[0025] The face liveness detection device of the embodiment of the present invention includes a determination module, a recognition module, a fusion calculation module and a face liveness detection module, wherein the determination module is first used to determine whether the face image is aligned. If aligned, the aligned face image is input into the multi-task deep model through the recognition module for recognition to obtain multiple face recognition parameters, and then the fusion calculation module is used to perform fusion calculation on the multiple face recognition parameters to obtain a fusion calculation result, and then the face liveness detection module is used to detect whether the current face is a live face according to the fusion calculation result. Therefore, the face liveness detection device of this embodiment can accurately and real-time detect whether the current face image is live without increasing the cost, effectively improving the user experience.

[0026] Additional aspects and advantages of the present invention will be given in part in the following description and in part will be obvious from the following description, or will be learned through practice of the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] Figure 1 is a flow chart of a method for detecting live faces according to an embodiment of the present invention;

[0028] Figure 2 is a flow chart of a face preprocessing method according to another embodiment of the present invention;

[0029] Figure 3 is a flowchart of a multi-task deep model method according to another embodiment of the present invention;

[0030] Figure 4 is a structural block diagram of an electronic device according to an embodiment of the present invention;

[0031] Figure 5 is a structural block diagram of a face liveness detection device according to an embodiment of the present invention;

[0032] Figure 6 is a flowchart of a multi-task deep model method according to a specific embodiment of the present invention;

[0033] Figure 7 is a flowchart of a multi-task deep model method according to another specific embodiment of the present invention;

[0034] Figure 8 It is a flowchart of a multi-task depth model method according to another specific embodiment of the present invention. DETAILED DESCRIPTION

[0035] Embodiments of the present invention are described in detail below, examples of which are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present invention, and should not be construed as limiting the present invention.

[0036] The following describes a method and apparatus for detecting liveness of a face, a computer-readable storage medium, and an electronic device according to embodiments of the present invention with reference to the accompanying drawings.

[0037] Figure 1 The figure is a flow chart of a method for detecting living face according to an embodiment of the present invention.

[0038] like Figure 1 As shown, the present invention proposes a method for detecting liveness of a human face, and the method for detecting liveness of a human face comprises the following steps:

[0039] S10, determining the aligned face images.

[0040] First of all, during the face recognition process, it is necessary to ensure that the currently recognized face is in the recognition area. Taking the turnstile as an example, when the user passes through the turnstile, he needs to adjust his face to be in the shooting area of ​​the camera installed on the turnstile. In addition, since the physical features of users are different, the positions of tall, short, fat and thin users when passing through the same turnstile are also different. Therefore, before obtaining the user's face information, it is necessary to first ensure that the current face image has been aligned.

[0041] In some embodiments of the present invention, Figure 2 Determining the aligned face image may include the following steps: S201, acquiring a face image. S202, preprocessing the face image to obtain an aligned face image.

[0042] Specifically, in order to improve the speed of face recognition so that the camera that acquires the face image can quickly recognize the aligned face image, the embodiment can first acquire the face image, and then preprocess the face image to obtain the aligned face image. In this embodiment, preprocessing the face image can include detecting feature points on the face image, and then aligning the face according to the detected feature points to obtain the aligned face image. Specifically, feature point detection on the face image can detect whether the facial features of the face image are complete, and at the same time detect whether the face image contains the entire face of the user, such as whether it contains the chin part, the forehead part, etc. Specifically, the distance between the face image and the background image can be detected by color difference to determine whether it meets the preset distance to determine whether the current face image contains the entire face of the user.

[0043] It should be noted that the present embodiment can acquire facial images through an RGB camera, thereby greatly reducing the cost of the camera and making the facial liveness detection method more applicable. Moreover, in the present embodiment, before preprocessing the facial image, face detection can also be performed based on the facial image to determine whether the size of the facial image meets the preset standard.

[0044] Specifically, a threshold value may be preset, and then the size of the face image acquired by the RGB camera is compared with the threshold value to determine whether the size of the current face image meets the preset standard. It is understandable that if the size of the current face image meets the preset standard, the current face image may be preprocessed, otherwise, the current face image is not preprocessed and the user is reminded to adapt by adjusting the position.

[0045] S20, inputting the aligned face image into a multi-task deep model for recognition to obtain multiple face recognition parameters.

[0046] Specifically, after determining the aligned facial image, the facial image is recognized. The present embodiment recognizes the facial image through a multi-task deep model. It can be understood that the facial recognition parameters that can be obtained after recognizing the facial image through the multi-task deep model include facial clarity information, facial angle information and preliminary facial liveness recognition information.

[0047] It can be understood that after obtaining the face clarity information, it can be compared with the preset clarity to determine whether the currently aligned face image meets the requirements. Similarly, the face angle information and the face liveness preliminary recognition information can be compared with their respective set thresholds to determine whether the multiple face recognition parameters currently obtained meet the requirements. If not, it can be prompted that the subsequent steps cannot be performed and return to the previous step, that is, to obtain the aligned face image.

[0048] In a specific embodiment of the present invention, Figure 3 As shown, recognizing face images through a multi-task deep model includes:

[0049] S301, using a basic network structure to perform deep learning on the aligned face images to obtain facial feature information.

[0050] Specifically, the basic network in this embodiment can use the classic Resnet network or Mobilenet network as the Backbone network. Of course, the user can select different basic networks in combination with parameters such as the usage environment. After being processed by the basic network structure, the facial feature information in the current face image can be obtained.

[0051] S302, performing a first convolution calculation on the facial feature information to obtain a first convolution calculation result, performing a second convolution calculation on the first convolution calculation result to obtain facial clarity information, and performing a third convolution calculation on the first convolution calculation result to obtain preliminary facial liveness recognition information. S303, performing a fourth convolution calculation on the facial feature information to obtain facial angle information.

[0052] Specifically, Figure 6 As shown, after the face image has undergone deep learning of the basic network structure, the first convolution module can be used to calculate the face feature information to obtain the first convolution calculation result, and then the first convolution calculation result is calculated by the second convolution module and the third convolution module respectively to obtain the face clarity information and the face live preliminary recognition information, wherein the face clarity information can include two results of clear and blurred, and the face live preliminary recognition information can include two results of live and attack, wherein the attack indicates that the face is non-live, such as a photo. In this embodiment, the fourth convolution module is also used to perform a fourth convolution calculation on the face feature information to obtain the face angle information, wherein the face angle information can include normal angle, medium angle and large angle. It can be understood that different angles are respectively set with different thresholds for comparison. It should be noted that in the process of network training, the loss functions of the above four convolution modules can be obtained by a direct addition method.

[0053] More specifically, if Figure 7As shown, in this embodiment, the Backbone network selects the Resnet18 network as an example for description, wherein the aligned face size is 112×112×3. After being processed by the Resnet18 network, the feature layer can be converted into a 7×7×512 format, and then processed by the first convolution module, the second convolution module, the third convolution module and the fourth convolution module, and different face information is output according to different convolution modules. It should be noted that after the second convolution module, the third convolution module and the fourth convolution module are processed, adaptive average pooling processing can also be performed to further improve the accuracy of the processing results. In addition, it should be noted that each convolution module is provided with a vector convolution operation conv, a batch normalization processing module BN (Batch Normalization) and a rectified linear unit Relu (RectifiedLinearUnit). Furthermore, it can be verified through experiments that, Figure 8 As shown, for different tasks, the location of branch access can be appropriately adjusted.

[0054] S30, performing fusion calculation on multiple face recognition parameters to obtain a fusion calculation result.

[0055] Specifically, after obtaining multiple face recognition parameters, the multiple face recognition parameters can be fused and calculated. During the fusion process, the face size, face clarity and face angle can be judged. This is because in real scenes, the faces captured by the camera will meet the above three conditions. If the face in the face image is a fake face, such as a printed photo or video playback, it generally will not meet the requirements, so the requirement of excluding non-living faces can be met to a certain extent.

[0056] In one embodiment of the present invention, multiple face recognition parameters can be fused and calculated according to the following formula: Score = S_face + W1*S_quality + W2*S_angle, where Score represents the fusion calculation result, S_face represents the confidence level of whether the face corresponding to the initial face liveness recognition information is live, S_quality represents the score of face clarity, S_angle represents face angle information, and W1 and W2 represent weight coefficients. The weight coefficients W1 and W2 can be obtained through multi-task deep model training and learning.

[0057] Specifically, after obtaining the face clarity score and the face angle fusion score, a weight module is connected to the back of the network, such as connecting a fully connected layer (FC, Fully Connected layer). This layer mainly learns the fusion coefficient, that is, the weight coefficient.

[0058] Specifically, the parameters that the fully connected layer (FC) needs to learn mainly include the face clarity weight coefficient. The lower the learned face clarity, that is, the blurrier the face, the smaller the weight learned by the network; the clearer the face, the greater the weight learned by the network. It can be understood that when the face image is clearer, the learned weight is closer to 0.

[0059] More specifically, the parameters that the fully connected layer (FC) needs to learn also include the face angle weight coefficient, which mainly includes three parameters (normal angle, medium angle, and large angle). The model is integrated to obtain a face angle weight. When the face angle is larger, the learned weight is smaller; when the face angle is smaller, the learned weight is larger. It can be understood that when the face angle is smaller, the learned weight is closer to 0.

[0060] Specifically, it can be seen from the above formula that the fusion calculation result Score fully considers the multi-task depth model, preliminary face liveness recognition information, face clarity information and face angle information, thereby improving the accuracy of the fusion calculation result Score. In addition, in this embodiment, a preset value can be set for comparison with the fusion calculation result Score, so as to further judge whether the face in the current face image is a live face through the comparison result.

[0061] S40, detecting whether the current face is a living face according to the fusion calculation result.

[0062] Specifically, after obtaining the fusion calculation result Score, it is compared with the preset value. If the fusion calculation result Score is greater than the preset value, it indicates that the current face is a live face; if the fusion calculation result Score is less than the preset value, it indicates that the current face is a non-live face. If the current face is determined to be a live face, the next step of face image application, such as face recognition, can be performed; if the current face is determined to be a non-live face, a warning message can be issued to remind.

[0063] In summary, the face liveness detection method of the embodiment of the present invention can accurately and real-time detect whether the current face image is alive without increasing the cost, thereby effectively improving the user experience.

[0064] Furthermore, the present invention proposes a computer-readable storage medium on which a face liveness detection program is stored. When the face liveness detection program is executed by a processor, the face liveness detection method in the above embodiment is implemented.

[0065] The computer-readable storage medium of the embodiment of the present invention, the processor executes the face liveness detection program stored on the storage medium, can accurately and real-time detect whether the current face image is alive without increasing the cost, and effectively improve the user experience.

[0066] Figure 4 It is a structural block diagram of an electronic device according to an embodiment of the present invention.

[0067] Furthermore, if Figure 4 As shown, the present invention proposes an electronic device 10, which includes a memory 11, a processor 12, and a face liveness detection program stored in the memory 11 and executable on the processor 12. When the processor 12 executes the face liveness detection program, the face liveness detection method in the above embodiment is implemented.

[0068] The electronic device of the embodiment of the present invention includes a memory and a processor. The processor executes a face liveness detection program stored in the memory, and can accurately and real-time detect whether the current face image is alive without increasing the cost, thereby effectively improving the user experience.

[0069] Figure 5 It is a structural block diagram of a face liveness detection device according to an embodiment of the present invention.

[0070] Furthermore, if Figure 5 As shown, the present invention proposes a face liveness detection device 100, which includes a determination module 101, an identification module 102, a fusion calculation module 103 and a face liveness detection module 104, wherein the determination module 101 is used to determine the aligned face image; the identification module 102 is used to input the aligned face image into a multi-task deep model for identification to obtain multiple face recognition parameters; the fusion calculation module 103 is used to perform fusion calculation on the multiple face recognition parameters to obtain a fusion calculation result; the face liveness detection module 104 is used to detect whether the current face is a live face according to the fusion calculation result.

[0071] Specifically, see Figure 5 The face liveness detection device 100 includes a determination module 101, a recognition module 102, a fusion calculation module 103 and a face liveness detection module 104.

[0072] First, during the face recognition process, it is necessary to ensure that the currently recognized face is in the recognition area. Taking the turnstile as an example, when the user passes through the turnstile, the user needs to adjust his or her face to be in the shooting area of ​​the camera installed on the turnstile. In addition, since the user's physical features are different, the positions of tall, short, fat and thin users when passing through the same turnstile are also different. Therefore, before obtaining the user's face information, it is necessary to use the determination module 101 to determine whether the current face image has been aligned.

[0073] After determining the aligned face image, the recognition module 102 can be used to recognize the face image. In this embodiment, the face image is recognized by a multi-task depth model. It can be understood that the face recognition parameters that can be obtained after the face image is recognized by the multi-task depth model include face clarity information, face angle information, and face live preliminary recognition information. It can be understood that after obtaining the face clarity information, it can be compared with the preset clarity to determine whether the currently aligned face image meets the requirements. Similarly, the face angle information and the face live preliminary recognition information can be compared with their respective set thresholds, and then determine whether the multiple face recognition parameters currently obtained meet the requirements. If not, it can be prompted that the subsequent steps cannot be performed and return to the previous step, that is, the aligned face image is determined by the determination module 101.

[0074] After the recognition module 102 obtains multiple face recognition parameters, the fusion calculation module 103 can be used to perform fusion calculation on the multiple face recognition parameters to obtain a fusion calculation result. During the fusion process, the face liveness detection module 104 can be used to judge the face size, face clarity and face angle according to the fusion calculation result, and then judge whether the current face is a live face. Because in a real scene, the face collected by the camera will meet the above three conditions, and if the face in the face image is a fake face, such as a printed photo or video playback, it will generally not meet the requirements, so it can meet the requirements of excluding non-live faces to a certain extent. After obtaining the fusion calculation result through the fusion calculation module 103, the face liveness detection module 104 can also compare it with a preset value. If the fusion calculation result is greater than the preset value, it means that the current face is a live face; if the fusion calculation result is less than the preset value, it means that the current face is a non-live face. Among them, if it is determined that the current face is a living face, the next step of face image application, such as face recognition, can be carried out; if it is determined that the current face is not a living face, a warning message can be issued to remind.

[0075] In some embodiments of the present invention, the recognition module 102 is also used to: use the basic network structure to perform deep learning on the aligned face images to obtain face feature information; perform a first convolution calculation on the face feature information to obtain a first convolution calculation result, and perform a second convolution calculation on the first convolution calculation result to obtain face clarity information, and perform a third convolution calculation on the first convolution calculation result to obtain preliminary face liveness recognition information; perform a fourth convolution calculation on the face feature information to obtain face angle information.

[0076] In some embodiments of the present invention, the fusion calculation module 103 performs fusion calculation on multiple face recognition parameters according to the following formula: Score = S_face + W1*S_quality + W2*S_angle, wherein Score represents the fusion calculation result, S_face represents the confidence level of whether the face corresponding to the preliminary face liveness recognition information is alive, S_quality represents the face clarity score, S_angle represents the face angle information, and W1 and W2 represent weight coefficients.

[0077] In some embodiments of the present invention, the weight coefficients W1 and W2 are both negative values.

[0078] In some embodiments of the present invention, weight coefficients W1 and W2 are determined according to a multi-task deep model.

[0079] In some embodiments of the present invention, the determination module 101 is further used to: obtain a face image; and pre-process the face image to obtain an aligned face image.

[0080] In some embodiments of the present invention, the determination module 101 pre-processes the face image, including: detecting feature points on the face image, and performing face alignment according to the detected feature points to obtain an aligned face image.

[0081] In some embodiments of the present invention, before preprocessing the facial image, the determination module 101 further includes: performing face detection according to the facial image to determine whether the size of the facial image meets a preset standard.

[0082] In some embodiments of the present invention, a facial image is acquired through an RGB camera.

[0083] It should be noted that the specific implementation of the face liveness detection device in the embodiment of the present invention can refer to the specific implementation of the face liveness detection method in the above embodiment, which will not be repeated here.

[0084] In summary, the face liveness detection device of the embodiment of the present invention can accurately and in real time detect whether the current face image is alive without increasing the cost, thereby effectively improving the user experience.

[0085] It should be noted that the logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be specifically implemented in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute instructions), or in combination with these instruction execution systems, devices or apparatuses. For the purposes of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in combination with these instruction execution systems, devices or apparatuses. More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection portion with one or more wirings (electronic device), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), an optical fiber device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways if necessary, and then stored in a computer memory.

[0086] It should be understood that the various parts of the present invention can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, a plurality of steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0087] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representation of the above terms does not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner.

[0088] In the description of the present invention, it is to be understood that the terms “center”, “longitudinal”, “lateral”, “length”, “width”, “thickness”, “up”, “down”, “front”, “back”, “left”, “right”, “vertical”, “horizontal”, “top”, “bottom”, “inside”, “outside”, “clockwise”, “counterclockwise”, “axial”, “radial”, “circumferential”, etc., indicating orientations or positional relationships based on the orientations or positional relationships shown in the accompanying drawings, are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the referred device or element must have a specific orientation, be constructed and operated in a specific orientation, and therefore should not be understood as limiting the present invention.

[0089] In addition, the terms "first", "second", etc. used in the embodiments of the present invention are only used for descriptive purposes and should not be understood as indicating or implying relative importance, or implicitly indicating the number of technical features indicated in the present embodiment. Therefore, the features defined by the terms "first", "second", etc. in the embodiments of the present invention can explicitly or implicitly indicate that the embodiment includes at least one of the features. In the description of the present invention, the word "multiple" means at least two or two or more, such as two, three, four, etc., unless otherwise clearly and specifically defined in the embodiments.

[0090] In the present invention, unless otherwise clearly specified or limited in the embodiments, the terms "installed", "connected", "connected" and "fixed" etc. in the embodiments should be understood in a broad sense. For example, the connection can be a fixed connection, a detachable connection, or an integrated connection. It can be understood that it can also be a mechanical connection, an electrical connection, etc.; of course, it can also be a direct connection, or an indirect connection through an intermediate medium, or it can be the internal connection of two elements, or the interaction relationship between two elements. For ordinary technicians in this field, the specific meanings of the above terms in the present invention can be understood according to the specific implementation situation.

[0091] In the present invention, unless otherwise clearly specified and limited, a first feature being "above" or "below" a second feature may mean that the first and second features are in direct contact, or the first and second features are in indirect contact through an intermediate medium. Moreover, a first feature being "above", "above" or "above" a second feature may mean that the first feature is directly above or obliquely above the second feature, or simply means that the first feature is higher in level than the second feature. A first feature being "below", "below" or "below" a second feature may mean that the first feature is directly below or obliquely below the second feature, or simply means that the first feature is lower in level than the second feature.

[0092] Although the embodiments of the present invention have been shown and described above, it is to be understood that the above embodiments are exemplary and are not to be construed as limitations of the present invention. A person skilled in the art may change, modify, replace and vary the above embodiments within the scope of the present invention.

Claims

1. A method for detecting liveness of a face, characterized in that: include: Determining aligned face images; Inputting the aligned face image into a multi-task deep model for recognition to obtain a plurality of face recognition parameters, wherein the plurality of face recognition parameters include face definition information, face angle information and face liveness preliminary recognition information; Performing fusion calculation on the multiple face recognition parameters to obtain a fusion calculation result; Detecting whether the current face is a living face according to the fusion calculation result; The multiple face recognition parameters are fused and calculated according to the following formula: Score=S_face+W1*S_quality+W2*S_angle, Wherein, Score represents the fusion calculation result, S_face represents the confidence level of whether the face corresponding to the preliminary face liveness recognition information is alive, S_quality represents the score of face clarity, S_angle represents face angle information, and W1 and W2 represent weight coefficients; The weight coefficients W1 and W2 are both negative values.

2. The method for face liveness detection according to claim 1, characterized in that: Inputting the aligned face image into a multi-task deep model for recognition, including: Using a basic network structure to perform deep learning on the aligned face images to obtain face feature information; Performing a first convolution calculation on the facial feature information to obtain a first convolution calculation result, performing a second convolution calculation on the first convolution calculation result to obtain the facial clarity information, and performing a third convolution calculation on the first convolution calculation result to obtain the preliminary facial liveness recognition information; Perform a fourth convolution calculation on the facial feature information to obtain the facial angle information.

3. The method for detecting liveness of a face according to any one of claims 1 to 2, characterized in that: Determine the aligned face images, including: Get face image; The face image is preprocessed to obtain the aligned face image.

4. The method for face liveness detection according to claim 3, characterized in that: Preprocessing the face image includes: Feature point detection is performed on the face image, and face alignment is performed according to the detected feature points to obtain the aligned face image.

5. The method for face liveness detection according to claim 3, characterized in that: Before preprocessing the face image, the method further includes: Face detection is performed based on the face image to determine whether the size of the face image meets a preset standard.

6. The method for face liveness detection according to claim 3, characterized in that: The face image is acquired through an RGB camera.

7. A computer-readable storage medium, characterized in that: A face liveness detection program is stored thereon, and when the face liveness detection program is executed by the processor, the face liveness detection method as described in any one of claims 1 to 6 is implemented.

8. An electronic device, characterized in that: The invention comprises a memory, a processor and a face liveness detection program stored in the memory and executable on the processor. When the processor executes the face liveness detection program, the face liveness detection method according to any one of claims 1 to 6 is implemented.

Citation Information

Patent Citations

  • Multi-task deep learning network-based training method, system, multi-task deep learning network-based identification method and system

    CN106503669A

  • Face recognition method and device and computer readable storage medium

    CN110287776A