Face Recognition Standard Photo Update Method, Device, Computer Equipment and Storage Medium
By pre-determining the standard update time based on the face change information and time points in the face recognition system, and determining whether to retrain in the similarity and time dimensions, the problem of difficulty in determining the update frequency in the prior art is solved, and a balance between high accuracy and resource saving is achieved.
Patent Information
- Application Number
- CN202110129877.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-01-29
- Publication Date
- 2025-06-24
- Estimated Expiration
- 2041-01-29
AI Technical Summary
In the prior art, the method of periodic update of databases cannot take into account the accuracy of facial recognition and avoid resource waste. Especially in the case of face changes, the update frequency is difficult to determine.
By determining the time point for the next update of the standard photo based on the face change information and the time point for the previous update of the standard photo, the time point for the next update of the standard photo is predetermined, and determining whether to start the standard photo retraining training is started in the two dimensions of similarity and time, and the face characteristics obtained from the training are updated.
It achieves the goal of taking into account the accuracy of facial recognition while avoiding unnecessary standard retraining, reducing resource waste, and improving the accuracy of facial recognition.
Smart Images

Figure CN112784793B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of artificial intelligence, and particularly to a method, device, computer device and storage medium for updating standard face recognition photos. Background Art
[0002] With the rapid development of face recognition technology, face recognition has gradually been applied to various industries due to its advantages such as being difficult to forge and convenient to use. For example, access control, face payment, identity verification, etc. Especially in the huge banking business system, face recognition is used in more and more scenarios to determine whether the customer is the person himself. In scenarios such as counter transactions and face payment involving the purchase of financial products, it is necessary to check and verify the identity of the customer to ensure that the customer is conducting the transaction himself, thereby protecting the customer's funds. However, during the face recognition process, there are problems such as recognition posture, face changes, and insufficient light, which may lead to face recognition failure. In the case of face changes, factors such as age increase, physical condition changes, staying up late, and plastic surgery of a person will all reduce the accuracy of face recognition.
[0003] In existing methods, most focus on optimizing the problems of reduced face recognition effect caused by factors such as face occlusion, wearing glasses, and light. For example, when using a deep network model for face recognition, after collecting a face image, an image of a person wearing black-framed glasses is simulated, and the feature values in both the case of not wearing glasses and wearing glasses are extracted, thereby improving the accuracy of face recognition when wearing glasses. However, this method cannot continuously update the database, and when a person's age increases, the accuracy of face recognition will be reduced. To solve the above problems, there is a method of updating the database periodically or when face recognition fails to perform re-training of face features. However, if the period is set too long, the accuracy of face recognition will be reduced; if the period is set too short, unnecessary feature re-training will occur, wasting system resources.
[0004] Therefore, how to update the database in a timely manner, determine when to start re-training face recognition feature values, and improve the accuracy of face recognition has become an urgent problem to be solved in the industry. Summary of the Invention
[0005] An embodiment of the present invention provides a method for updating standard face recognition photos to solve the technical problem that the existing method of periodically updating the database cannot balance accuracy and avoid wasting resources. The method includes:
[0006] Based on the face change information and the degree of change corresponding to the current user at the time point of the previous update of the standard photo, the time point when the difference between the current degree of change and the degree of change corresponding to the time point of the previous update of the standard photo is 1 is determined as the time point for the current user to update the standard photo next time, where the face change information includes the corresponding relationship between each time point in a person's life and the degree of change, and the degree of change represents the number of times of updating the standard photo;
[0007] Obtain the similarity between the facial features of the currently captured photo and the standard photo of the current user, where the standard photo is the stored facial features.
[0008] When the similarity meets the preset similarity requirement and the current time and the time point for the next update of the standard photo meet the preset time requirement, store the currently captured photo, train the facial features based on the currently stored photo set, and update the standard photo of the current user with the trained facial features.
[0009] An embodiment of the present invention further provides a device for updating the standard photo for face recognition to solve the technical problem in the prior art that the method of periodically updating the database cannot balance accuracy and avoid resource waste. The device includes:
[0010] A next update time determination module, configured to determine, according to the facial change information and the degree of change corresponding to the current user at the time point of the previous update of the standard photo, the time point when the difference between the current degree of change and the degree of change corresponding to the time point of the previous update of the standard photo is 1 as the time point for the next update of the standard photo of the current user, where the facial change information includes the correspondence between each time point in life and the degree of change, and the degree of change represents the number of times of updating the standard photo.
[0011] A similarity determination module, configured to obtain the similarity between the facial features of the currently captured photo and the standard photo of the current user, where the standard photo is the stored facial features.
[0012] An update module, configured to store the currently captured photo and train the facial features based on the currently stored photo set and update the standard photo of the current user with the trained facial features when the similarity meets the preset similarity requirement and the current time and the time point for the next update of the standard photo meet the preset time requirement.
[0013] An embodiment of the present invention further provides a computer device, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, it implements any of the above methods for updating the standard photo for face recognition to solve the technical problem in the prior art that the method of periodically updating the database cannot balance accuracy and avoid resource waste.
[0014] An embodiment of the present invention further provides a computer-readable storage medium storing a computer program for executing any of the above methods for updating the standard photo for face recognition to solve the technical problem in the prior art that the method of periodically updating the database cannot balance accuracy and avoid resource waste.
[0015] In an embodiment of the present invention, face change information is proposed. The face change information includes the correspondence between each time point in a person's life and the degree of change. The degree of change represents the number of times the standard photo is updated. Therefore, according to the face change information and the degree of change corresponding to the time point when the current user updated the standard photo last time, the time point for the current user to update the standard photo next time can be determined in advance. For example, the time point when the difference between the current degree of change and the degree of change corresponding to the time point when the standard photo was updated last time is 1 is determined as the time point for the current user to update the standard photo next time. Then, the similarity between the face features of the currently captured photo and the standard photo of the current user is obtained. Finally, when the similarity meets the preset similarity requirement and the current time and the time point for updating the standard photo next time meet the preset time requirement, the currently captured photo is stored, and the standard photo retraining is started. The face features are trained based on the currently stored photo set, and the standard photo of the current user is updated with the trained face features. Compared with the prior art technical solution of periodically updating the standard photo, the similarity dimension measures the difference and consistency between the photo and the standard photo, and the time dimension measures the update frequency of the standard photo from the perspective of the face change rate. It can avoid unnecessary standard photo retraining caused by short-term face changes (such as face feature changes caused by short-term physical problems like colds). The embodiment of the present invention realizes determining whether to start the standard photo retraining through two dimensions of similarity and time, which is beneficial to avoiding the problems of too slow or too fast standard photo updates, is beneficial to starting the standard photo retraining more accurately and precisely, is beneficial to improving the accuracy of face recognition, and is also beneficial to avoiding resource waste caused by frequent starting of face feature retraining, and thus is beneficial to achieving the balance between the accuracy of face recognition and avoiding resource waste. BRIEF DESCRIPTION OF THE DRAWINGS
[0016] The drawings described herein are used to provide a further understanding of the present invention, form a part of this application, and do not limit the present invention. In the drawings:
[0017] Figure 1 is a flowchart of a method for updating the standard photo for face recognition provided by an embodiment of the present invention;
[0018] Figure 2 is a flowchart of a specific implementation of the method for updating the standard photo for face recognition described above;
[0019] Figure 3 is a flowchart of the process for updating the photos in the database provided by an embodiment of the present invention;
[0020] Figure 4 is a schematic diagram of similarity comparison provided by an embodiment of the present invention;
[0021] Figure 5 is a schematic diagram of the photo storage queue provided by an embodiment of the present invention;
[0022] Figure 6 is a flowchart of a training process for a life gradual change curve provided by an embodiment of the present invention;
[0023] Figure 7 is a schematic diagram of the individual face change curve of Customer 1 provided by an embodiment of the present invention;
[0024] Figure 8 is a schematic diagram of a general face change curve at the age of 40 provided by an embodiment of the present invention;
[0025] Figure 9 is a schematic diagram of a life gradual change curve provided by an embodiment of the present invention;
[0026] Figure 10 is a flowchart of a process for starting the retraining of face features provided by an embodiment of the present invention;
[0027] Figure 11 is a structural block diagram of a computer device provided by an embodiment of the present invention;
[0028] Figure 12 is a structural block diagram of a device for updating the standard face recognition photo provided by an embodiment of the present invention. Detailed implementation manners
[0029] To make the objectives, technical solutions, and advantages of the present invention clearer and more understandable, the present invention will be further described in detail below in conjunction with the implementation manners and the accompanying drawings. Here, the illustrative implementation manners of the present invention and their descriptions are used to explain the present invention, but do not limit the present invention.
[0030] In an embodiment of the present invention, a method for updating the standard face recognition photo is provided. As Figure 1 shown, the method includes:
[0031] Step 102: According to the face change information and the degree of change corresponding to the time point when the current user updated the standard photo last time, determine the time point when the difference between the current degree of change and the degree of change corresponding to the time point when the standard photo was updated last time is 1 as the time point for the current user to update the standard photo next time, where the face change information includes the corresponding relationship between each time point in life and the degree of change, and the degree of change represents the number of times of updating the standard photo;
[0032] Step 104: Obtain the similarity between the face features of the currently captured photo and the standard photo of the current user, where the standard photo is the stored face features;
[0033] Step 106: When the similarity meets the preset similarity requirement and the current time and the time point for the next update of the standard photo meet the preset time requirement, store the currently captured photo, train the face features based on the currently stored photo set, and update the standard photo of the current user with the trained face features.
[0034] As can be seen from Figure 1 the process shown, in the embodiment of the present invention, face change information is proposed. This face change information includes the correspondence between each time point in life and the degree of change, and the degree of change represents the number of times the standard photo is updated. Therefore, according to the face change information and the degree of change corresponding to the time point when the current user updated the standard photo last time, the time point for the current user to update the standard photo next time can be determined in advance. For example, the time point when the difference between the current degree of change and the degree of change corresponding to the time point when the standard photo was updated last time is 1 is determined as the time point for the current user to update the standard photo next time. Then, obtain the similarity between the face features of the currently captured photo and the standard photo of the current user. Finally, when the similarity meets the preset similarity requirement and the current time and the time point for the next update of the standard photo meet the preset time requirement, store the currently captured photo, start the retraining of the standard photo, train the face features based on the currently stored photo set, and update the standard photo of the current user with the trained face features. Compared with the prior art technical solution of periodically updating the standard photo, the similarity dimension measures the difference and consistency between the photo set and the standard photo, and the time dimension measures the update frequency of the standard photo from the perspective of the face change rate, which can avoid unnecessary retraining of the standard photo caused by short-term face changes (such as face feature changes caused by transient physical problems like colds). The embodiment of the present invention realizes determining whether to start the retraining of the standard photo through two dimensions of similarity and time, which is beneficial to avoiding the problem of too slow or too fast update of the standard photo, is beneficial to starting the retraining of the standard photo more accurately and precisely, is beneficial to improving the accuracy of face recognition while avoiding resource waste caused by frequent starting of face feature retraining, and thus is beneficial to achieving the balance between the accuracy of face recognition and avoiding resource waste.
[0035] Specifically in implementation, the above face recognition standard photo update method realizes judging whether to start the retraining of the standard photo by combining similarity and time when the user has a standard photo. Therefore, in order to enable the user to have a standard photo and combine similarity and time to judge whether to start the retraining of the standard photo in real time when capturing photos, as Figure 2 and Figure 3 shown, the process of updating the user's database photo is realized through the following steps:
[0036] Step 302: Judge whether the user is using the face recognition system for the first time;
[0037] Step 304: When the user uses the face recognition system for the first time, all the collected photos are directly stored in the database. When the number of collected photos reaches the preset threshold a, the face recognition feature training is started, and the face features trained from this batch of collected photos are recorded as the standard photo of the customer. When the user is not using the face recognition system for the first time, the user's photos are collected periodically or when face recognition is used. For example, in the actual application of the face recognition system, photos can be collected according to the set ideal photo collection period T.
[0038] Step 306: Mark the collected user photos with a timestamp (i.e., mark the collection time), compare the similarity between the newly collected photos and the standard photos in the database, and then determine whether to retain the newly collected photos.
[0039] In specific implementation, in order to accurately update the photos and accurately determine whether to start the retraining of the standard photo when collecting photos in real time, in this embodiment, when collecting the user's photos periodically, the similarity between the face features of the collected photos and the user's standard photo is determined. When the similarity is less than the first preset similarity, it is determined that the collected photo and the user's standard photo do not belong to the same person, and the collected photo is discarded. When the similarity is greater than the first preset similarity and less than the second preset similarity, the collected photo is stored and marked with a timestamp, and the face feature training is triggered based on the currently stored photo set, and the face features obtained by training are used to update the user's standard photo. When the similarity is greater than the second preset similarity and less than the third preset similarity, the collected photo is stored and marked with a timestamp. When the similarity is greater than the third preset similarity, the collected photo is discarded.
[0040] Specifically, the standard photo trained from the photo set already stored in the database can be denoted as S, the face features of the newly collected photo can be denoted as S′, and λ is used to represent the similarity between the standard photo and the face features of the newly collected photo. For example Figure 4As shown in the figure, the first preset similarity is λ0. λ0 represents the threshold of low similarity between the face features of the newly captured photo and the standard photo, and is used to distinguish whether the newly captured photo and the standard photo belong to the same person. For example, when λ ≤ λ0, the newly captured photo and the standard photo are not the same person, and the captured photo is discarded; the second preset similarity is λ1. λ1 represents the threshold of ordinary similarity between the face features of the newly captured photo and the standard photo. λ1 is used to distinguish whether the degree of similarity difference between the face features of the newly captured photo and the standard photo requires starting the retraining of the standard photo. For example, when the similarity between the face features of the newly captured photo and the standard photo is low, that is, λ0 < λ < λ1, and the current capture time and the time point when the current user updates the standard photo next time meet the preset time requirements, then store the captured photo and mark the time stamp on the photo, and directly start the retraining of the face recognition features. Based on the newly captured photos stored and the photos already stored in the database, a photo set is formed, and the face features are trained according to the currently stored photo set, and the standard photo in the database is updated with the face features obtained by training; the third preset similarity is λ2. λ2 represents the threshold of moderate similarity between the face features of the newly captured photo and the standard photo. λ2 is used to distinguish whether the degree of similarity difference between the face features of the newly captured photo and the standard photo requires storing the newly captured photo. For example, when the similarity between the face features of the newly captured photo and the standard photo is moderately similar, that is, λ1 < λ < λ2, it means that there are certain changes between the newly captured photo and the standard photo, then store the captured photo and mark the time stamp on the photo; when the similarity between the face features of the newly captured photo and the standard photo is highly similar, that is, λ2 < λ < 1, then discard the captured photo.
[0041] In specific implementation, during the process of storing the captured photo and marking the time stamp on the photo, the photo storage method is as Figure 5 shown. The photos of each customer can be stored in a queue manner, and when marking the time stamp on the photo according to the capture time, the capture time can be directly marked on the photo, or the photos can be numbered according to the size of the capture time. The larger the time (that is, the closer the time is), the larger the marked number. As Figure 5 shown, A1A2A3...A n-1 are the photos stored by the user in the database. The larger the subscript, the more recent the photo of the user, and the closer it is to the true appearance of the current user.
[0042] In specific implementation, in order to determine the time point for the user to update the next standard photo, in this embodiment, the following steps are proposed to obtain the face change information. For example, for each age group in a person's life, obtain the standard photo update time and the corresponding change degree of each user in this age group, where the change degree increases by 1 for each update of the standard photo; according to the standard photo update time and the corresponding change degree of each user in this age group, fit the face change curve of this age group; splice the face change curves of each age group in chronological order to obtain the life gradual change curve, and determine the life gradual change curve as the face change information.
[0043] In specific implementation, the process of training the life gradual change curve to obtain the face change information is as Figure 6 shown, including the following steps:
[0044] Step 602: Record the time point and the change degree when each customer in a certain age group starts the face feature retraining within the specified time, and obtain the face change curve of each customer;
[0045] Specifically, for different age groups, each age group can take a period of time as an operation cycle. For example, taking one year as an operation cycle, for customer 1 at the age of 40, obtain the record of the standard photo update time point and the corresponding change degree of customer 1 at the age of 40 in this year of 40 years old, which can be expressed as where i is the numbering of the times when customer 1 starts the face feature retraining in this year of 40 years old, and m is the number of customers participating in the statistics of this age group of 40 years old, that is indicating that customer 1 triggers the face feature retraining for the first time in this year of 40 years old. Each time the face feature retraining is started, it is regarded as the change degree increasing by 1, and the standard photo stored in the database is updated. By recording the time point and the corresponding change degree of the face feature training started in this year, and connecting all the discrete points with a curve, the individual face change curve (Face-Curve) of customer 1 can be simulated, as Figure 7 shown.
[0046] Step 604: Fit the face change curve of this age group according to the face change curves of multiple customers in the same age group;
[0047] Specifically, collect the face change curves of multiple users in the same age group. Since people's facial feature change rates are similar in the same age group, the general face change curve (Face-GrCurve) of this age group can be fitted according to the face change curves of multiple users in the same age group. For example, according to the Face-Curve of m customers at the age of 40, fit the general face change curve (Face-GrCurve) applicable to all customers at the age of 40, as Figure 8 shown. The thin lines from bottom to top and represents the Face-Curve of m 40-year-old customers in the year when they turn 40. Among them, The curve of is different from the curves of other customers by more than the preset threshold ξ, that is, the change trend of the curve of this customer 3 is significantly different from that of other customers. This phenomenon may be due to abnormal facial feature changes caused by the customer 3 getting sick or having a large change in makeup in a short period of time. Such changes belong to individual abnormalities. Then, the data of this customer 3 collected can be regarded as noise points, and the data of this customer 3 can be removed. Fit the Face-Curve of m - n customers after removing the noise points, where n is the number of customers with abnormal data. Take the average value of all function values at the same time point on the curve to obtain the universal facial change curve applicable to all customers at the age of 40
[0048] Step 606: Integrate the facial change curves of all age groups to obtain the life gradual change curve.
[0049] Specifically, through the above method, connect the Face-GrCurves of different age groups, and smooth the connected curve to obtain the life gradual change curve (Life-GrCurve), that is, the above facial change information, as Figure 9 shown. During the juvenile period from 0 to about 20 years old, most people's facial features change greatly, so the frequency of triggering the retraining of facial features is also relatively high. When entering the youth period from 20 to about 30 years old, the facial changes are relatively small. After exceeding 30 years old, slowly entering middle age and old age, the changes of facial features also gradually increase. According to the fitted Life-GrCurve, the time point for starting the retraining of facial features can be calculated, which is used as a reference standard in the time dimension for the retraining standard photo.
[0050] In specific implementation, after obtaining the facial change information, the process of determining whether to start a new round of retraining of facial features in the two dimensions of similarity and time is as Figure 10 shown, including the following steps:
[0051] Step 1002: Determine the time node for the next retraining of facial features according to the life gradual change curve (i.e., the facial change information);
[0052] Step 1004: Combine the similarity and time dimensions to judge whether to start a new round of retraining of facial features;
[0053] Step 1006: Determine the weight of each photo used for the retraining of the standard photo through the AHP algorithm.
[0054] Specifically, the specific operation for determining whether to initiate a new round of face feature retraining by combining similarity and time dimension is as follows: When the similarity between the face features of the currently captured photo and the standard photo of the current user meets the preset similarity requirement, and the current time and the time point for the next update of the standard photo meet the preset time requirement, face feature retraining can be initiated; otherwise, face feature retraining is not initiated.
[0055] Specifically, the similarity between the face features of the currently captured photo and the standard photo of the current user meets the preset similarity requirement. Specifically, it can be that the similarity is greater than the first preset similarity and less than the second preset similarity, where the second preset similarity is greater than the first preset similarity. The first preset similarity is used to distinguish whether the face features of the photo set and the standard photo belong to the same person. Here, the second preset similarity and the first preset similarity can be the same as the second preset similarity and the first preset similarity during the similarity comparison in the process of photo capture, that is, the first preset similarity is λ0, and the second preset similarity is λ1.
[0056] In specific implementation, the current time and the time point for the next update of the standard photo meet the preset time requirement. Specifically, it can be that the current time is equal to the time point for the next update of the standard photo. For example, assuming that each face feature retraining is regarded as an increase in the change degree by 1, and the function f(x) represents the life gradual change curve (i.e., the above-mentioned face change information). If face feature retraining was initiated at t1 last time, then the time point t2 for the next face feature retraining satisfies equation (1).
[0057] f(t2) - f(t1) = 1 (1)
[0058] Therefore, when the current time is equal to the time point t2 for the next update of the standard photo, it can be considered that the current time and the time point for the next update of the standard photo meet the preset time requirement.
[0059] In addition, due to certain individual differences among each customer, some people's faces change faster, and some people's faces change slower. Therefore, a time offset is proposed to be added in the process of calculating the start time of standard photo retraining. This time offset is determined according to the individual face change differences. Subtracting the preset time offset from the time point for the next update of the standard photo to obtain a time point. When the current time is greater than this time point, it can be considered that the current time and the time point for the next update of the standard photo meet the preset time requirement.
[0060] For example, when the current time t and the similarity λ satisfy equation (2), the standard photo retraining can be initiated.
[0061]
[0062] Among them, the first preset similarity λ0 and the second preset similarity λ1 respectively represent the critical values of low similarity and medium similarity, σ represents the time offset, and the value of σ satisfies Equation (3).
[0063]
[0064] Among them, d is a preset parameter value, and the value of d can be determined according to actual data statistics. For example, if d = 10, then when and the similarity between the collected photo and the existing standard photo in the database is low (i.e., meeting the preset similarity requirement), the standard photo retraining is started.
[0065] During specific implementation, during the process of standard photo training, in order to improve the consistency between the standard photo and the user's recent appearance, in this embodiment, a weight is determined for each photo in the currently stored photo set according to the timestamp of each photo, where the closer the timestamp is to the current time, the greater the weight; and then the face features are trained based on the photos in the currently stored photo set and the weights corresponding to the photos, so as to highlight the importance of recent photos in training face features.
[0066] During specific implementation, the AHP algorithm can be used to determine the weight of each photo used for training the standard photo. For example, the importance value of each two photos is determined according to the time difference between the acquisition times of every two photos; a judgment matrix is constructed with the importance values of every two photos, and according to the judgment matrix and the largest eigenvalue of the judgment matrix, the eigenvector of the judgment matrix is determined; the eigenvector is normalized to obtain a vector composed of the weights of each photo, where the sum of the weights of each photo in the photo set is 1.
[0067] Specifically, the importance of photos can be quantified by the nine-level scale method, the importance value of each two photos is determined according to the time difference between the acquisition times of every two photos, and the judgment matrix P is constructed according to Equation (4), where r ij is the comparison of the importance of every two photos, n is the number of photos. Here, three photos are taken as an example, but in practical applications, it is not limited to these three photos.
[0068] P=(r ij ) n×n ,r ij =1 / r ji ,r ij >0, i, j = 1, 2, 3,..., n (4)
[0069] The judgment matrix P can be expressed in the form of Equation (5):
[0070]
[0071] Among them, P1, P2, and P3 respectively represent the photos collected in the database. The larger the subscript (i.e., representing the timestamp), the closer it is to the recent photo of the customer. Let Pw = λ max w, where w is the eigenvector and λ max is the largest eigenvalue. After normalizing w, the weight of each photo in the process of re-training the standard photo is obtained, as shown in Equation (6).
[0072] U = [u1, u2, …, u n T (6)
[0073] Among them, the weights corresponding to the n photos used to train the standard photo satisfy u1 + u2 + … + u n = 1.
[0074] In specific implementation, due to the particularity of some customers, the facial change rate is slower or faster than that of the general public. If only the time dimension and similarity are used to determine whether to start the re-training of the standard photo, it may lead to a decrease in the face recognition accuracy of customers with faster facial feature changes. Therefore, in order to further improve the face recognition accuracy, in this embodiment, it is proposed that when face recognition fails, identity recognition is performed through the user's biometric features. After successful recognition and receiving the instruction from the user to confirm the update of the standard photo, the user's photo is collected and stored, and the face features are trained based on the currently stored photo set, and the trained face features are used to update the user's said standard photo.
[0075] In specific implementation, as Figure 2 shown, the customer interaction function can be added during the use of the face recognition system. When face recognition fails, a pop-up window prompts the customer at the terminal to confirm whether the transaction is made by himself / herself, and auxiliary identity recognition is performed through other biometric features such as fingerprints. If the fingerprint recognition is successful and the instruction from the user to subjectively confirm the update of the standard photo is received, the photo of the customer can be collected, and the re-training of the standard photo is started, and during the process of constructing the judgment matrix, the weight of the photo collected after the customer's fingerprint confirmation is increased.
[0076] In this embodiment, a computer device is provided, as Figure 11 shown, including a memory 1102, a processor 1104, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, the above-mentioned arbitrary face recognition standard photo update method is implemented.
[0077] Specifically, the computer device can be a computer terminal, a server, or a similar computing device.
[0078] In this embodiment, a computer-readable storage medium is provided, and the computer-readable storage medium stores a computer program for executing any of the above-mentioned face recognition standard photo update methods.
[0079] Specifically, a computer-readable storage medium includes permanent and non-permanent, removable and non-removable media, and information storage can be implemented by any method or technology. The information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer-readable 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, compact disc read-only memory (CD-ROM), digital versatile disc (DVD), or other optical storage, magnetic cassette tapes, magnetic tape magnetic disk storage, or other magnetic storage devices, or any other non-transmission medium that can be used to store information accessible by a computing device. As defined herein, a computer-readable storage medium does not include transitory computer-readable media, such as modulated data signals and carrier waves.
[0080] Based on the same inventive concept, an embodiment of the present invention also provides a face recognition standard photo update device as described in the following embodiments. Since the principle of the face recognition standard photo update device for solving problems is similar to that of the face recognition standard photo update method, the implementation of the face recognition standard photo update device can refer to the implementation of the face recognition standard photo update method, and the repeated parts will not be described again. As used hereinafter, the term "unit" or "module" can be a combination of software and / or hardware that can implement a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware is also possible and contemplated.
[0081] Figure 12 is a structural block diagram of the face recognition standard photo update device according to an embodiment of the present invention, as Figure 12 shown, the device further includes:
[0082] A next update time determination module 1202, configured to determine, according to the face change information and the change degree corresponding to the current user at the time point of the previous update of the standard photo, the time point when the difference between the current change degree and the change degree corresponding to the time point of the previous update of the standard photo is 1 as the time point for the current user to update the standard photo next time, where the face change information includes the correspondence between each time point in life and the change degree, and the change degree represents the number of times of updating the standard photo;
[0083] A similarity determination module 1204, configured to obtain the similarity between the facial features of the currently captured photo and the standard photo of the current user, where the standard photo is the stored facial features.
[0084] An update module 1206, configured to store the currently captured photo and train the facial features based on the currently stored photo set when the similarity meets the preset similarity requirement and the current time meets the preset time requirement for the next update of the standard photo, and update the standard photo of the current user with the trained facial features.
[0085] In one embodiment, the preset similarity requirement is that the similarity is greater than a first preset similarity and less than a second preset similarity, where the second preset similarity is greater than the first preset similarity, and the first preset similarity is used to distinguish whether the facial features of the photo set and the standard photo belong to the same person.
[0086] In one embodiment, the preset time requirement is that the current time is equal to the time point for the next update of the standard photo; or, a time point is obtained by subtracting a preset time offset from the time point for the next update of the standard photo, and the current time is greater than the time point.
[0087] In one embodiment, it further includes:
[0088] A facial change information acquisition module, configured to, for each age group, obtain the time point for updating the standard photo and the corresponding change degree of each user in that age group, where the change degree increases by 1 each time the standard photo is updated; fit a facial change curve for that age group based on the time points for updating the standard photos and the corresponding change degrees of the users in that age group; splice the facial change curves of each age group in chronological order to obtain a life gradual change curve, and determine the life gradual change curve as the facial change information.
[0089] In one embodiment, the update module is specifically configured to determine a weight for each photo in the currently stored photo set according to the timestamp of each photo, where the closer the timestamp is to the current time, the greater the weight; and train the facial features based on the photos and the corresponding weights in the currently stored photo set.
[0090] In one embodiment, the update module is further configured to determine the importance value of every two photos according to the difference in the acquisition time of every two photos; construct a judgment matrix with the importance values of every two photos, and determine the eigenvector of the judgment matrix according to the judgment matrix and the largest eigenvalue of the judgment matrix; perform normalization processing on the eigenvector to obtain a vector composed of the weights of each photo, where the sum of the weights of each photo in the photo set is 1.
[0091] In one embodiment, it further includes:
[0092] A photo update module, configured to determine that the captured photo and the user's standard photo do not belong to the same person and discard the captured photo if the similarity is less than a first preset similarity; store the captured photo and mark a timestamp for the photo if the similarity is greater than a second preset similarity and less than a third preset similarity; and discard the captured photo if the similarity is greater than the third preset similarity, where the second preset similarity is greater than the first preset similarity, and the third preset similarity is greater than the second preset similarity.
[0093] In one embodiment, it further includes:
[0094] A biometric recognition module, configured to perform identity recognition through the user's biometric features when face recognition fails;
[0095] The update module is further configured to, when receiving an instruction from the user to confirm the update of the standard photo after successful recognition, trigger the capture and storage of the user's photo, train face features based on the currently stored photo set, and update the user's standard photo with the trained face features.
[0096] The embodiments of the present invention achieve the following technical effects: The face change information is proposed, which includes the correspondence between each time point in life and the change degree. The change degree represents the number of times of updating the standard photo. Therefore, according to the face change information and the change degree corresponding to the time point when the current user updated the standard photo last time, the time point for the current user to update the standard photo next time can be determined in advance. For example, the time point when the difference between the current change degree and the change degree corresponding to the time point when the standard photo was updated last time is 1 is determined as the time for the current user to update the standard photo next time. Then, the similarity between the face features of the currently stored photo set and the standard photo of the current user is obtained. Finally, when the similarity meets the preset similarity requirement and the current time and the time point for updating the standard photo next time meet the preset time requirement, the currently captured photo is stored, and the standard photo retraining is started. The face features are trained according to the currently stored photo set, and the standard photo of the current user is updated with the trained face features. Compared with the prior art technical solution of periodically updating the standard photo, the similarity dimension measures the difference and consistency between the photo set and the standard photo, and the time dimension measures the update frequency of the standard photo from the perspective of the face change rate. It can avoid unnecessary standard photo retraining caused by short-term face changes (such as face feature changes caused by short-term physical problems such as colds). The embodiments of the present invention achieve the determination of whether to start the standard photo retraining through two dimensions of similarity and time, which is beneficial to avoiding the problems of too slow or too fast update of the standard photo, is beneficial to starting the standard photo retraining more accurately and precisely, is beneficial to improving the accuracy of face recognition, and is beneficial to avoiding resource waste caused by frequent start of face feature retraining, and thus is beneficial to achieving the balance between the accuracy of face recognition and avoiding resource waste.
[0097] Those skilled in the art should understand that the embodiments of the present invention can be provided as a method, a system, or a computer program product. Therefore, the present invention can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present invention can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0098] The present invention is described with reference to the flowcharts and / or block diagrams of methods, apparatuses (systems), and computer program products according to the embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, and the combination of processes and / or blocks in the flowchart and / or block diagram can be realized by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing devices generate for realizing the processFigure 1 one process or multiple processes and / or blocks Figure 1 a device for the functions specified in one block or multiple blocks.
[0099] These computer program instructions can also be stored in a computer-readable memory capable of guiding a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory produce a manufactured article including an instruction device, and the instruction device implements the processes Figure 1 one process or multiple processes and / or blocks Figure 1 the functions specified in one block or multiple blocks.
[0100] These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operation steps are executed on the computer or other programmable device to generate a computer-implemented process. Therefore, the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in Figure 1 one process or multiple processes and / or blocks Figure 1 one block or multiple blocks.
[0101] The specific embodiments described above further elaborate on the purpose, technical solutions, and beneficial effects of the present invention. It should be understood that the above are only specific embodiments of the present invention and are not used to limit the protection scope of the present invention. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A method for updating a standard photo for face recognition, characterized in that, Including: Based on the face change information and the change degree corresponding to the time point when the current user updated the standard photo last time, determine the time point when the difference between the current change degree and the change degree corresponding to the time point when the standard photo was updated last time is 1 as the time point for the current user to update the standard photo next time. Wherein, the face change information includes the corresponding relationship between each time point in life and the change degree, and the change degree represents the number of times the standard photo is updated; Obtain the similarity between the face feature of the currently captured photo and the standard photo of the current user, where the standard photo is the stored face feature; When the similarity meets the preset similarity requirement and the current time and the time point for updating the standard photo next time meet the preset time requirement, store the currently captured photo, train the face feature based on the currently stored photo set, and update the standard photo of the current user with the trained face feature; It also includes: For each age group, obtain the standard photo update time point and the corresponding change degree of each user in this age group. Wherein, the change degree increases by 1 for each update of the standard photo; According to the standard photo update time points and the corresponding change degrees of each user in this age group, fit the face change curve of this age group; Piece together the face change curves of each age group in chronological order to obtain the life gradual change curve, and determine the life gradual change curve as the face change information; The similarity meeting the preset similarity requirement includes: The similarity is greater than the first preset similarity and less than the second preset similarity, where the second preset similarity is greater than the first preset similarity, and the first preset similarity is used to distinguish whether the face feature of the photo set and the standard photo belong to the same person.
2. The method for updating the standard face recognition photo according to claim 1, wherein, The current time and the time point for updating the standard photo next time meeting the preset time requirement includes: The current time is equal to the time point for updating the standard photo next time; or Subtract the preset time offset from the time point for updating the standard photo next time to obtain a time point, and the current time is greater than this time point.
3. The method for updating the standard face recognition photo according to claim 1, wherein, Training the face feature based on the currently stored photo set includes: According to the timestamp of each photo in the currently stored photo set, determine a weight for each photo, where the closer the timestamp is to the current time, the greater the weight; Train the face feature based on the photos and the corresponding weights in the currently stored photo set.
4. The method for updating the standard face recognition photo according to claim 3, wherein Determining a weight for each photo according to the acquisition time of each photo in the currently stored photo set includes: Determine the importance value of every two photos according to the difference between the acquisition times of every two photos; Construct a judgment matrix with the importance values of every two photos, and determine the eigenvector of the judgment matrix according to the judgment matrix and the largest eigenvalue of the judgment matrix; Normalize the eigenvector to obtain a vector composed of the weights of each photo, where the sum of the weights of each photo in the photo set is 1.
5. The method for updating the standard face recognition photo according to any one of claims 1 to 4, characterized in that, It also includes: When the similarity is less than the first preset similarity, determine that the captured photo and the standard photo of the user do not belong to the same person, and discard the captured photo; When the similarity is greater than a second preset similarity and less than a third preset similarity, store the captured photo and mark a timestamp for the photo; When the similarity is greater than the third preset similarity, discard the captured photo, where the second preset similarity is greater than the first preset similarity, and the third preset similarity is greater than the second preset similarity.
6. The method for updating the standard face recognition photo according to any one of claims 1 to 4, characterized in that, It further includes: When face recognition fails, perform identity recognition through the user's biometric features. When a command to confirm the update of the standard photo is received after successful recognition, capture and store the user's photo, train face features based on the currently stored photo set, and update the user's standard photo with the trained face features.
7. A standard photo updating device for face recognition, characterized in that, It includes: Next update time determination module, configured to determine, according to the face change information and the degree of change corresponding to the time point when the current user updated the standard photo last time, the time point when the difference between the current degree of change and the degree of change corresponding to the time point when the standard photo was updated last time is 1 as the time point for the current user to update the standard photo next time, where the face change information includes the correspondence between each time point in life and the degree of change, and the degree of change represents the number of times the standard photo is updated; Similarity determination module, configured to obtain the similarity between the face features of the currently captured photo and the standard photo of the current user, where the standard photo is the stored face features; Update module, configured to when the similarity meets the preset similarity requirements and the current time meets the preset time requirements with respect to the time point for updating the standard photo next time, store the currently captured photo, train face features based on the currently stored photo set, and update the standard photo of the current user with the trained face features; It further includes: a face change information acquisition module, configured to, for each age group, obtain the standard photo update time point and the corresponding degree of change of each user in that age group, where the degree of change increases by 1 for each update of the standard photo; fit the face change curve of that age group according to the standard photo update time points and the corresponding degrees of change of each user in that age group; splice the face change curves of each age group in chronological order to obtain a life gradual change curve, and determine the life gradual change curve as the face change information; The similarity meeting the preset similarity requirements includes: the similarity is greater than a first preset similarity and less than a second preset similarity, where the second preset similarity is greater than the first preset similarity, and the first preset similarity is used to distinguish whether the face features of the photo set and the standard photo belong to the same person.
8. A computer device, comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the face recognition standard photo update method according to any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program for executing the face recognition standard photo update method according to any one of claims 1 to 6.
Citation Information
Patent Citations
Method for improving face recognition accuracy rate and adaptability through updating of images
CN102968645A
Human face identification method based on human face characteristic data mining and device
CN103778409A