Face living body detection method based on feature decoupling and feature fusion generation

By employing feature decoupling and fusion generation methods, the problem of decreased recognition capability of face liveness detection under unknown attacks and cross-domain scenarios is solved, achieving efficient and robust face liveness detection that is suitable for mobile deployment.

CN121861733APending Publication Date: 2026-04-14CHONGQING UNIV OF POSTS & TELECOMM
View PDF 1 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-11-21
Publication Date
2026-04-14

Smart Images

  • Figure CN121861733A_ABST
    Figure CN121861733A_ABST
Patent Text Reader

Abstract

The invention provides a face in-vivo detection method based on feature decoupling and feature fusion generation, and belongs to the technical field of computer vision. Comprising the following steps of 1, dividing image data into a real sample and a false sample, and performing feature extraction on the real sample and the false sample to obtain respective corresponding high-dimensional feature representations; 2, designing a feature decoupling and feature fusion module, decoupling the extracted features of different levels into content features and style features, and enhancing the feature decoupling capability by using a multi-head attention mechanism; fusing the extracted features of the real sample and the false sample by using an AdaIn method, and sending the fused features to a generation module and a classification learning module; and step 3, obtaining a generated image with real image features and false image attack features through a Decoder module of the VAE, and participating in subsequent image classification training. And step 4, through a comparison learning module and a classifier, finally realizing authenticity prediction of one picture.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of computer vision technology, specifically, it is a face liveness detection method based on feature decoupling and feature fusion. Background Technology

[0002] Facial recognition has become a key technology in security systems, enabling seamless authentication in applications such as access control and payment verification. However, its widespread adoption is hampered by vulnerabilities such as printing attacks, video playback attacks, and 3D mask attacks. Facial spoofing prevention technologies have emerged to address this, evolving from traditional manual feature-based methods to advanced deep learning techniques. Despite significant progress in controlled, co-located environments, the scarcity of diverse datasets and limited generalization to unseen attack types remain key challenges.

[0003] Early facial recognition methods relied on handcrafted features such as local binary patterns, scale-invariant feature transforms, and histograms of oriented gradients to distinguish between real and fake faces. While these methods performed well in controlled environments, they struggled to cope with various complex attack types. The advent of deep learning marked a paradigm shift; convolutional neural networks achieved binary classification and could incorporate auxiliary cues such as depth maps, reflectance maps, and long-range photoplethysmography to improve detection accuracy.

[0004] Despite these advances, successful results within a single domain have not translated well into cross-domain scenarios due to domain variations. Domain adaptation techniques have been used to adjust source and target distributions using unlabeled target data; however, their reliance on such data limits their practicality. Therefore, domain generalization methods have gained increasing attention, categorized as learning common feature spaces, meta-learning methods, etc. While these methods are effective, their accuracy remains poor in the face of unseen attack types and cross-domain scenarios. Therefore, considering the generalization capability for unseen attack types in real-world environments is a crucial issue in the field of face liveness detection.

[0005] After searching, the application publication number CN114360015B discloses a liveness detection method. Its core is to accurately cut out multiple preset parts (left eye, right eye, nose, mouth, left / right cheek, etc.) of a single face image, extract their independent features, fuse the features, and then eliminate feature correlation through "feature supplementation + set partitioning + iterative generation of high-dimensional features". Finally, the liveness is determined by voting on multiple high-dimensional features.

[0006] The patent has the following shortcomings: (1) It is highly dependent on the accurate detection and matting of facial parts. In scenarios with large poses, occlusion, low light, blurry or non-frontal faces, the localization of parts is prone to failure or serious distortion of features, resulting in a sharp decline in overall performance and poor robustness in actual deployment; (2) It has weak generalization ability for unknown attack types (such as new 3D masks, silicone head molds, new Deepfake algorithms, etc.) and cross-dataset / cross-domain scenarios. It is essentially still supervised feature learning and can only passively memorize the attack features that appear in the training set. When encountering attacks that have not been seen before, the discrimination ability is greatly reduced; (3) It lacks a mechanism to actively generate new attack samples and cannot expand the attack style boundary during the training stage. The defense capability is passive and limited; (4) The high-dimensional feature iteration generation process is computationally complex and has a high inference delay, which is not conducive to real-time deployment on mobile devices.

