# Patent

## Title
Method for authenticating identity of handset user

## Abstract

A method for authenticating the identity of a handset user is provided. The method includes: obtaining, a login account and a password from the user; judging whether the login account and the password are correct; if the login account or the password is incorrect, refusing the user to access an operating system of the handset; if the login account and the password are correct, sending the login account and the password to a cloud server, wherein the login account and the password correspond to a face sample image library of the user stored on the cloud server; acquiring an input face image of the user; sending the input face image to the cloud server; authenticating, by the cloud server, the identity of the user according to the login account, the password and the input face image.

## Background
CROSS REFERENCE TO RELATED APPLICATIONS
This application is a continuation of International Application No. PCT/CN2011/076623, filed on Jun. 30, 2011, which is hereby incorporated by reference in its entirety.
FIELD OF THE INVENTION
The present invention relates to the field of communication technologies, and in particular, to a method for authenticating the identity of a handset user.
BACKGROUND OF THE INVENTION
With the widespread popularity of handsets, especially smart handsets, the security of the operating systems of the handsets becomes increasingly important. Currently, most smart handsets only use a login account and a password of a user as a means for identity authentication. However, this method is not secure, and as soon as the login account and the password are stolen by other users, all data on the operating system of the handset is exposed.
The technology using biological features of a human body, especially the face, for security authentication, develops rapidly. However, the computational complexity of the face authentication is high, and the computational resources of a handset are generally limited, so that it is difficult to support the face authentication with a heavy computational burden. In addition, in conventional face authentication systems, face authentication algorithms are rough and thus the probability of misjudgment is very high.
SUMMARY OF THE INVENTION
Embodiments of the present invention provide a method for authenticating the identity of a handset user. Embodiments of the present invention are based on the cloud computing technology, the cloud server can bear the load of identity authentication, thus improving the security of the operating system of the handset, enhancing the user's experience and raising the precision of the face authentication.
An embodiment of the present invention provides a method for authenticating the identity of a handset user, wherein the user's handset is connected to the cloud server through a communication network, the cloud server stores a face sample image library corresponding to the user, and the method includes:

    
    
        obtaining, by the handset, a login account and a password from the user;
        judging, by the handset, whether the login account and the password are correct;
        if the login account or the password is incorrect, refusing, by the handset, the user to access an operating system of the handset;
        if the login account and the password are correct, sending, by the handset, the login account and the password to the cloud server, wherein the login account and the password correspond to a face sample image library of the user stored on the cloud server;
        acquiring, by the handset, an input face image of the user;
        sending, by the handset, the input face image to the cloud server;
        authenticating, by the cloud server, the identity of the user according to the login account, the password and the input face image;
        judging, by the cloud server, whether the user is allowed to access the operating system of the handset;
        wherein the step of judging whether the user is allowed to access the operating system of the handset comprises:
        step A. determining, by the cloud server, according to the login account and the password, the face sample image library of the user corresponding to the login account and the password;
        step B. obtaining, by the cloud server, a face feature similarity value (FFSV) according to the input face image and the face sample image library; wherein the face feature similarity value represents the degree of similarity between the input face image and each face sample image in the face sample image library;
        wherein the step of B comprises:
        step B1. obtaining, by the cloud server, a face region image from the input face image;
        step B2. calculating, by the cloud server, a first characteristic value of each face sample image in the face sample image library and a second characteristic value of the face region image;
        step B3. calculating, by the cloud server, a characteristic distance between the first characteristic value of each face sample image in the face sample image library and the second characteristic value of the face region image, to obtain multiple second characteristic distances; determining, by the cloud server, a face feature similarity value (FFSV) according to the multiple second characteristic distances;
        step C. judging, the cloud server, whether the face feature similarity value is larger than a preset threshold, wherein the preset threshold is obtained according to multiple first characteristic distances between each face sample image in the face sample image library;
        step D. if the face feature similarity value is not larger than the preset threshold, allowing, by the cloud server, the user to access the operating system of the handset;
        step E. if the face feature similarity value is larger than the preset threshold, calculating, by the cloud server, a first number and a second number, wherein the first number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are larger than the face feature similarity value, and the second number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are not larger than the face feature similarity value; judging, by the cloud server, whether the first number is larger than the second number;
        step F. if the first number is smaller than the second number, refusing the user to access the operating system of the handset;
        step G. if the first number is not smaller than the second number, allowing, by the cloud server, the user to access the operating system of the handset.
    
    


In the embodiment of the present invention, the cloud server can bear the load of identity authentication, thus improving the security of the operating system of the handset, enhancing the user's experience and raising the precision of the face authentication.



