Sperm library identity verification system and method based on face recognition
By normalizing the facial feature information and iteratively training the identity recognition model, combining the prior information of the sperm bank's associated personnel information, feature attention analysis of facial feature information in multi-view poses, solving the problem of difficulty in identity verification at different angles and postures in the existing three-dimensional face recognition system, and improving the accuracy and efficiency of sperm bank's identity verification.
Patent Information
- Application Number
- CN202510063914.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-15
- Publication Date
- 2025-05-16
- Estimated Expiration
- 2045-01-15
AI Technical Summary
The existing three-dimensional face recognition system cannot complete identity verification at different angles and postures, and the errors brought by a single perspective cannot guarantee more accurate extraction and mapping of facial feature points into the three-dimensional space, resulting in delays in system recognition speed and user waiting time.
By collecting facial feature information in real time, normalizing the process, and iteratively training the identity recognition model using the training set and the test set to output a converging identity recognition model. This model uses the information of the associated personnel of the sperm bank as a priori information to identify and analyze the facial feature information, and performs feature attention analysis on the facial feature information in multi-view postures without affecting the accuracy of verification.
It improves the accuracy of sperm bank identity verification, reduces the amount of model calculation, reduces the burden on device operation of the identity recognition model, and overcomes the problem of the existing system's difficulty in authentication at different angles and postures.
Smart Images