[0007] This invention completely eliminates the reliance on local part matting by using content-style decoupling based on multi-layer feature maps, AdaIN style transfer fusion, VAE to generate new attack samples, and domain-invariant feature extraction based on contrastive learning and domain adversarial approaches. It actively simulates and generates a large number of difficult samples with "real content + unknown attack styles", which significantly improves the generalization ability for unknown attack types and cross-domain scenarios, while maintaining efficient inference. It achieves more robust and universal face liveness detection in complex real-world environments, overcoming the above-mentioned shortcomings of the existing CN114360015B. Summary of the Invention

[0008] This invention aims to solve the problems of the prior art. It proposes a face liveness detection method based on feature decoupling and feature fusion. The technical solution of this invention is as follows:

[0009] A face liveness detection method based on feature decoupling and feature fusion includes the following steps:

[0010] Step 1: Divide the image data into real samples and fake samples, and extract features from the real samples and fake samples respectively to obtain their corresponding high-dimensional feature representations;

[0011] Step 2: Design a feature decoupling and feature fusion module to decouple the extracted features from different levels into content features and style features, and use a multi-head attention mechanism to enhance the feature decoupling capability; then, use the AdaIn adaptive instance normalization method to fuse the features extracted from real samples and fake samples, and feed them into the generation module and classification learning module.

[0012] Step 3: Obtain a generated image with real image features and fake image attack features through the Decoder module of the VAE autoencoder, and participate in subsequent image classification training;

[0013] Step 4: Through the contrastive learning module and classifier, the authenticity of an image is finally predicted.

[0014] Furthermore, step 1 specifically includes: for each batch of datasets, it needs to contain one real image and one fake image from a different domain, and use a pre-trained ResNet residual network sampler to obtain downsampled feature maps at different levels for use by subsequent feature decoupling and feature fusion modules.

[0015] Furthermore, step 2 includes: representing the n-layer multi-scale feature maps extracted in step 1 as follows: ,in This is the feature map of the l-th layer, whose spatial size decreases as l increases. Each feature map... Each element is divided into a fixed number of blocks N, with the block size adjusted according to the resolution. For each block, mean and variance statistics are calculated to represent content and style information, respectively. Content features include semantic structure and physical attributes such as facial feature points and shape. These features are derived from mid- to high-level metrics, l ≥ m, where m is a threshold level. Global content is emphasized by computation over a larger area and then aggregated into a content vector. ;

[0016] Style features include capturing elements related to vividness, as well as variations in material texture and lighting. These features are extracted from mid-to-lower layers; differences are computed using smaller regions to highlight local texture details, and these are then aggregated into a style vector. These features are integrated in a hierarchical manner within a pyramid-like structure, gradually transitioning from finer to coarser scales.

[0017] Mean of image patch for each layer and variance Apply self-attention mechanism.

[0018] Furthermore, step 2 specifically includes the following steps:

[0019] 2.1 Divide the feature map of each level into 8x8 patches of equal size, and calculate the mean and variance for each patch. Flatten the obtained mean and variance and store them in a 1x64 matrix:

[0020]

[0021]

[0022]

[0023] ;

[0024] 2.2 For each layer, the self-attention mechanism refines the statistical information of image patches by simulating intra-layer dependencies, thereby generating better feature representations:

[0025]

[0026]

[0027] ;

[0028] 2.3 The mean and variance matrices obtained from real and fake images are fused using the AdaIN algorithm. Upsampling is applied to restore the matrices to the same size as the original feature matrices, and residual operations are performed to obtain a new image feature matrix with fake attack features. :

[0029]

[0030]

[0031]

[0032]

[0033]

[0034] Furthermore, in step 3: the obtained fused image features are fed into the VAE decoder, and the previously acquired feature features are mapped to a Gaussian latent distribution.

[0035]

[0036] The training objective of the decoder is to maximize the lower bound of the evidence:

[0037]

[0038] ELBO serves as the lower bound for evidence. To be from the distribution Take the expected value from the middle. This is the approximate posterior distribution of the encoder output. For KL regularization terms, Prior distribution;

[0039] The final generation objective can be represented as:

[0040] ;

[0041] in Given an input image matrix, This is the encoder layer.

[0042] Furthermore, in step 4: a contrastive learning module is introduced, which can separate domain-specific variations and extract domain-invariant features that are insensitive to deception styles; by utilizing contrastive learning, real images and deception images in multiple source domains maintain distance; real samples are set as anchor points and fused with the generated feature matrix. Comparative learning:

