Method and apparatus for determining identity identifier of face in face image, and terminal
First Claim
1. A method for determining an identity identifier of a face in a face image, comprising:
- obtaining an original feature vector of a face image, comprising;
tracking locations of the face in different video images to obtain N consecutive frames of face images; and
obtaining the original feature vector from a tth frame of face image of the N frames of face images, wherein 1≤
t<
N;
selecting k candidate vectors from a face image database according to the original feature vector, wherein a vector v* in the face image database comprises components [v·
A,v·
B·
vT], a feature extraction manner for v is the same as that for the original feature vector, A represents a cross-correlation submatrix in a joint Bayesian probability matrix, B represents an autocorrelation submatrix in the joint Bayesian probability matrix, and k is a positive integer;
selecting a matching vector of the original feature vector from the k candidate vectors, wherein the matching vector of the original feature vector is a candidate vector of the k candidate vectors that has a shortest cosine distance from a vector [v1,1], and v1 represents the original feature vector;
determining, according to the matching vector of the original feature vector, an identity identifier that is of the matching vector and that is recorded in the face image database as an identity identifier of a face in the face image;
storing, into a cache database, the matching vector of the original feature vector and the identity identifier that is of the matching vector and that is recorded in the face image database;
obtaining an original feature vector of a (t+1)th frame of face image of the N frames of face images, wherein the (t+1)th frame of face image is a next frame of face image of the tth frame of face image;
selecting a target vector from the cache database according to the original feature vector of the (t+1)th frame of face image, wherein the cache database comprises the matching vector of the original feature vector of the tth frame of face image; and
when a target distance between the original feature vector of the (t+1)th frame of face image and the target vector is less than a preset threshold, determining an identity identifier that is of the target vector and that is recorded in the cache database as an identity identifier of a face in the (t+1)th frame of face image.
1 Assignment
0 Petitions
Accused Products
Abstract
The present invention provides a method and an apparatus for determining an identity identifier of a face in a face image, and a terminal. The method includes: obtaining an original feature vector of a face image; selecting k candidate vectors from a face image database; selecting a matching vector of the original feature vector from the k candidate vectors; and determining, an identity identifier that is of the matching vector. In embodiments of the present invention, a face image database stores a medium-level feature vector formed by means of mutual interaction between a low-level face feature vector and autocorrelation and cross-correlation submatrices in a joint Bayesian probability matrix. The medium-level feature vector includes information about mutual interaction between the face feature vector and the autocorrelation and cross-correlation submatrices in the joint Bayesian probability matrix, so that efficiency and accuracy of facial recognition can be improved.
-
Citations
12 Claims
-
1. A method for determining an identity identifier of a face in a face image, comprising:
-
obtaining an original feature vector of a face image, comprising; tracking locations of the face in different video images to obtain N consecutive frames of face images; and obtaining the original feature vector from a tth frame of face image of the N frames of face images, wherein 1≤
t<
N;selecting k candidate vectors from a face image database according to the original feature vector, wherein a vector v* in the face image database comprises components [v·
A,v·
B·
vT], a feature extraction manner for v is the same as that for the original feature vector, A represents a cross-correlation submatrix in a joint Bayesian probability matrix, B represents an autocorrelation submatrix in the joint Bayesian probability matrix, and k is a positive integer;selecting a matching vector of the original feature vector from the k candidate vectors, wherein the matching vector of the original feature vector is a candidate vector of the k candidate vectors that has a shortest cosine distance from a vector [v1,1], and v1 represents the original feature vector;
determining, according to the matching vector of the original feature vector, an identity identifier that is of the matching vector and that is recorded in the face image database as an identity identifier of a face in the face image;storing, into a cache database, the matching vector of the original feature vector and the identity identifier that is of the matching vector and that is recorded in the face image database; obtaining an original feature vector of a (t+1)th frame of face image of the N frames of face images, wherein the (t+1)th frame of face image is a next frame of face image of the tth frame of face image; selecting a target vector from the cache database according to the original feature vector of the (t+1)th frame of face image, wherein the cache database comprises the matching vector of the original feature vector of the tth frame of face image; and when a target distance between the original feature vector of the (t+1)th frame of face image and the target vector is less than a preset threshold, determining an identity identifier that is of the target vector and that is recorded in the cache database as an identity identifier of a face in the (t+1)th frame of face image. - View Dependent Claims (2, 3, 4, 5)
-
-
6. A method for determining an identity identifier of a face in a face image, comprising:
-
obtaining an original feature vector of a face image; selecting a target vector from a face image database according to a formula s=[v2,1]·
(v*c)T+v2·
B·
v2T, wherein v2 represents the original feature vector, v*c represents a vector in the face image database, v*c comprises components [v·
A,v·
B·
vT], a feature extraction manner for v is the same as that for the original feature vector, A represents a cross-correlation submatrix in a joint Bayesian probability matrix, B represents an autocorrelation submatrix in the joint Bayesian probability matrix, s represents a target distance between v2 and v*c, and the target vector is a vector that is in the face image database and that has a smallest target distance from v2; andwhen a target distance between the original feature vector and the target vector is less than a preset threshold, determining an identity identifier that is of the target vector and that is recorded in the face image database as an identity identifier of a face in the face image.
-
-
7. An apparatus for determining an identity identifier of a face in a face image, comprising:
-
a memory to store instructions; and a processor to execute the instructions to cause the apparatus to; obtain an original feature vector of a face image, comprising track locations of the face in different video images to obtain N consecutive frames of face images, and obtain the original feature vector from a tth frame of face image of the N frames of face images, wherein 1≤
t<
N;select k candidate vectors from a face image database according to the original feature vector, wherein a vector v in the face image database comprises components [v·
A,v·
B·
vT], a feature extraction manner for v is the same as that for the original feature vector, A represents a cross-correlation submatrix in a joint Bayesian probability matrix, B represents an autocorrelation submatrix in the joint Bayesian probability matrix, and k is a positive integer;select a matching vector of the original feature vector from the k candidate vectors, wherein the matching vector of the original feature vector is a candidate vector of the k candidate vectors that has a shortest cosine distance from a vector [v1,1], and v1 represents the original feature vector; determine, according to the matching vector of the original feature vector, an identity identifier that is of the matching vector and that is recorded in the face image database as an identity identifier of a face in the face image; store, into a cache database, the matching vector of the original feature vector and the identity identifier that is of the matching vector and that is recorded in the face image database; obtain an original feature vector of a (t+1)th frame of face image of the N frames of face images, wherein the (t+1)th frame of face image is a next frame of face image of the tth frame of face image; select a target vector from the cache database according to the original feature vector of the (t+1)th frame of face image, wherein the cache database comprises the matching vector of the original feature vector of the tth frame of face image; and when a target distance between the original feature vector of the (t+1)th frame of face image and the target vector is less than a preset threshold, determine an identity identifier that is of the target vector and that is recorded in the cache database as an identity identifier of a face in the (t+1)th frame of face image. - View Dependent Claims (8, 9, 10, 11)
-
-
12. A terminal, comprising:
-
a camera, configured to collect a face image; a processor, configured to obtain an original feature vector v1 of the face image, and generate a vector v′
according to the original feature vector v1, wherein v40 =[v1,v1·
B·
v1T] and B represents an autocorrelation submatrix in a joint Bayesian probability matrix; anda transmitter, configured to send the vector v′
to a server, wherein the vector v40 is used by the server to recognize an identity identifier of a face in the face image.
-
Specification