BRIEF DESCRIPTION OF THE DRAWINGS
FIG. 1 is a flow chart of a method for authenticating the identity of a handset user according to the first embodiment of the present invention.
FIG. 2 is a schematic structural view illustrating a cloud server according to the second embodiment of the present invention.
FIG. 3 is a schematic structural view illustrating a unit for determining a FFSV of the cloud server according to the second embodiment of the present invention.
FIG. 4 is a schematic structural view illustrating a network system according to the third embodiment of the present invention.



DETAILED DESCRIPTION OF THE EMBODIMENTS
Cloud computing is an Internet-based computation method, by which shared software and hardware resources and information may be provided to computers, handsets and other devices as required. A typical cloud computing provider tends to provide general network service applications, which may be accessed by software such as a browser or other Web services, and the software and data are all stored on a cloud server.
Embodiments of the present invention are based on the cloud computing technology, and the task for authenticating the identity of a handset may be assigned to a cloud server, so that the burden of the handset is reduced, and high-overhead services can be introduced into the handset, thus enhancing the user's experience.
In the embodiments of the present invention, the user's handset is connected to the cloud server through a communication network, the cloud server stores a face sample image library corresponding to the user and may be managed by a telecommunication operator, and the user registers the face sample images with the cloud server of the telecommunication operator when subscribing. The cloud server binds the user's handset number, the login account and password of the operating system of the handset and other information to the face sample image library.
Embodiment 1
FIG. 1 shows a flowchart of a method for authenticating the identity of a handset user according to the first embodiment of the present invention. As shown in FIG. 1, the method includes the following steps:
Step S101: The user enters a login account and a password on the handset.
Step S103: The handset judges whether the login account and the password are correct.
Step S105: If the login account or the password is incorrect, the user is not allowed to access the operating system of the handset and an error is displayed.
Step S107: If the login account and the password are correct, the login account and the password are sent to the cloud server, where the login account and the password correspond to a face sample image library of the user stored on the cloud server.
Step S109: The handset starts a camera to acquire an input face image of the user and send the input face image to the cloud server.
Step S111: The cloud server authenticates the identity of the user according to the login account, the password and the input face image and judges whether the user is allowed to access the operating system of the handset. Step S111 specifically includes:
Step S111-2: The cloud server determines, according to the login account and the password, the face sample image library of the user corresponding to the login account and the password.
Step S111-4: The cloud server obtains a face feature similarity value (FFSV) according to the input face image and the face sample image library; the face feature similarity value represents the degree of similarity between the input face image and each face sample image, and the smaller the face feature similarity value (FFSV) is, the more similar the input face image and each face sample image are.
Step S111-4 specifically includes:
Step S111-4-1: Through face detection, the cloud server obtains a face region image from the face input image; mainly, the face detection method is comparing the face skin color regions of the input face image and the face sample images, and extracting the face region image based on the proportion of the head shape.
Step S111-4-3: The cloud server calculates a first characteristic value of each face sample image in the face sample image library and a second characteristic value of the face region image.
Step S111-4-5: The cloud server calculates an characteristic distance between the first characteristic value of each face sample image in the face sample image library and the second characteristic value of the face region image, to obtain multiple second characteristic distances, and determines a face feature similarity value (FFSV) according to the multiple second characteristic distances; and the face feature similarity value (FFSV) represents the degree of similarity between the input face image and each face sample image, and the smaller the face feature similarity value is, the more similar the input face image and each face sample image are. The face feature similarity value may be the maximum value among multiple second characteristic distances, or may be an average value of multiple second characteristic distances.
Step S111-6: The cloud server judges whether the face feature similarity value is larger than a preset threshold, wherein the preset threshold is obtained from multiple first characteristic distances between each face sample image in the face sample image library; and the preset threshold may be the maximum value in multiple first characteristic distances, or may be an average value of multiple first characteristic distances.
Step S111-8: If the face feature similarity value is not larger than the preset threshold, that is, the similarity of the user's face image and the face sample images in the face sample image library meets security requirements, the user is allowed to access the operating system of the handset.
Step S111-10: If the face feature similarity value is larger than the preset threshold, that is, the similarity of the user's face image and the face sample images in the face sample image library fails to meet security requirements, the cloud server makes statistics respectively regarding how many face sample images whose first characteristic distance is larger or smaller than the face feature similarity value there are, that is, a first number and a second number, wherein the first number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are larger than the face feature similarity value, and the second number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are not larger than the face feature similarity value; and then, judges whether the first number is larger than the second number.
Step S111-12: If the first number is smaller than the second number, the user is not allowed to access the operating system of the handset.
Step S111-14: If the first number is not smaller than the second number, the user is allowed to access the operating system of the handset.
The following further describes how the embodiment of the present invention extracts the face image features and determines the first characteristic value of each face sample image in the face sample image library, the second characteristic value of the face region image, the first characteristic distances between the face sample images in the face sample image library, the second characteristic distance between each face sample image in the face sample image library and the face region image, the preset threshold and the face feature similarity value.
A face sample image X(x,y) is taken as an example. The face sample image X(x,y) is a 2-dimensional 64×64 grayscale image, where x represents a horizontal coordinate pixel and y represents a vertical ordinate pixel. The face sample image library consists of M face sample images, and may be represented by {Xi|i=1, 2, . . . , M}. The M face sample images are superimposed according to face positions to obtain an average value of all images after the superimposition, that is,




  
    
      X
      _
    
    =
    
      
        1
        M
      
      ⁢
      
        
          ∑
          
            i
            =
            1
          
          M
        
        ⁢
        
          X
          i
        
      
    
  
  ,