[0043]

[0044]

[0045]

[0046] in The cosine similarity formula for two inputs is... , Given two different input matrices, To avoid calculating the gradient of the anchor input;

[0047] An adversarial training method with a domain discriminator is employed to optimize content features, making features from different domains difficult to distinguish.

[0048]

[0049] Where D is the domain discriminator. For content feature extractor; Indicates from sampling The expected probability;

[0050] Finally, binary cross-entropy loss is used as the classification function to ultimately predict the authenticity of an image:

[0051]

[0052] The proposed loss function for the model is:

[0053] .

[0054] An electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the program, implements a face liveness detection method based on feature decoupling and feature fusion as described in any one of the claims.

[0055] A non-transitory computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements a face liveness detection method based on feature decoupling and feature fusion generation as described in any one of the claims.

[0056] The advantages and beneficial effects of this invention are as follows:

[0057] This invention proposes a face liveness detection method based on feature decoupling and feature fusion, aiming to address the problem that face liveness detection methods suffer from decreased recognition ability and vulnerability to attacks when faced with unknown attack types and cross-domain images. This method significantly improves the model's accuracy in recognizing unseen attack types by decoupling the features of the attack image and fusing the original and attack images through a VAE model. The main advantages and beneficial effects of this invention are as follows:

[0058] 1. Enhancing the model's ability to extract domain-invariant features: A feature decoupling and fusion module is proposed to decompose image features into content features and style features. By decoupling features, the model's ability to learn domain-invariant features is enhanced, improving its robustness and generalization performance in cross-domain tasks.

[0059] 2. Generating High-Quality Images: The fused feature matrix is ​​input into the variational autoencoder (VAE) decoder to generate high-quality images with novel features. Experiments show that the feature decoupling and fusion module can significantly improve the texture quality of the VAE-generated images, enrich the feature representations learned by the model, avoid overfitting, and further enhance the model's generalization ability.

[0060] 3. Contrastive Learning Optimization: By employing contrastive learning methods, domain-specific variation features are separated, and domain-invariant features that are insensitive to style changes are extracted. This method effectively improves the model's recognition accuracy when facing unknown attacks and unseen source domain image scenes, thereby significantly enhancing the model's generalization ability.

[0061] 4. The innovation enhances the model's ability to extract domain-invariant features, primarily corresponding to claims 1, 3, and 4 (especially step 2 and sub-steps 2.1-2.3). The core lies in dividing the multi-layer feature map into 8×8 patch blocks and calculating the mean and variance to explicitly separate content (global semantic structure) and style (local texture, lighting, materials). Then, an intra-layer self-attention mechanism further refines the statistical information, and finally, AdaIN is used to achieve accurate transfer of real content and fake style. While existing technologies include content-style decoupling (such as AdaIN and PhotoWOGAN) and multi-head attention mechanisms, very few have specifically used "mean and variance statistics + intra-layer self-attention" for multi-scale feature maps in the face liveness detection domain to separate "liveness-related style" and "facial semantic content," let alone combined it with subsequent VAE generation for actively expanding attack samples. This combination is not a conventional approach but a targeted design addressing the pain point of cross-domain generalization in liveness detection, thus possessing strong non-obviousness. The innovation lies in generating high-quality images, primarily corresponding to claims 1 and 5 (step 3 and its ELBO formula and target generation formula). Unlike conventional data augmentation or ordinary GAN / VAE generation, this patent does not directly generate fake faces in the pixel domain. Instead, it first performs precise AdaIN fusion of "real content + fake style" in multiple feature domains, then uses the fused feature matrix as conditional input to the VAE decoder to generate new samples. This allows the generated attack samples to naturally possess the characteristics of "real face structure + unknown attack texture." In existing technologies, VAEs or diffusion models mostly use random sampling or simple mixing when generating live attack samples, resulting in either structurally broken samples or unrealistic attack traces, leading to low training gains. This patent significantly improves the texture realism and diversity of the generated samples through a feature domain decoupling-fusion-residual process, experimentally demonstrating a significant improvement in cross-domain metrics. This method of using "feature domain conditional VAE" for the active generation of live attack samples is extremely rare in existing published patents and papers, exhibiting high inventiveness. The innovation point, which is optimized through comparative learning, mainly corresponds to claims 1 and 6 (step 4 and its cosine similarity comparison loss formula, domain discriminator adversarial loss formula, and total loss function). This patent not only uses conventional comparative learning, but more importantly, it uses the feature matrix generated by fusing "real content + fake style" as an additional negative sample domain for comparison, and simultaneously introduces a domain discriminator for adversarial processing, forcing the model to learn domain-invariant features that are insensitive to attack styles. Most existing liveness detection comparative learning literature only compares between real and fake classes, and the negative samples are limited to attack types already present in the training set, failing to cope with unknown attacks. This patent provides "novel attack styles" of negative samples in real time through a generation module, significantly expanding the comparison boundary, while simultaneously using domain adversarial processing to further eliminate domain-specific information.This closed-loop training paradigm of "generation-contrast-adversarial" is not yet a conventional technical approach in the field of liveness detection, representing a breakthrough design with significant non-obviousness. The three innovations correspond to the core steps of claim 1: step 2 (decoupling and fusion), step 3 (conditional VAE generation), and step 4 (generating enhanced contrast + adversarial). These three steps form a complete closed loop, each indispensable, collectively realizing the core idea of ​​"actively generating unknown attack samples → forcing the model to learn truly domain-invariant features." This is fundamentally different from existing techniques that passively memorize existing attack patterns, thus demonstrating strong overall inventiveness. It is recommended that the above analysis be included in the innovative description paragraph at the end of the "Invention Content" or "Detailed Embodiments" section in the final draft. Attached Figure Description