Figure CN120014681A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of information management, and in particular relates to a sperm bank identity verification system and method based on face recognition. Background Art
[0002] Sperm banks are medical institutions that use ultra-low temperature freezing technology to collect, test, preserve and provide sperm for the purpose of treating infertility, preventing genetic diseases and providing reproductive insurance. The sperm in sperm banks mainly comes from sperm donation volunteers. Sperm banks must strictly keep the information of donors and users confidential to prevent information leakage. This includes taking appropriate technical and management measures to protect personal information during the storage, use and destruction of sperm.
[0003] Chinese patent CN112270783B discloses a sperm bank identity verification and process management system based on three-dimensional face recognition technology, which belongs to the field of information management technology, including a three-dimensional face recognition device, a PC, an ID card reader, an embedded face recognition terminal, a reception desk, a physical examination room, a specimen receiving area, a sperm collection room and a database. The PC is respectively controlled and connected with the three-dimensional face recognition device and the ID card reader. However, the three-dimensional face recognition device of the existing system cannot complete identity authentication at different angles and postures, and the error caused by a single viewing angle cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, which delays the system recognition speed and user waiting time. In view of the above problems, we propose a sperm bank identity verification system and method based on face recognition. Summary of the invention
[0004] The purpose of the present invention is to address the shortcomings of the prior art and provide a sperm bank identity verification system and method based on face recognition, which solves the problem that the three-dimensional face recognition device of the existing system cannot complete identity verification at different angles and postures, and the errors caused by a single viewing angle cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, thereby delaying the system recognition speed and user waiting time.
[0005] The existing system three-dimensional face recognition device cannot complete identity authentication at different angles and postures, and the errors caused by a single perspective cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, which delays the system recognition speed and user waiting time. To address the above problems, we proposed a sperm bank identity verification system and method based on face recognition. When the method is implemented, facial feature information is first collected in real time, and the facial feature information is normalized. At the same time, the training set and the test set are used to iteratively train the identity recognition model, and a converged identity recognition model is output. Then, the identity recognition model uses the sperm bank-related personnel information as prior information, identifies and analyzes the facial feature information, and outputs the identity recognition result. Finally, it is determined whether the identity recognition result meets the preset risk threshold. If the identity recognition result meets the preset risk threshold. In an embodiment of the present invention, the identity recognition model is iteratively trained through a training set and a test set. The identity recognition model uses the information of personnel associated with the sperm bank as prior information, recognizes and analyzes facial feature information, uses the information of personnel associated with the sperm bank as prior information without affecting the verification accuracy, and performs feature attention analysis on facial feature information under multi-view postures, thereby improving the accuracy of sperm bank identity verification, reducing the amount of model calculation, and alleviating the burden of the identity recognition model on equipment operation.
[0006] The present invention is implemented as follows: a sperm bank identity verification method based on face recognition includes real-time collection of facial feature information and normalization of the facial feature information;
[0007] Pre-build an identity verification database based on the information of sperm bank-related personnel, traverse the identity verification database, derive a modeling sample set from the identity verification database, divide the modeling sample set into a training set and a test set, iteratively train the identity recognition model using the training set and the test set, and output a converged identity recognition model;
[0008] The normalized facial feature information is loaded, and the facial feature information is used as input to execute the identity recognition model. The identity recognition model uses the sperm bank-related personnel information as prior information, recognizes and analyzes the facial feature information, and outputs the identity recognition result.
[0009] Load the identity recognition result and determine whether the identity recognition result meets the preset risk threshold. If the identity recognition result meets the preset risk threshold, the identity verification is passed;
[0010] If the identification result does not meet the preset risk threshold, the sperm bank will be triggered to warn of the risk.
[0011] The method for normalizing facial feature information specifically includes:
[0012] Loading facial feature information, executing a moving average filtering algorithm on the facial feature information, performing target area feature detection, and generating at least one set of feature image sets;
[0013] Obtain a feature image set, filter the feature image set based on a moving average filter, and call the PyTorch library function to calculate the mean image of the image feature set after filtering;
[0014] Traverse the feature image set, calculate the difference target between the feature image set and the mean image, and calculate the mean and standard deviation of the difference target based on the open source database Opencv library function cv2.bi l ater l Filter();
[0015] Calculate the segmentation threshold of the difference target based on the mean and standard deviation of the difference target;
[0016] The segmentation threshold is calculated by the following formula:
[0017] T d =μ d +α×δ d (1)
[0018]
[0019] Among them, T d Represents the segmentation threshold of the difference target, μ d is the mean of the difference target, δ d represents the standard deviation of the difference target, α is the threshold segmentation coefficient, A d is the signal-to-noise ratio, σ d is the variance of the difference target, f d is the modulus of the difference target;
[0020] Load the segmentation threshold of the difference target, segment the difference target based on the segmentation threshold of the difference target, and obtain a binary segmentation target;
[0021] Taking the binary segmentation target as input, cluster the binary segmentation target based on the K-Means algorithm and generate the detection anchor box of the binary segmentation target;
[0022] Integrate at least one set of detection anchor boxes and binary segmentation targets, and output normalized facial feature information.
[0023] The method of iteratively training the identity recognition model using a training set and a test set specifically includes:
[0024] Load the initial model, training set, and test set of the identity recognition model;
[0025] Define the training rounds, loss function and hyperparameters of the initial model, iteratively train the initial model using the training set, and generate identity recognition models from different perspectives;
[0026] The local binary features of the identity recognition model are learned using isolation forest, and the identity recognition model is subjected to global linear regression analysis;
[0027] Determine whether the identity recognition model converges. If the identity recognition model converges, output the identity recognition model.
[0028] Load the test set, use the test set as input, execute the identity recognition model, and the identity recognition model outputs the deviation angle estimation of the test set;
[0029] The deviation angle is estimated by the following formula:
[0030]
[0031] Among them, p c is the deviation angle estimation, N is the number of test sets, L is the number of feature points, Δc represents the inclination angle of the current feature point, q t is the current feature point weight, r dis is the distance between the current feature point and the associated feature point, q0 is the initial weight of the current feature point;
[0032] Determine whether the deviation angle estimation of the test set meets the preset deviation threshold. If it meets the preset deviation threshold, output the identity recognition model after iterative training.
[0033] The identity recognition model uses the YOLOv5 network model as the initial model. The initial model consists of an input layer, a feature extraction layer, a feature fusion layer, and a target prediction layer. When the identity recognition model is constructed, the input layer of the initial model is frozen, and an encoder and a decoder are introduced into the input layer. The encoder is used to downsample and reduce the dimension of facial feature information, and the decoder is used to upsample and increase the dimension of facial feature information. The feature extraction layer consists of a Focus module, a CSP module, a CBL module, and an SPP module. The CBL module and the SPP module of the feature extraction layer are frozen, and the CBL module and the SPP module are replaced by the CBAM attention mechanism. The feature fusion layer is a BiFPN feature fusion network. Three groups of 3×3, 5×5, and 13×13 maximum pooling layers are introduced into the Bi FPN feature fusion network for multi-scale feature fusion.
[0034] The identity recognition model uses sperm bank-related personnel information as prior information, and the method for identifying and analyzing facial feature information specifically includes:
[0035] Load the sperm bank-related personnel information and facial feature information, using the standard image of the sperm bank-related personnel input information as prior information;
[0036] Obtain facial feature information, the encoder downsamples and reduces the dimension of the facial feature information, and outputs the downsampled result;
[0037] Load the down-sampling result, the decoder up-samples the down-sampling result and outputs the decoding information set;
[0038] The feature extraction layer extracts features from the decoded information set and uses the CBAM attention mechanism to process the decoded information set to obtain feature attention output;
[0039] Obtain feature attention output, and the BiFPN feature fusion network performs feature fusion on the feature attention output and outputs a feature fusion set;
[0040] The standard image of the sperm bank's associated personnel input information is used as prior information, the feature fusion set and the prior probability of the standard image are calculated, and the prior probability is used as the output recognition analysis result.
[0041] The feature attention output is expressed as:
[0042] S C =Sigmoid(MLP(Maxpool(F))+MLP(Avgpool(F)))(5)
[0043] Among them, S C is the feature attention output, and F is the feature extraction result of the feature extraction layer on the decoded information set;
[0044] The calculation formula of feature fusion set is as follows:
[0045]
[0046] Among them, F out represents the feature fusion set, Conv(·) is the convolution operation, and w i is the weight value of the feature attention output after the activation function, Resize(·) is the pooling operation, S C+1 It is the fusion result of the BiFPN feature fusion network feature attention output after the activation function, and ε is the preset minimum value.
[0047] On the other hand, the present invention also provides a sperm bank identity verification system based on face recognition, the sperm bank identity verification system based on face recognition specifically comprises:
[0048] An information collection module is used to collect facial feature information in real time and normalize the facial feature information;
[0049] Verify the database, pre-build the identity verification database based on the information of the sperm bank-related personnel, traverse the identity verification database, derive the modeling sample set from the identity verification database, divide the modeling sample set into a training set and a test set, use the training set and the test set to iteratively train the identity recognition model, and output a converged identity recognition model;
[0050] The identity recognition module is used to load the normalized facial feature information, take the facial feature information as input, execute the identity recognition model, and the identity recognition model uses the sperm bank-related personnel information as prior information, recognizes and analyzes the facial feature information, and outputs the identity recognition result;
[0051] The risk judgment module is used to load the identity recognition results and determine whether the identity recognition results meet the preset risk threshold. If the identity recognition results meet the preset risk threshold, the identity verification is passed; if the identity recognition results do not meet the preset risk threshold, the sperm bank warning risk is triggered.
[0052] The information collection module includes:
[0053] A feature detection unit, used to load facial feature information, perform a moving average filtering algorithm on the facial feature information, perform target area feature detection, and generate at least one set of feature image sets;
[0054] An image filtering unit is used to obtain a feature image set, filter the feature image set based on a moving average filter, and call a PyTorch library function to calculate a mean image of the image feature set after filtering;
[0055] A target calculation unit is used to traverse the feature image set, calculate the difference target between the feature image set and the mean image, and calculate the mean and standard deviation of the difference target based on the open source database Opencv library function cv2.bilateralFilter();
[0056] A binary segmentation unit, which calculates a segmentation threshold of the difference target based on the mean and standard deviation of the difference target, loads the segmentation threshold of the difference target, and segments the difference target based on the segmentation threshold of the difference target to obtain a binary segmentation target;
[0057] The target clustering unit takes the binary segmentation target as input, clusters the binary segmentation target based on the K-Means algorithm and generates a detection anchor frame of the binary segmentation target, integrates at least one set of detection anchor frames and binary segmentation targets, and outputs normalized facial feature information.
[0058] Compared with the prior art, the embodiments of the present application have the following beneficial effects:
[0059] In the embodiment of the present invention, the identity recognition model is iteratively trained through training sets and test sets. The identity recognition model uses the information of personnel associated with the sperm bank as prior information to identify and analyze facial feature information. Without affecting the verification accuracy, the information of personnel associated with the sperm bank is used as prior information to perform feature attention analysis on facial feature information under multiple perspectives and postures, thereby improving the accuracy of sperm bank identity verification, reducing the amount of model calculation, and alleviating the burden of the identity recognition model on equipment operation. The problem that the three-dimensional face recognition device of the existing system cannot complete identity authentication at different angles and postures, and the error caused by a single perspective cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, thereby delaying the system recognition speed and user waiting time is overcome.
[0060] In an embodiment of the present invention, by normalizing facial feature information, the impact of individual differences, environmental influences, and noise on sperm bank identity verification can be reduced, and the generalization ability of sperm bank identity verification can be improved. During preprocessing, the difference target is segmented based on the segmentation threshold of the difference target to obtain a binary segmentation target. The generation of the binary segmentation target simplifies the data preprocessing steps, making subsequent image analysis and feature extraction more efficient. Normalization processing helps to standardize input data, so that the identity recognition model can obtain consistent performance on different data sets.
[0061] In an embodiment of the present invention, an identity recognition model and an iterative training method thereof are provided. The identity recognition model uses a YOLOv5 network model as an initial model, introduces an encoder, a decoder, a CBAM attention mechanism, and a Bi FPN feature fusion network. By combining the encoder, the decoder, the CBAM attention mechanism, and the Bi FPN feature fusion network, the identity recognition model can more comprehensively utilize facial feature information under different viewing angles and postures, thereby improving the generalization ability under different scenes and postures. BRIEF DESCRIPTION OF THE DRAWINGS
[0062] Figure 1 It is a schematic diagram of the implementation flow of the sperm bank identity verification method based on face recognition provided by the present invention.
[0063] Figure 2 The following is a schematic diagram of the implementation process of the normalization processing method for facial feature information.
[0064] Figure 3 The figure shows a schematic diagram of the implementation process of the iterative training method of the identity recognition model using a training set and a test set.
[0065] Figure 4 The figure shows a schematic diagram of the implementation process of the facial feature information recognition and analysis method using the sperm bank-related personnel information as prior information for the identity recognition model.
[0066] Figure 5A schematic diagram of the architecture of a sperm bank identity verification system based on face recognition is shown. DETAILED DESCRIPTION
[0067] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by technicians in the technical field of this application; the terms used in the specification of the application herein are only for the purpose of describing specific embodiments and are not intended to limit this application; the terms "including" and "having" and any variations thereof in the specification and claims of this application and the above-mentioned drawings are intended to cover non-exclusive inclusions. The terms "first", "second", etc. in the specification and claims of this application or the above-mentioned drawings are used to distinguish different objects, not to describe a specific order.
[0068] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0069] The existing system three-dimensional face recognition device cannot complete identity authentication at different angles and postures, and the errors caused by a single perspective cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, which delays the system recognition speed and user waiting time. To address the above problems, we proposed a sperm bank identity verification system and method based on face recognition. When the method is implemented, facial feature information is first collected in real time, and the facial feature information is normalized. At the same time, the training set and the test set are used to iteratively train the identity recognition model, and a converged identity recognition model is output. Then, the identity recognition model uses the sperm bank-related personnel information as prior information, identifies and analyzes the facial feature information, and outputs the identity recognition result. Finally, it is determined whether the identity recognition result meets the preset risk threshold. If the identity recognition result meets the preset risk threshold. In the embodiment of the present invention, the identity recognition model is iteratively trained through training sets and test sets. The identity recognition model uses the information of personnel associated with the sperm bank as prior information to identify and analyze facial feature information. Without affecting the verification accuracy, the information of personnel associated with the sperm bank is used as prior information to perform feature attention analysis on facial feature information under multiple perspectives and postures, thereby improving the accuracy of sperm bank identity verification, reducing the amount of model calculation, and alleviating the burden of the identity recognition model on equipment operation. The problem that the three-dimensional face recognition device of the existing system cannot complete identity authentication at different angles and postures, and the error caused by a single perspective cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, thereby delaying the system recognition speed and user waiting time is overcome.
[0070] The embodiment of the present invention provides a sperm bank identity verification method based on face recognition. Figure 1 The present invention shows a schematic diagram of the implementation process of the sperm bank identity verification method based on face recognition, which specifically includes:
[0071] Step S10, collecting facial feature information in real time and normalizing the facial feature information;
[0072] It should be noted that the facial feature information refers to facial images and videos in a multi-view state, and the facial feature information includes but is not limited to the feature information of eyes, mouth, nose, ears, and eyebrows.
[0073] Step S20, pre-constructing an identity verification database based on the sperm bank-related personnel information, traversing the identity verification database, deriving a modeling sample set from the identity verification database, dividing the modeling sample set into a training set and a test set, iteratively training the identity recognition model using the training set and the test set, and outputting a converged identity recognition model;
[0074] Step S30, load the normalized facial feature information, use the facial feature information as input, execute the identity recognition model, the identity recognition model uses the sperm bank associated personnel information as prior information, recognizes and analyzes the facial feature information, and outputs the identity recognition result.
[0075] Step S40, loading the identity recognition result, and determining whether the identity recognition result meets the preset risk threshold;
[0076] In this embodiment, the preset risk threshold may be set to 0.4-0.45.
[0077] Step S50, if the identity recognition result meets the preset risk threshold, the identity verification is passed;
[0078] Step S60: If the identity recognition result does not meet the preset risk threshold, the sperm bank is triggered to warn of the risk.
[0079] In this embodiment, the identity recognition model is iteratively trained through training sets and test sets. The identity recognition model uses the information of personnel associated with the sperm bank as prior information, recognizes and analyzes facial feature information, and uses the information of personnel associated with the sperm bank as prior information without affecting the verification accuracy. Feature attention analysis is performed on facial feature information under multiple perspectives and postures, thereby improving the accuracy of sperm bank identity verification and reducing the amount of model calculation. This reduces the burden of the identity recognition model on equipment operation, and overcomes the problem that the three-dimensional face recognition device of the existing system cannot complete identity authentication at different angles and postures, and the error caused by a single perspective cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, thereby delaying the system recognition speed and user waiting time.
[0080] The embodiment of the present invention provides a method for normalizing facial feature information. Figure 2 A schematic diagram of the implementation process of a method for normalizing facial feature information is shown. The method for normalizing facial feature information specifically includes:
[0081] Step S101, loading facial feature information, executing a moving average filtering algorithm on the facial feature information, performing target area feature detection, and generating at least one set of feature image sets;
[0082] It should be noted that moving average filtering is a simple smoothing technique that reduces noise by calculating the average value of data in a certain window. In facial feature information processing, the feature point coordinates or feature vectors are smoothed to improve the stability and accuracy of subsequent analysis. When performing target area feature detection, the face-api.js detection method can be used to extract target area features and generate at least one set of feature image sets.
[0083] Step S102, obtaining a feature image set, filtering the feature image set based on a moving average filter, and calling a PyTorch library function to calculate a mean image of the image feature set after filtering;
[0084] Step S103, traversing the feature image set, calculating the difference target between the feature image set and the mean image, and calculating the mean and standard deviation of the difference target based on the open source database Opencv library function cv2.bilayerFilter();
[0085] Step S104, calculating the segmentation threshold of the difference target based on the mean and standard deviation of the difference target;
[0086] The segmentation threshold is calculated by the following formula:
[0087] T d =μ d +α×δ d (1)
[0088]
[0089] Among them, T d Represents the segmentation threshold of the difference target, μ d is the mean of the difference target, δ d represents the standard deviation of the difference target, α is the threshold segmentation coefficient, A d is the signal-to-noise ratio, σ d is the variance of the difference target, f d The modulus of the difference target.
[0090] Step S105, loading the segmentation threshold of the difference target, segmenting the difference target based on the segmentation threshold of the difference target, and obtaining a binary segmentation target;
[0091] It should be noted that the acquisition of binary segmentation targets helps to simplify the subsequent feature extraction and matching process, because binary images only contain black and white pixels, reducing the complexity of the data. The segmentation threshold based on the difference target can more accurately distinguish facial features from the background, thereby improving the accuracy of the facial recognition system.
[0092] Step S106, taking the binary segmentation target as input, clustering the binary segmentation target based on the K-Means algorithm and generating a detection anchor box of the binary segmentation target;
[0093] Step S107, integrating at least one set of detection anchor frames and binary segmentation targets, and outputting normalized facial feature information.
[0094] In an embodiment of the present invention, by normalizing facial feature information, the impact of individual differences, environmental influences, and noise on sperm bank identity verification can be reduced, and the generalization ability of sperm bank identity verification can be improved. During preprocessing, the difference target is segmented based on the segmentation threshold of the difference target to obtain a binary segmentation target. The generation of the binary segmentation target simplifies the data preprocessing steps, making subsequent image analysis and feature extraction more efficient. Normalization processing helps to standardize input data, so that the identity recognition model can obtain consistent performance on different data sets.
[0095] The embodiment of the present invention provides a method for iteratively training an identity recognition model using a training set and a test set. Figure 3 The following is a schematic diagram of the implementation process of a method for iteratively training an identity recognition model using a training set and a test set. The method for iteratively training an identity recognition model using a training set and a test set specifically includes:
[0096] Step S201, loading the initial model, training set and test set of the identity recognition model;
[0097] Step S202, defining the training rounds, loss function and hyperparameters of the initial model, iteratively training the initial model using the training set, and generating identity recognition models under different perspectives;
[0098] In this embodiment, the training rounds of the initial model may be 100-120 times, the loss function may be a cross entropy loss function, and the learning rate hyperparameter is set to 0.002.
[0099] Step S203, using isolation forest to learn local binary features of the identity recognition model, and performing global linear regression analysis on the identity recognition model;
[0100] The Isolation Forest algorithm can effectively detect outliers in the data set. By removing these outliers, the quality and consistency of the data can be improved, thereby providing cleaner and more reliable training data for the identity recognition model. The local binary feature is an effective texture descriptor that can capture local structural information in the image. Applying this feature to the identity recognition model can enhance the model's ability to express facial features.
[0101] Step S204, determining whether the identity recognition model has converged, and if the identity recognition model has converged, outputting the identity recognition model;
[0102] Step S205, load the test set, take the test set as input, execute the identity recognition model, and the identity recognition model outputs the deviation angle estimation of the test set; in the embodiment of the present invention, by analyzing the deviation angle estimation on the test set, the performance of the identity recognition model under different angle conditions can be understood, and the identity recognition model can be improved in a targeted manner. The deviation threshold sets a performance benchmark for the identity recognition model, which helps to compare the effects of different identity recognition models or algorithms.
[0103] The deviation angle is estimated by the following formula:
[0104]
[0105] Among them, p c is the deviation angle estimation, N is the number of test sets, L is the number of feature points, Δc represents the inclination angle of the current feature point, q t is the current feature point weight, r dis is the distance between the current feature point and the associated feature point, q0 is the initial weight of the current feature point. The initial weight of the feature point can be set and determined based on expert consultation method and principal component analysis method;
[0106] Step S206, determining whether the deviation angle estimation of the test set meets a preset deviation threshold. In this embodiment, the deviation threshold may be 0.1-0.15;
[0107] Step S207: if the preset deviation threshold is met, output the identity recognition model after iterative training;
[0108] If it does not meet the preset deviation threshold, return to step S202 to continue iterative training of the identity recognition model.
[0109] In this embodiment, the identity recognition model uses the YOLOv5 network model as the initial model. The initial model consists of an input layer, a feature extraction layer, a feature fusion layer, and a target prediction layer. When the identity recognition model is constructed, the input layer of the initial model is frozen, and an encoder and a decoder are introduced into the input layer. The encoder is used to downsample and reduce the dimension of facial feature information, and the decoder is used to upsample and increase the dimension of facial feature information. The feature extraction layer consists of a Focus module, a CSP module, a CBL module, and an SPP module. The CBL module and the SPP module of the feature extraction layer are frozen, and the CBL module and the SPP module are replaced by a CBAM attention mechanism. The feature fusion layer is a Bi FPN feature fusion network. Three groups of 3×3, 5×5, and 13×13 maximum pooling layers are introduced into the Bi FPN feature fusion network for multi-scale feature fusion. Bi FPN (Birectional Feature Pyramid Network) is a bidirectional feature pyramid network that can effectively fuse features of different scales, thereby improving the model's recognition ability for multi-scale facial features. This feature fusion strategy helps improve the performance of the model in dealing with complex backgrounds and different lighting conditions.
[0110] In an embodiment of the present invention, an identity recognition model and an iterative training method thereof are provided. The identity recognition model uses a YOLOv5 network model as an initial model, introduces an encoder, a decoder, a CBAM attention mechanism, and a Bi FPN feature fusion network. By combining the encoder, the decoder, the CBAM attention mechanism, and the Bi FPN feature fusion network, the identity recognition model can more comprehensively utilize facial feature information under different viewing angles and postures, thereby improving the generalization ability under different scenes and postures.
[0111] The embodiment of the present invention provides a method for identifying and analyzing facial feature information by using sperm bank-related personnel information as prior information in an identity recognition model. Figure 4 The figure shows a schematic diagram of the implementation process of the method for identifying and analyzing facial feature information by using the sperm bank-related personnel information as prior information. The method for identifying and analyzing facial feature information by using the sperm bank-related personnel information as prior information specifically includes:
[0112] Step S301, loading the sperm bank associated personnel information and facial feature information, using the standard image of the sperm bank associated personnel input information as prior information;
[0113] Step S302, acquiring facial feature information, the encoder downsamples and reduces the dimension of the facial feature information, and outputs the downsampling result;
[0114] In this embodiment, the encoder consists of 3 convolutional layers, which are responsible for extracting the spatial features of the input image. Each convolutional layer is followed by a ReLU activation function to introduce nonlinearity so that the model can learn more complex features.
[0115] Step S303, loading the down-sampling result, the decoder up-samples the down-sampling result and outputs a decoding information set;
[0116] Step S304, the feature extraction layer extracts features from the decoded information set, and uses the CBAM attention mechanism to process the decoded information set to obtain feature attention output;
[0117] Step S305, obtaining feature attention output, and the Bi FPN feature fusion network performs feature fusion on the feature attention output, and outputs a feature fusion set;
[0118] Step S306, using the standard image of the sperm bank associated personnel input information as prior information, calculating the feature fusion set and the prior probability of the standard image, and using the prior probability as the output recognition analysis result.
[0119] It should be noted that sperm bank-related personnel can be sperm donation volunteers, institutional technicians, and institutional service personnel, and the information entered by sperm bank-related personnel includes but is not limited to basic information, health information, and image information. For facial feature recognition under multi-view postures, prior probability can help the model adapt to different perspective changes and improve recognition stability.
[0120] In this embodiment, the feature attention output is expressed as:
[0121] S C =Sigmoid(MLP(Maxpool(F))+MLP(Avgpool(F)))(5)
[0122] Among them, S C is the feature attention output, and F is the feature extraction result of the feature extraction layer on the decoded information set;
[0123] The calculation formula of feature fusion set is as follows:
[0124]
[0125] Among them, F out represents the feature fusion set, Conv(·) is the convolution operation, and w i is the weight value of the feature attention output after the activation function, Resize(·) is the pooling operation, S C+1 It is the fusion result of the BiFPN feature fusion network feature attention output after the activation function, and ε is the preset minimum value, which can be 0.01-0.05.
[0126] The embodiment of the present invention provides a sperm bank identity verification system based on face recognition. Figure 5 The schematic diagram of the structure of the sperm bank identity verification system based on face recognition is shown. The sperm bank identity verification system based on face recognition specifically includes:
[0127] The information collection module 100 is used to collect facial feature information in real time and normalize the facial feature information;
[0128] Verification database 200, pre-constructing an identity verification database based on the sperm bank-related personnel information, traversing the identity verification database, deriving a modeling sample set from the identity verification database, dividing the modeling sample set into a training set and a test set, iteratively training the identity recognition model using the training set and the test set, and outputting a converged identity recognition model;
[0129] The identity recognition module 300 is used to load the normalized facial feature information, take the facial feature information as input, execute the identity recognition model, the identity recognition model takes the sperm bank associated personnel information as prior information, recognizes and analyzes the facial feature information, and outputs the identity recognition result;
[0130] The risk judgment module 400 is used to load the identity recognition result and judge whether the identity recognition result meets the preset risk threshold. If the identity recognition result meets the preset risk threshold, the identity verification is passed; if the identity recognition result does not meet the preset risk threshold, the sperm bank warning risk is triggered.
[0131] It should be noted that the information collection module 100, the verification database 200, the identity recognition module 300, and the risk judgment module 400 can be connected by Bluetooth or Lora communication to realize interactive transmission of data, and the sperm bank identity verification system based on face recognition in the embodiment of the present invention corresponds to the above-mentioned sperm bank identity verification method based on face recognition. The explanations, examples, beneficial effects and other parts of the relevant contents can refer to the corresponding contents in the sperm bank identity verification method based on face recognition, which will not be repeated here.
[0132] In this embodiment, the information collection module 100 includes:
[0133] The feature detection unit 110 is used to load facial feature information, perform a moving average filtering algorithm on the facial feature information, perform target area feature detection, and generate at least one set of feature image sets;
[0134] An image filtering unit 120 is used to obtain a feature image set, filter the feature image set based on a moving average filter, and call a PyTorch library function to calculate a mean image of the image feature set after filtering;
[0135] A target calculation unit 130 is used to traverse the feature image set, calculate the difference target between the feature image set and the mean image, and calculate the mean and standard deviation of the difference target based on the open source database Opencv library function cv2.bilateralFilter();
[0136] A binary segmentation unit 140 calculates a segmentation threshold of the difference target based on a mean value and a standard deviation of the difference target, loads the segmentation threshold of the difference target, and segments the difference target based on the segmentation threshold of the difference target to obtain a binary segmentation target;
[0137] The target clustering unit 150 takes the binary segmentation target as input, clusters the binary segmentation target based on the K-Means algorithm and generates a detection anchor frame of the binary segmentation target, integrates at least one set of detection anchor frames and binary segmentation targets, and outputs normalized facial feature information.
[0138] On the other hand, an embodiment of the present invention further provides a computer device, the computer device comprising a memory and a processor, the memory storing a computer program, and the computer program implementing any one of the above-mentioned methods when executed by the processor.
[0139] As a non-volatile computer-readable storage medium, the memory can be used to store non-volatile software programs, non-volatile computer executable programs and modules, such as the program instructions / modules corresponding to the sperm bank identity verification method based on face recognition in the embodiment of the present application. The memory may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created by the use of the sperm bank identity verification method based on face recognition, etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory may optionally include a memory remotely arranged relative to the processor, and these remote memories may be connected to the local module via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0140] In another aspect of the embodiments of the present invention, a computer-readable storage medium is provided, wherein the computer-readable storage medium stores computer program instructions, and the computer program instructions can be executed by a processor. When the computer program instructions are executed, the method of any one of the above embodiments is implemented.
[0141] Finally, it should be noted that the computer-readable storage medium (e.g., memory) herein may be a volatile memory or a nonvolatile memory, or may include both a volatile memory and a nonvolatile memory. As an example and not by way of limitation, a nonvolatile memory may include a read-only memory (ROM), a programmable ROM (PROM), an electrically programmable ROM (EPROM), an electrically erasable programmable ROM (EEPROM), or a flash memory. A volatile memory may include a random access memory (RAM), which may act as an external cache memory. As an example and not by way of limitation, RAM may be obtained in a variety of forms, such as synchronous RAM (DRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), and direct Rambus RAM (DRRAM). The storage devices of the disclosed aspects are intended to include, but are not limited to, these and other suitable types of memory.
[0142] In summary, the present invention provides a sperm bank identity verification system and method based on face recognition. In an embodiment of the present invention, the identity recognition model is iteratively trained through a training set and a test set. The identity recognition model uses the sperm bank-related personnel information as prior information to identify and analyze facial feature information. Without affecting the verification accuracy, the sperm bank-related personnel information is used as prior information to perform feature attention analysis on facial feature information under multiple perspectives and postures, thereby improving the sperm bank identity verification accuracy and reducing the model calculation amount, alleviating the burden of the identity recognition model on equipment operation, and overcoming the problem that the existing system three-dimensional face recognition device cannot complete identity authentication at different angles and postures, and the error caused by a single perspective cannot guarantee more accurate extraction and mapping of facial feature points into three-dimensional space, thereby delaying the system recognition speed and user waiting time.
[0143] It should be noted that, for the above-mentioned embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that the present invention is not limited by the described order of actions, because according to the present invention, some steps may be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions and modules involved are not necessarily required by the present invention.
[0144] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the scope of protection of the invention. Obviously, the described embodiments are only some embodiments of the present invention, rather than all embodiments. Based on these embodiments, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in this field can still combine, add, delete or make other adjustments to the features in the various embodiments of the present invention according to the circumstances without conflict, without making creative work, so as to obtain different other technical solutions that do not deviate from the concept of the present invention in essence, and these technical solutions also belong to the scope of protection of the present invention.
Claims
1. A sperm bank identity verification method based on face recognition, characterized in that: include Collect facial feature information in real time and normalize the facial feature information; Pre-build an identity verification database based on the information of sperm bank-related personnel, traverse the identity verification database, derive a modeling sample set from the identity verification database, divide the modeling sample set into a training set and a test set, iteratively train the identity recognition model using the training set and the test set, and output a converged identity recognition model; The normalized facial feature information is loaded, and the facial feature information is used as input to execute the identity recognition model. The identity recognition model uses the sperm bank-related personnel information as prior information, recognizes and analyzes the facial feature information, and outputs the identity recognition result.
2. The sperm bank identity verification method based on face recognition as claimed in claim 1, characterized in that: The sperm bank identity verification method based on face recognition also includes: Load the identity recognition result and determine whether the identity recognition result meets the preset risk threshold. If the identity recognition result meets the preset risk threshold, the identity verification is passed; If the identification result does not meet the preset risk threshold, the sperm bank will be triggered to warn of the risk.
3. The sperm bank identity verification method based on face recognition as claimed in claim 1, characterized in that: The method for normalizing facial feature information specifically includes: Loading facial feature information, executing a moving average filtering algorithm on the facial feature information, performing target area feature detection, and generating at least one set of feature image sets; Obtain a feature image set, filter the feature image set based on a moving average filter, and call the PyTorch library function to calculate the mean image of the image feature set after filtering; Traverse the feature image set, calculate the difference target between the feature image set and the mean image, and calculate the mean and standard deviation of the difference target based on the open source database Opencv library function cv2.bilateralFilter(); Calculate the segmentation threshold of the difference target based on the mean and standard deviation of the difference target; The segmentation threshold is calculated by the following formula: T d =μ d +a×d d (1) Among them, T d Represents the segmentation threshold of the difference target, μ d is the mean of the difference target, δ d represents the standard deviation of the difference target, α is the threshold segmentation coefficient, A d is the signal-to-noise ratio, σ d is the variance of the difference target, f d The modulus of the difference target.
4. The sperm bank identity verification method based on face recognition as claimed in claim 3, characterized in that: The method for normalizing facial feature information further includes: Load the segmentation threshold of the difference target, segment the difference target based on the segmentation threshold of the difference target, and obtain a binary segmentation target; Taking the binary segmentation target as input, cluster the binary segmentation target based on the K-Means algorithm and generate the detection anchor box of the binary segmentation target; Integrate at least one set of detection anchor boxes and binary segmentation targets, and output normalized facial feature information.
5. The sperm bank identity verification method based on face recognition as claimed in claim 1, characterized in that: The method of iteratively training the identity recognition model using a training set and a test set specifically includes: Load the initial model, training set, and test set of the identity recognition model; Define the training rounds, loss function and hyperparameters of the initial model, iteratively train the initial model using the training set, and generate identity recognition models from different perspectives; The local binary features of the identity recognition model are learned using isolation forest, and the identity recognition model is subjected to global linear regression analysis; Determine whether the identity recognition model converges. If the identity recognition model converges, output the identity recognition model. Load the test set, use the test set as input, execute the identity recognition model, and the identity recognition model outputs the deviation angle estimation of the test set; The deviation angle is estimated by the following formula: Among them, p c is the deviation angle estimation, N is the number of test sets, L is the number of feature points, Δc represents the inclination angle of the current feature point, q t is the current feature point weight, r dis is the distance between the current feature point and the associated feature point, q0 is the initial weight of the current feature point; Determine whether the deviation angle estimation of the test set meets the preset deviation threshold. If it meets the preset deviation threshold, output the identity recognition model after iterative training.
6. The sperm bank identity verification method based on face recognition as claimed in claim 5, characterized in that: The identity recognition model uses the YOLOv5 network model as the initial model. The initial model consists of an input layer, a feature extraction layer, a feature fusion layer, and a target prediction layer. When the identity recognition model is constructed, the input layer of the initial model is frozen, and an encoder and a decoder are introduced into the input layer. The encoder is used to downsample and reduce the dimension of facial feature information, and the decoder is used to upsample and increase the dimension of facial feature information. The feature extraction layer consists of a Focus module, a CSP module, a CBL module, and an SPP module. The CBL module and the SPP module of the feature extraction layer are frozen, and the CBL module and the SPP module are replaced by the CBAM attention mechanism. The feature fusion layer is a BiFPN feature fusion network. Three groups of 3×3, 5×5, and 13×13 maximum pooling layers are introduced into the BiFPN feature fusion network for multi-scale feature fusion.
7. The sperm bank identity verification method based on face recognition as claimed in claim 6, characterized in that: The identity recognition model uses sperm bank-related personnel information as prior information, and the method for identifying and analyzing facial feature information specifically includes: Load the sperm bank-related personnel information and facial feature information, using the standard image of the sperm bank-related personnel input information as prior information; Obtain facial feature information, the encoder downsamples and reduces the dimension of the facial feature information, and outputs the downsampled result; Load the down-sampling result, the decoder up-samples the down-sampling result and outputs the decoding information set; The feature extraction layer extracts features from the decoded information set and uses the CBAM attention mechanism to process the decoded information set to obtain feature attention output; Obtain feature attention output, and the BiFPN feature fusion network performs feature fusion on the feature attention output and outputs a feature fusion set; The standard image of the sperm bank's associated personnel input information is used as prior information, the feature fusion set and the prior probability of the standard image are calculated, and the prior probability is used as the output recognition analysis result.
8. The sperm bank identity verification method based on face recognition as claimed in claim 7, characterized in that: The feature attention output is expressed as: S C =Sigmoid(MLP(Maxpool(F))+MLP(Avgpool(F)))(5) Among them, S C is the feature attention output, and F is the feature extraction result of the feature extraction layer on the decoded information set; The calculation formula of feature fusion set is as follows: Among them, F out represents the feature fusion set, Conv(·) is the convolution operation, and w i is the weight value of the feature attention output after the activation function, Resize(·) is the pooling operation, S C+1 It is the fusion result of the BiFPN feature fusion network feature attention output after the activation function, and ε is the preset minimum value.
9. A sperm bank identity verification system based on face recognition, used to implement a sperm bank identity verification method based on face recognition as claimed in any one of claims 1 to 8, characterized in that: The sperm bank identity verification system based on face recognition specifically includes: An information collection module is used to collect facial feature information in real time and normalize the facial feature information; Verify the database, pre-build the identity verification database based on the information of the sperm bank-related personnel, traverse the identity verification database, derive the modeling sample set from the identity verification database, divide the modeling sample set into a training set and a test set, use the training set and the test set to iteratively train the identity recognition model, and output a converged identity recognition model; The identity recognition module is used to load the normalized facial feature information, take the facial feature information as input, execute the identity recognition model, and the identity recognition model uses the sperm bank-related personnel information as prior information, recognizes and analyzes the facial feature information, and outputs the identity recognition result; The risk judgment module is used to load the identity recognition results and determine whether the identity recognition results meet the preset risk threshold. If the identity recognition results meet the preset risk threshold, the identity verification is passed; if the identity recognition results do not meet the preset risk threshold, the sperm bank warning risk is triggered.
10. The sperm bank identity verification system based on face recognition as claimed in claim 9, characterized in that: The information collection module includes: A feature detection unit, used to load facial feature information, perform a moving average filtering algorithm on the facial feature information, perform target area feature detection, and generate at least one set of feature image sets; An image filtering unit is used to obtain a feature image set, filter the feature image set based on a moving average filter, and call a PyTorch library function to calculate a mean image of the image feature set after filtering; The target calculation unit is used to traverse the feature image set, calculate the difference target between the feature image set and the mean image, and calculate the mean and standard deviation of the difference target based on the open source database Opencv library function cv2.bilateralFilter(); A binary segmentation unit, which calculates a segmentation threshold of the difference target based on the mean and standard deviation of the difference target, loads the segmentation threshold of the difference target, and segments the difference target based on the segmentation threshold of the difference target to obtain a binary segmentation target; The target clustering unit takes the binary segmentation target as input, clusters the binary segmentation target based on the K-Means algorithm and generates a detection anchor frame of the binary segmentation target, integrates at least one set of detection anchor frames and binary segmentation targets, and outputs normalized facial feature information.
Citation Information
Patent Citations
Sperm bank identity verification and process management system based on 3D facial recognition technology
CN112270783B
Face super-resolution reconstruction method based on identity prior generative adversarial network
CN110706157A
Method for simultaneously identifying multiple attributive characters of face
CN111401175A
Driver identity verification method and device, computer equipment and storage medium
CN114241459A
Voiceprint recognition method, device and equipment based on related crowd voiceprint library
CN117877492A
Cited By
Payment identity credibility verification protection method and system
CN121304169A
Payment identity trust verification protection method and system
CN121304169B