The difference between each face sample image Xi and the average value X is: φi=Xi− X(i=1, . . . , M).
A covariance matrix is constructed: C=AAT. Where, A=[φ1, φ2, . . . , φM] is a linear combination of difference vectors. For a 64×64 face image, the size of the covariance matrix C is 4096×4096, and it is difficult to obtain its eigenvalues and eigenvectors directly. According to the singular value decomposition theorem, the eigenvalues and the eigenvectors of C=AAT are obtained by finding the eigenvalues and the eigenvectors of AT A. Assuming λi(i=1, 2, . . . , r) is r nonzero eigenvalues of the matrix AT A, vi and is an eigenvector of AT A corresponding to λi, then the orthogonal normalized eigenvector of C=AAT is




  
    
      u
      i
    
    =
    
      
        1
        
          
            λ
            i
          
        
      
      ⁢
      A
      ⁢
      
        
      
      ⁢
      
        v
        i
      
    
  
  ,




and the eigenvalues corresponding to the sample covariance are arranged in order of magnitude: λ1≧λ2≧ . . . ≧λr. Assuming that the corresponding eigenvector of λi is ui, each face sample image may be projected to an eigenspace U formed by u1, u2, . . . , ur.

In the specific application, the first d eigenvalues may be selected as the eigenspace, and because the dimensions of this eigenspace are lower than the dimensions of the original face sample images, after each face sample image is projected to the eigenspace U formed by u1, u2, . . . , ur, the dimensions of the face sample images are decreased greatly, thus achieving the objective of decreasing dimensions and extracting features. The principle for selection is determined according to the energy proportion of the eigenvalues α, and generally, the value of α is from 95% to 99%.
In order to improve the efficiency and precision of feature extraction, the embodiment of the present invention provides a method for finding the eigenvectors of the face sample images by dividing the face sample images into blocks. A face has three distinguishing features: eyes, nose and mouth, and they are respectively located at upper, middle and lower blocks of the face. Therefore, a face image is divided into three independent sub-blocks according to the three distinguishing features, that is, the upper part includes the eyes, the middle part includes the nose, and the lower part includes the mouth.
Through the block division, a face sample image becomes three sub-images, and thus each face sample image Xi may be denoted as Xi=[Xiu Xim Xib]T (i=1, 2, . . . , M), where Xiu represents an upper sub-block image, Xim represents the middle sub-block image, and Xib represents a lower sub-images.
The original one face sample image library becomes three sub-block image libraries independent of each other, that is, Xiu, Xim and Xib (i=1, 2, . . . , M). If Xi is a matrix of P rows and Q columns, Xiu is a matrix of P1 rows and Q columns, Xim is a matrix of P2 rows and Q columns, and Xib is a matrix of P3 rows and Q columns, where P1+P2+P3=P.
All upper sub-images of the face sample image library constitute an upper sub-block image library, and similarly, the middle and lower sub-images respectively constitute a middle sub-block image library and a lower sub-block image library. In the process of feature extraction, they will be treated as three independent sub-block image libraries.
Considering that the samples in the face sample image library are limited, the embodiment of the present invention provides the following algorithm which can increase the number of samples without sampling, thus improving the precision of feature extraction. The method specifically includes the following steps:
1. For the face sample image X (an m×n matrix), a dual sample X′ is generated, where X′=XY, Y is an n×n matrix in which anti-diagonal elements are 1s and other elements are 0s, that is:




  
    X
    =
    
      [
      
        
          
            
              X
              ⁡
              
                (
                
                  1
                  ,
                  1
                
                )
              
            
          
          
            
              X
              ⁡
              
                (
                
                  1
                  ,
                  2
                
                )
              
            
          
          
            ...
          
          
            
              X
              ⁡
              
                (
                
                  1
                  ,
                  n
                
                )
              
            
          
        
        
          
            ⋮
          
          
            ⋮
          
          
            ⋱
          
          
            ⋮
          
        
        
          
            
              X
              ⁡
              
                (
                
                  m
                  ,
                  1
                
                )
              
            
          
          
            
              X
              ⁡
              
                (
                
                  m
                  ,
                  2
                
                )
              
            
          
          
            ...
          
          
            
              X
              ⁡
              
                (
                
                  m
                  ,
                  n
                
                )
              
            
          
        
      
      ]
    
  
  ,
  
    

  
  ⁢
  
    
      X
      ′
    
    =
    
      [
      
        
          
            
              X
              ⁡
              
                (
                
                  1
                  ,
                  n
                
                )
              
            
          
          
            
              X
              ⁡
              
                (
                
                  1
                  ,
                  
                    n
                    -
                    1
                  
                
                )
              
            
          
          
            ...
          
          
            
              X
              ⁡
              
                (
                
                  1
                  ,
                  1
                
                )
              
            
          
        
        
          
            ⋮
          
          
            ⋮
          
          
            ⋱
          
          
            ⋮
          
        
        
          
            
              X
              ⁡
              
                (
                
                  m
                  ,
                  n
                
                )
              
            
          
          
            
              X
              ⁡
              
                (
                
                  m
                  ,
                  
                    n
                    -
                    1
                  
                
                )
              
            
          
          
            ...
          
          
            
              X
              ⁡
              
                (
                
                  m
                  ,
                  1
                
                )
              
            
          
        
      
      ]
    
  