[0062] Figure 1 This invention provides a schematic diagram of the overall network model structure in a preferred embodiment.

[0063] Figure 2 This is a schematic diagram of the feature decoupling and fusion module structure of the present invention. Detailed Implementation

[0064] The technical solutions of the embodiments of the present invention will be clearly and thoroughly described below with reference to the accompanying drawings. The described embodiments are merely some embodiments of the present invention.

[0065] The technical solution of the present invention to solve the above-mentioned technical problems is:

[0066] This invention is based on the ResNet network design and aims to achieve efficient object recognition and classification by learning the hierarchical structure of image features. ResNet can extract key features from input images and progressively abstract these features by stacking multiple residual blocks, resulting in multi-level feature extraction maps. We use feature decoupling and fusion methods to decouple content features and style features, allowing for high-quality fusion of features from two images. The fused image serves as a guide for the VAE model's decoder and is also fed into the final classification inference training. In classification inference, we propose a contrastive learning method to separate domain-specific variation features and extract domain-invariant features that are insensitive to style changes. Finally, we use binary cross-entropy loss to classify the images. These methods enable our proposed model to exhibit good generalization ability when facing unknown attack types and unseen domain images.

[0067] Figure 1 This is a schematic diagram of the overall network model structure provided by the present invention. Figure 2 This is a schematic diagram of the feature decoupling and fusion module structure of the present invention, which includes the following steps:

[0068] Step 1: Divide the image data into real samples and fake samples, and extract features from the real samples and fake samples respectively to obtain their corresponding high-dimensional feature representations;

[0069] Step 2: Design a feature decoupling and feature fusion module to decouple the extracted features from different levels into content features and style features, and use a multi-head attention mechanism to enhance the feature decoupling capability. Then, fuse the features extracted from real samples and fake samples using the AdaIn method and feed them into the generation module and classification learning module;

[0070] Step 3: Obtain a generated image with real image features and fake image attack features through the VAE's Decoder module, and participate in subsequent image classification training.

[0071] Step 4: Through the contrastive learning module and classifier, the authenticity of an image is finally predicted.

[0072] Furthermore, in step 1: for each batch of datasets, it is necessary to include one real image and one fake image from a different domain. Using a pre-trained ResNet sampler, downsampled feature maps at different levels are obtained for use by subsequent feature decoupling and feature fusion modules.

[0073] Furthermore, in step 2: the n-layer multi-scale feature maps extracted in step 1 are represented as follows: ,in This is the feature map of the l-th layer, whose spatial size decreases as l increases. Each feature map... Each element is divided into a fixed number of blocks N, with the block size adjusted according to the resolution: smaller blocks in lower layers capture details, while larger blocks in higher layers maintain structural integrity. For each block, we calculate the mean and variance statistics to represent content and style information, respectively.