Where, the matrix Y is symmetric, that is Y=YT; and orthogonal, that is YYT=Y YT=I (I represents a unit matrix).
X is decomposed into a first sample Xe=(X+X′)/2 and a second sample Xo=(X−X′)/2. Therefore, the relationship between the average value of the dual samples X′ and the covariance matrix C′ is as follows:

 X′= XY,C′=YTCY 

The relationship between the average value of the first samples Xe and the covariance matrix Ce is as follows:

 Xe= X(I+Y)/2,Ce=(I+Y)TC(I+Y)/4

The relationship between the average value of the second samples Xo and the covariance matrix Co is as follows:

 Xo= X(I−Y)/2,Co=(I−Y)TC(I−Y)/4

According to mathematical theory, it can be determined that the eigenspace of the first samples Xe and the eigenspace of the second samples Xo are orthogonal, and that the eigenspace of X is a direct sum of the eigenspace of the first samples Xe and the eigenspace of the second samples Xo.
Therefore, the first eigenspace Ue and the second eigenspace Uo may be respectively obtained with respect to Xe and Xo based on the feature extraction algorithm, and then, the eigenvectors with high recognition precision and large variance are selected from the first eigenspace Ue and the second eigenspace Uo to constitute the eigenspace U of X. Then, by using U as a feature transformation matrix, features are extracted through V=AU.
The method according to the embodiment of the present invention is hereinafter described in conjunction with the face sample image library after block division. By taking the upper sub-block image library as an example, a dual sample Xiu′(i=1, 2, . . . , M) is generated for each sample Xiu (i=1, 2, . . . , M) in the upper sub-block image library, where Xiu′=XiuY, Y is a Q×Q matrix in which the anti-diagonal elements are 1s and other elements are 0s, that is:



  
    
      X
      i
      u
    
    =
    
      [
      
        
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  1
                  ,
                  1
                
                )
              
            
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  1
                  ,
                  2
                
                )
              
            
          
          
            ...
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  1
                  ,
                  Q
                
                )
              
            
          
        
        
          
            ⋮
          
          
            ⋮
          
          
            ⋱
          
          
            ⋮
          
        
        
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  
                    P
                    1
                  
                  ,
                  1
                
                )
              
            
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  
                    P
                    1
                  
                  ,
                  2
                
                )
              
            
          
          
            ...
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  
                    P
                    1
                  
                  ,
                  Q
                
                )
              
            
          
        
      
      ]
    
  




  
    
      
        X
        i
        u
      
      ′
    
    =
    
      [
      
        
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  1
                  ,
                  Q
                
                )
              
            
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  1
                  ,
                  
                    Q
                    -
                    1
                  
                
                )
              
            
          
          
            ...
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  1
                  ,
                  1
                
                )
              
            
          
        
        
          
            ⋮
          
          
            ⋮
          
          
            ⋱
          
          
            ⋮
          
        
        
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  
                    P
                    1
                  
                  ,
                  Q
                
                )
              
            
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  P
                  ,
                  
                    Q
                    -
                    1
                  
                
                )
              
            
          
          
            ...
          
          
            
              
                X
                i
                u
              
              ⁡
              
                (
                
                  P
                  ,
                  1
                
                )
              
            
          
        
      
      ]
    
  



Xiu is decomposed into a first sample Xi eu=(Xiu+Xiu′)/2 and a second sample Xi ou=(Xiu−Xiu′)/2.

A first eigenspace Uui,e and a second eigenspace Uui,o are obtained respectively with respect to Xi eu and Xi ou based on the foregoing feature extraction algorithm, and then, the eigenvectors with high recognition precision and large variance are selected from the first eigenspace Uui,e and the second eigenspace Uui,o to constitute an eigenspace Uui; and by using Uui as a feature transformation matrix, the projection of Xiu in the eigenspace Uui, namely Viu, is extracted through Viu=XiuUui.
A feature extraction is performed with respect to each sample Xim and Xib (i=1, 2, . . . , M) in the middle sub-block image library and the lower sub-block image library by using the same method, where the projection of each sample Xim and Xib (i=1, 2, . . . , M) of the middle sub-block image library and the lower sub-block image library in respective eigenspaces is recorded as Vim and Vib.
Assuming that Viu is a ki,1-dimensional vector, for an eigenmatrix




  
    V
    i
    u
  
  =
  
    [
    
      
        
          
            
              t
              i
            
            ⁡
            
              (
              
                1
                ,
                1
              
              )
            
          
        
        
          ...
        
        
          
            
              t
              i
            
            ⁡
            
              (
              
                1
                ,
                
                  k
                  
                    i
                    ,
                    1
                  
                
              
              )
            
          
        
      
      
        
          ⋮
        
        
          ⋱
        
        
          ⋮
        
      
      
        
          
            
              t
              i
            
            ⁡
            
              (
              
                
                  P
                  1
                
                ,
                1
              
              )
            
          
        
        
          ...
        
        
          
            
              t
              i
            
            ⁡
            
              (
              
                
                  P
                  1
                
                ,
                
                  k
                  
                    i
                    ,
                    1
                  
                
              
              )
            
          
        
      
    
    ]
  




of each sample Xiu (i=1, 2, . . . , M) in the upper sub-block image library, a characteristic value Tiu is calculated respectively, that is:





  
    T
    i
    u
  
  =
  
    
      
        
          ∑
          
            
              n
              =
              1
            
            ,
            
              l
              =
              1
            
          
          
            
              P
              1
            
            ,
            
              k
              
                i
                ,
                1
              
            
          
        
        ⁢
        
          
            (
            
              
                t
                i
              
              ⁡
              
                (
                
                  n
                  ,
                  l
                
                )
              
            
            )
          
          2
        
      
    
    .
  




For the eigenspace Vim (a ki,2-dimensional vector) and Vib (a ki,3-dimensional vector) of each sample Xim and Xib (i=1, 2, . . . , M) of the middle sub-block image library and the lower sub-block image library, characteristic values




  
    T
    i
    m
  
  =
  
    
      
        
          
            ∑
            
              
                n
                =
                1
              
              ,
              
                l
                =
                1
              
            
            
              
                P
                2
              
              ,
              
                k
                
                  i
                  ,
                  2
                
              
            
          
          ⁢
          
            
              (
              
                
                  t
                  i
                
                ⁡
                
                  (
                  
                    n
                    ,
                    l
                  
                  )
                
              
              )
            
            2
          
        
      
      ⁢
      
        
      
      ⁢
      and
      ⁢
      
        
      
      ⁢
      
        T
        i
        b
      
    
    =
    
      
        
          ∑
          
            
              n
              =
              1
            
            ,
            
              l
              =
              1
            
          
          
            
              P
              3
            
            ,
            
              k
              
                i
                ,
                3
              
            
          
        
        ⁢
        
          
            (
            
              
                t
                i
              
              ⁡
              
                (
                
                  n
                  ,
                  l
                
                )
              
            
            )
          
          2
        
      
    
  




are calculated respectively.