[0074] Content features include semantic structure and physical properties such as facial landmarks and shape, derived from mid- to high-level (l ≥ m, where m is a threshold level). Global content is emphasized by computation over a larger region and aggregated into a content vector. .

[0075] Style features include content that captures aspects related to vividness and domain-specific information such as material texture and lighting variations; these features are extracted from mid-to-low layers. Differences are computed using smaller regions to highlight local texture details, and these are then aggregated into a style vector. These features are integrated in a hierarchical manner within a pyramid-like structure, gradually transitioning from finer to coarser scales.

[0076] To prioritize processing layers containing relevant information, we average the image patches for each layer. and variance Apply self-attention mechanisms. Specifically, this includes the following steps:

[0077] 2.1 We divide the feature map of each level into 8x8 patches of equal size, and calculate the mean and variance for each patch. We then flatten the obtained mean and variance and store them in a 1x64 matrix:

[0078]

[0079]

[0080] 2.2 For each layer, the self-attention mechanism refines the statistical information of image patches by simulating intra-layer dependencies, thereby generating better feature representations:

[0081]

[0082]

[0083] 2.3 The mean and variance matrices obtained from real and fake images are fused using the AdaIN algorithm. Upsampling is applied to restore the matrices to the same size as the original feature matrices, and residual operations are performed to obtain a new image feature matrix with fake attack features. :

[0084]

[0085]

[0086] Furthermore, in step 3: the obtained fused image features are fed into the VAE decoder, and the previously acquired feature features can be mapped to a Gaussian latent distribution:

[0087]

[0088]

[0089] The training objective of the decoder is to maximize the lower bound of the evidence:

[0090]

[0091] The final generation objective can be represented as:

[0092]

[0093] Furthermore, in step 4: we introduce a contrastive learning module that can separate domain-specific variations and extract domain-invariant features insensitive to deception styles. By leveraging contrastive learning, this module encourages real and deception images from multiple source domains to maintain distance, treating the generated image as a new domain to further enrich the diversity of contrast pairs. Specifically, we set real samples as anchors and fuse them with the generated feature matrix. Comparative learning:

[0094]

[0095] Furthermore, to ensure domain generalization capability, we employ an adversarial training method with a domain discriminator, which optimizes content features to make features from different domains difficult to distinguish:

[0096]

[0097] Where D is the domain discriminator. It is a content feature extractor.

[0098] Finally, we use binary cross-entropy loss as our classification function to ultimately predict the authenticity of an image:

[0099]

[0100] We propose the following loss function for the model:

[0101]

[0102] This invention proposes a novel liveness detection network that significantly improves the model's generalization ability when facing unknown attack types and unseen domain images through innovative feature extraction methods. The network incorporates a feature decoupling and fusion module, decomposing image features into content and style features. This enhances the model's ability to focus on domain-invariant features, thereby improving the quality of images generated by the variational autoencoder (VAE) and significantly increasing the model's recognition generalization performance. This method effectively addresses the challenge of decreased accuracy in face liveness detection under unknown attack types and unseen domain image scenarios. Through contrastive learning, the model can effectively distinguish between real and deceptive images across multiple source domains, maintaining the domain invariance of feature representations and further enhancing generalization ability. Compared to existing face liveness detection models, this invention demonstrates superior performance in cross-domain tests (including OULU, CASIA, Idiap, and MSU datasets). Particularly noteworthy is its leading performance even in scenarios with limited source domain data (i.e., cross-domain tests trained using only one or two source domains). In practical applications, especially when processing unseen domain images, this invention can significantly improve the recognition accuracy of the model, providing an efficient and robust solution for face liveness detection.

[0103] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or entities, or by products with certain functions.

[0104] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.

[0105] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0106] The above embodiments should be understood as illustrative only and not as limiting the scope of protection of the present invention. After reading the description of the present invention, those skilled in the art can make various alterations or modifications to the present invention, and these equivalent changes and modifications also fall within the scope defined by the claims of the present invention.

Claims

1. A face liveness detection method based on feature decoupling and feature fusion, characterized in that, Includes the following steps: Step 1: Divide the image data into real samples and fake samples, and extract features from the real samples and fake samples respectively to obtain their corresponding high-dimensional feature representations; Step 2: Design a feature decoupling and feature fusion module to decouple the extracted features at different levels into content features and style features, and use a multi-head attention mechanism to enhance the feature decoupling capability; Then, the features extracted from real and fake samples are fused using the AdaIn adaptive instance normalization method and fed into the generation module and classification learning module; Step 3: Obtain a generated image with real image features and fake image attack features through the Decoder module of the VAE autoencoder, and participate in subsequent image classification training; Step 4: Through the contrastive learning module and classifier, the authenticity of an image is finally predicted.

2. The face liveness detection method based on feature decoupling and feature fusion as described in claim 1, characterized in that, Step 1 specifically includes: for each batch of datasets, it needs to contain one real image and one fake image from a different domain. A pre-trained ResNet residual network sampler is used to obtain downsampled feature maps at different levels for use by subsequent feature decoupling and feature fusion modules.

3. The face liveness detection method based on feature decoupling and feature fusion as described in claim 1, characterized in that, Step 2 includes: representing the n-layer multi-scale feature maps extracted in step 1 as follows: ,in This is the feature map of the l-th layer, whose spatial size decreases as l increases. Each feature map... Each element is divided into a fixed number of blocks N, with the block size adjusted according to the resolution. For each block, mean and variance statistics are calculated to represent content and style information, respectively. Content features include semantic structure and physical attributes such as facial feature points and shape. These features are derived from mid- to high-level metrics, l ≥ m, where m is a threshold level. Global content is emphasized by computation over a larger area and then aggregated into a content vector. ; Style features include capturing elements related to vividness, as well as variations in material texture and lighting. These features are extracted from mid-to-lower layers; differences are computed using smaller regions to highlight local texture details, and these are then aggregated into a style vector. These features are integrated in a hierarchical manner within a pyramid-like structure, gradually transitioning from finer to coarser scales. Mean of image patch for each layer and variance Apply self-attention mechanism.

4. The face liveness detection method based on feature decoupling and feature fusion as described in claim 3, characterized in that, Step 2 specifically includes the following steps: 2.1 Divide the feature map of each level into 8x8 patches of equal size, and calculate the mean and variance for each patch. Flatten the obtained mean and variance and store them in a 1x64 matrix: ; 2.2 For each layer, the self-attention mechanism refines the statistical information of image patches by simulating intra-layer dependencies, thereby generating better feature representations: ; 2.3 The mean and variance matrices obtained from real and fake images are fused using the AdaIN algorithm. Upsampling is applied to restore the matrices to the same size as the original feature matrices, and residual operations are performed to obtain a new image feature matrix with fake attack features. :

5. The face liveness detection method based on feature decoupling and feature fusion as described in claim 4, characterized in that, Step 3: The obtained fused image features are fed into the VAE decoder, and the previously acquired feature features are mapped to a Gaussian latent distribution. The training objective of the decoder is to maximize the lower bound of the evidence: ELBO serves as the lower bound for evidence. To be from the distribution Take the expected value from the middle. This is the approximate posterior distribution of the encoder output. For KL regularization terms, Prior distribution; The final generation objective can be represented as: ; in Given an input image matrix, This is the encoder layer.

6. The face liveness detection method based on feature decoupling and feature fusion as described in claim 1, characterized in that, Step 4: Introduce a contrastive learning module that can separate domain-specific variations and extract domain-invariant features that are insensitive to deception styles; By utilizing contrastive learning, real and spoofed images from multiple source domains maintain distance; real samples are set as anchors and used in conjunction with the fused feature matrix. Comparative learning: in The cosine similarity formula for two inputs is... , Given two different input matrices, To avoid calculating the gradient of the anchor input; An adversarial training method with a domain discriminator is employed to optimize content features, making features from different domains difficult to distinguish. Where D is the domain discriminator. For content feature extractor; Indicates from sampling The expected probability; Finally, binary cross-entropy loss is used as the classification function to ultimately predict the authenticity of an image. The proposed loss function for the model is: 。 7. An electronic device, characterized in that, The method includes a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the face liveness detection method based on feature decoupling and feature fusion as described in any one of claims 1 to 6.

8. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the face liveness detection method based on feature decoupling and feature fusion as described in any one of claims 1 to 5.

Citation Information

Patent Citations

  • Living body detection method, device, equipment and storage medium

    CN114360015B