An average value of the characteristic values Tiu, Tim and Tib of each sample Xiu, Xim and Xib of the upper sub-block image library, the middle sub-block image library and the lower sub-block image library is calculated to obtain the first characteristic value Ti=(Tiu+Tim+Tib)/3 of each face sample Xi in the face sample image library, where (i=1, 2, . . . , M).
Described above is the processing of the face sample image library. Corresponding processing is performed for the input face region image by using the same method, that is, dividing the input face region image into blocks, calculating the corresponding characteristic value of each block respectively, finding the sum of these characteristic values to obtain an average value, and finally obtaining the second characteristic value T of the input face region image.
The embodiment of the present invention provides a method for calculating an characteristic distance, i.e. calculating multiple first characteristic distances between face sample images according to a first characteristic value of each face sample image in the face sample image library. The method specifically includes the following steps:
For face sample images Xi and Xj (i, j=1, 2, . . . , M, where i≠j), the first characteristic distance between the two face sample images is D(Xi, Xj)=√{square root over ((Ti−Tj)2)}, and multiple first characteristic distances between the face sample images are calculated. There are M*(M−1)/2 first characteristic distances in total.
Then, a preset threshold is obtained according to the M*(M−1)/2 first characteristic distances between each face sample image in the face sample image library, where the preset threshold may be the maximum value in the M*(M−1)/2 first characteristic distances, or the average value of the M*(M−1)/2 first characteristic distances.
Similarly, according to the second characteristic value T of the input face region image and the first characteristic value of each face sample image in the face sample image library, multiple second characteristic values D(Xi, X)=√{square root over ((Ti−T)2)} (i=1, 2, . . . , M) may be obtained, and there are M second characteristic distances. Then, a face feature similarity value is determined according to the M second characteristic distances, where the face feature similarity value may be the maximum value of the M second characteristic distances or the average value of the M second characteristic distances.
That is, the step of calculating the first characteristic value of each face sample image in the face sample image library includes:

    
    
        dividing the face sample image Xi into three sub-images, that is, Xiu, Xim and Xib (i=1, 2, . . . , M);
        generating dual samples respectively for Xiu, Xim and Xib;
        decomposing Xiu, Xim and Xib respectively into a first sample Xi eu=(Xiu=Xiu′)/2 and a second sample Xi ou=(Xiu−Xiu′)/2 according to the dual samples;
        constructing a covariance matrix with respect to the first sample and the second sample respectively;
        determining the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the orthogonal normalized eigenvectors of the covariance matrix of the second sample respectively;
        according to the first eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the second eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the second sample, determining the projections of the first sample and the second sample respectively in the first eigenspace and the second eigenspace;
        determining the characteristic values of Xiu, Xim and Xib according to the projections of the first sample and the second sample in the first eigenspace and the second eigenspace; and
        determining the first characteristic value of the face sample image Xi according to the characteristic values of Xiu, Xim and Xib.
    
    


Calculating the second characteristic value of the input face region image includes the steps of:

    
    
        dividing the input face region image into three sub-images;
        generating corresponding dual samples respectively with respect to the three sub-images;
        decomposing the three sub-images into a first sample and a second sample respectively according to the dual samples corresponding to the three sub-images;
        constructing a covariance matrix respectively with respect to the first sample and the second sample of the three sub-images;
        determining the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the orthogonal normalized eigenvectors of the covariance matrix of the second sample respectively;
        according to the eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the second sample, determining the projections of the first sample and the second sample in the eigenspace;
        determining the characteristic values of the three sub-images according to the projections of the first sample and the second sample in the eigenspace; and
        determining the second characteristic value of the input face region image according to the characteristic values of the three sub-images.
    
    


The embodiment of the present invention further includes: if the first number is not smaller than the second number, updating the face sample image library by using the input face image, where the updating policy may be replacing the oldest face sample image, or replacing the face sample image that is most different from the input face image.
In addition, the first characteristic distance of the face sample image library in the cloud server may be recalculated, and according to the first characteristic distance, a new preset threshold may be determined to replace the preset threshold. Thus, a dynamic update of the face sample image library is implemented.
With the method for authenticating the identity of a handset user according to the embodiment of the present invention, the cloud server can bear the load of identity authentication, thus improving the security of the operating system of the handset, enhancing the user's experience and raising the precision of the face authentication.
Embodiment 2
Another embodiment of the present invention further provides a cloud server. As shown in FIG. 2, the cloud server includes:

    
    
        a memory 200, configured to store a face sample image library of a user;
        a receiver 201, configured to receive a login account, a password and an input face image of the user;
        a determining unit 203, configured to determine the face sample image library of the user corresponding to the login account and the password; wherein the face sample image library of the user is stored in the memory 200;
        a unit for determining a face feature similarity value 205, configured to determine a face feature similarity value (FFSV) according to the input face image and the face sample image library; as shown in FIG. 3, the unit for determining a FFSV 205 includes: a unit for obtaining a face region image 205-2, a unit for calculating a characteristic value 205-4 and a unit for calculating a characteristic distance 205-6, wherein:
        the unit for obtaining a face region image 205-2, is configured to obtains a face region image from the input face image through face detection;
        the unit for calculating a characteristic value 205-4, is configured to calculate a first characteristic value of each face sample image in the face sample image library and a second characteristic value of the face region image; and
        the unit for calculating a characteristic distance 205-6, is configured to calculate an characteristic distance between the first characteristic value of each face sample image in the face sample image library and the second characteristic value of the face region image, to obtain multiple second characteristic distances, and determines a face feature similarity value (FFSV) according to the multiple second characteristic distances;
        a first determining unit 207, configured to judge whether the face feature similarity value is larger than a preset threshold, wherein the preset threshold is obtained from multiple first characteristic distances between each face sample image in the face sample image library;
        a first permitting unit 209, configured to allow the user to access the operating system of the handset, if the face feature similarity value is not larger than the preset threshold;
        a second determining unit 211, configured to determine a first number and a second number, where the first number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are larger than the face feature similarity value, and the second number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are not larger than the face feature similarity value, if the face feature similarity value is larger than the preset threshold;
        a refusing unit 213, configured to refuse the user to access the operating system of the handset, if the first number is smaller than the second number, a second permitting unit 215, configured to allowed the user to access the operating system of the handset, if the first number is not smaller than the second number.
    
    


Optionally, the cloud server may further includes: a first updating unit 217, configured to update the face sample image library by using the input face image, if the first number is not smaller than the second number.
Optionally, the cloud server may further includes: a second updating unit 219, configured to recalculate the first characteristic distance of the face sample image library in the cloud server, and according to the first characteristic distance, replace the preset threshold with the new preset threshold.

    
    
        the unit for calculating a characteristic value 205-4 includes:
        a first dividing unit 205-41, configured to divide the face sample image Xi into three sub-images, that is, Xiu, Xim and Xib(i=1, 2, . . . , M);
        a first generating unit 205-43, configured to generate dual samples respectively for Xiu, Xim and Xib;
        a first decomposing unit 205-45, configured to decompose Xiu, Xim and Xib respectively into a first sample Xi eu=(Xiu+Xiu′)/2 and a second sample Xi ou=(Xiu−Xiu′)/2 according to the dual samples;
        a first covariance matrix constructing unit 205-47, configured to construct a covariance matrix with respect to the first sample and the second sample respectively;
        a first eigenvector calculating unit 205-49, configured to determine the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the orthogonal normalized eigenvectors of the covariance matrix of the second sample respectively;
        a first projection calculating unit 205-411, configured to determine the projections of the first sample and the second sample respectively in the first eigenspace and the second eigenspace, according to the first eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the second eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the second sample;
        a first characteristic value calculating unit 205-413, configured to determine the characteristic values of Xiu, Xim and Xib according to the projections of the first sample and the second sample in the first eigenspace and the second eigenspace;
        a second dividing unit 205-415, configured to divide the input face region image into three sub-images;
        a second generating unit 205-417, configured to generate corresponding dual samples respectively with respect to the three sub-images;
        a second decomposing unit 205-419, configured to decompose three sub-images into a first sample and a second sample according to the dual samples corresponding to the three sub-images;
        a second covariance matrix constructing unit 205-421, configured to construct a covariance matrix respectively with respect to the first sample and the second sample of the three sub-images;
        a second eigenvector calculating unit 205-423, configured to determine the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the orthogonal normalized eigenvectors of the covariance matrix of the second sample respectively;
        a second projection calculating unit 205-425, configured to determine the projections of the first sample and the second sample respectively in the eigenspace, according to the first eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the first sample and the second eigenspace formed by the orthogonal normalized eigenvectors of the covariance matrix of the second sample;
        a second characteristic value calculating unit 205-427, configured to determine characteristic values of the three sub-images according to the projections of the first sample and the second sample in the eigenspace, and the characteristic values of the input face region according to the characteristic values of the three sub-images.
    
    


In the embodiment of the present invention, the cloud server can bear the load of identity authentication, thus improving the security of the operating system of the handset, enhancing the user's experience and raising the precision of the face authentication.
Embodiment 3
One embodiment of the present invention further provide a network system as shown in FIG. 4, including a handset 502 and a cloud server 504, wherein the user's handset 502 is connected to the cloud server 504 through a communication network; and the handset is configured to obtain a login account and a password input by the user, judge whether the login account and the password are correct; if the login account or the password is incorrect, allow the user to access the operating system of the handset; if the login account and the password are correct, send the login account and the password to the cloud server, where the login account and the password correspond to a face sample image library of the user stored on the cloud server; acquire an input face image of the user and send the input face image to the cloud server;

    
    
        the cloud server is configured to store a face sample image library corresponding to the user, authenticate the identity of the user according to the login account, the password and the input face image and judge whether the user is allowed to access the operating system of the handset.
    
    


The function specially includes:
Step A. The cloud server determines, according to the login account and the password, the face sample image library of the user corresponding to the login account and the password;
Step B. The cloud server obtains a face feature similarity value (FFSV) according to the face input image and the face sample image library; and the step B especially includes:
B1. Through face detection, the cloud server obtains a face region image from the face input image;
B2. The cloud server calculates a first characteristic value of each face sample image in the face sample image library and a second characteristic value of the face region image
B3. The cloud server calculates an characteristic distance between the first characteristic value of each face sample image in the face sample image library and the second characteristic value of the face region image, to obtain multiple second characteristic distances, and determines a face feature similarity value (FFSV) according to the multiple second characteristic distances;
Step C. The cloud server judges whether the face feature similarity value is larger than a preset threshold, where the preset threshold is obtained from multiple first characteristic distances between each face sample image in the face sample image library;
Step D. If the face feature similarity value is not larger than the preset threshold, that is, the similarity of the user's face image and the face sample images in the face sample image library meets security requirements, the user is allowed to access the operating system of the handset;
Step E. If the face feature similarity value is larger than the preset threshold, that is, the similarity of the user's face image and the face sample images in the face sample image library fails to meet security requirements, the cloud server makes statistics respectively regarding how many face sample images whose first characteristic distance is larger or smaller than the face feature similarity value there are, that is, a first number and a second number, where the first number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are larger than the face feature similarity value, and the second number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are not larger than the face feature similarity value; and then, judges whether the first number is larger than the second number;
Step F. If the first number is smaller than the second number, the user is not allowed to access the operating system of the handset;
Step G. If the first number is not smaller than the second number, the user is allowed to access the operating system of the handset.
The structure of the cloud server can be the one as described in Embodiment 2.
In the embodiment of the present invention, the cloud server can bear the load of identity authentication, thus improving the security of the operating system of the handset, enhancing the user's experience and raising the precision of the face authentication.
Persons of ordinary skill in the art should understand that all or a part of the steps of the method according to the embodiments of the present invention may be implemented by a program instructing relevant hardware. The program may be stored in a computer readable storage medium. When the program is run, the steps of the method according to the embodiments of the present invention are performed. The storage medium may be any medium that is capable of storing program codes, such as a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, and an optical disk.
Finally, it should be noted that the above embodiments are merely provided for describing the technical solutions of the present invention, but not intended to limit the present invention. It should be understood by persons of ordinary skill in the art that although the present invention has been described in detail with reference to the foregoing embodiments, modifications can be made to the technical solutions described in the foregoing embodiments, or equivalent replacements can be made to some technical features in the technical solutions, as long as such modifications or replacements do not cause the essence of corresponding technical solutions to depart from the spirit and scope of the present invention.

## Claims

1. A method for authenticating the identity of a handset user, wherein the handset is connected to a cloud server through a communication network, the cloud server stores a face sample image library corresponding to the user, and the method comprises:
obtaining, by the handset, a login account and a password from the user;
judging, by the handset, whether the login account and the password are correct;
if the login account or the password is incorrect, refusing, by the handset, the user to access an operating system of the handset;
if the login account and the password are correct, sending, by the handset, the login account and the password to the cloud server, wherein the login account and the password correspond to a face sample image library of the user stored on the cloud server;
acquiring, by the handset, an input face image of the user;
sending, by the handset, the input face image to the cloud server;
authenticating, by the cloud server, the identity of the user according to the login account, the password and the input face image;
judging, by the cloud server, whether the user is allowed to access the operating system of the handset;
wherein the step of judging whether the user is allowed to access the operating system of the handset comprises:
step (A) determining, by the cloud server, according to the login account and the password, the face sample image library of the user corresponding to the login account and the password;
step (B) obtaining, by the cloud server, a face feature similarity value, FFSV, according to the input face image and the face sample image library; wherein the face feature similarity value represents the degree of similarity between the input face image and each face sample image in the face sample image library;
step (C) judging, by the cloud server, whether the face feature similarity value is larger than a preset threshold, wherein the preset threshold is obtained according to multiple first characteristic distances between each face sample image in the face sample image library;
step (D) if the face feature similarity value is not larger than the preset threshold, allowing, by the cloud server, the user to access the operating system of the handset;
step (E) if the face feature similarity value is larger than the preset threshold, calculating, by the cloud server, a first number and a second number, wherein the first number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are larger than the face feature similarity value, and the second number is the number of face sample images in the face sample image library corresponding to the first characteristic distances which are not larger than the face feature similarity value; judging, by the cloud server, whether the first number is larger than the second number;
step (F) if the first number is smaller than the second number, refusing the user to access the operating system of the handset;
step (G) if the first number is not smaller than the second number, allowing, by the cloud server, the user to access the operating system of the handset;
and the step of B comprises:
step (B1) obtaining, by the cloud server, a face region image from the input face image;
step (B2) calculating, by the cloud server, a first characteristic value of each face sample image in the face sample image library and a second characteristic value of the face region image;
step (B3) calculating, by the cloud server, a characteristic distance between the first characteristic value of each face sample image in the face sample image library and the second characteristic value of the face region image, to obtain multiple second characteristic distances; determining, by the cloud server, the face feature similarity value, FFSV, according to the multiple second characteristic distances.