EMBEDDED FACE IDENTIFICATION SYSTEM
An embedded face identification system that receives, from an image capture device, a captured image. A face image is extracted from the captured image. The extracted face image is aligned to a reference face model. A face embedding is generated using a machine learning model and based on the aligned extracted face image. An individual associated with the face embedding is identified based on the generated face embedding and a database of existing face embeddings.
1 . A method comprising:
receiving, from an image capture device, a captured image;
extracting a face image from the captured image;
aligning the extracted face image to a reference face model;
generating, using a machine learning model and based on the aligned extracted face image, a face embedding; and
identifying, based on the generated face embedding and a database of existing face embeddings, an individual associated with the face embedding.
2 . The method of claim 1 , wherein aligning the extracted face image to a reference face model comprises:
identifying a set of landmarks from the extracted face image;
obtaining, from the set of landmarks, a subset of the set of landmarks;
determining, using the subset, the reference face model, and a homogenous transformation, parameters of homogenous transformation; and
applying the homogenous transformation with the determined parameters to each pixel of the extracted face image.
3 . The method of claim 2 , wherein the subset comprises a left eye of the face image, a right eye of the face image, and a middle of a lip of the face image.
4 . The method of claim 1 , wherein generating the face embedding comprises:
inputting, into the machine learning model, the aligned extracted face image to output the face embedding; and
reducing a dimension of the face embedding.
5 . The method of claim 1 , wherein determining, based on the generated face embedding and the database of existing face embeddings, the individual associated with the face embedding comprises:
for each existing face embedding of the database of existing face embeddings, calculating a similarity score between the generated face embedding and a respective existing face embedding; and
comparing the calculated similarity score of between the generated face embedding and the respective existing face embedding to a similarity score threshold value of the respective existing face embedding.
6 . The method of claim 1 , wherein determining, based on the generated face embedding and the database of existing face embeddings, the individual associated with the face embedding comprises:
for each cluster of existing face embeddings within the database of existing face embeddings, obtaining a representative face embedding for a respective cluster of existing face embeddings;
for each representative face embedding, calculating a similarity score between the generated face embedding and the representative face embedding; and
comparing the calculated similarity score of between the generated face embedding and the representative face embedding to a similarity score threshold value of the representative face embedding.
7 . The method of claim 5 , wherein each cluster of existing face embeddings in the database of existing face embeddings corresponding to an individual is assigned a unique similarity threshold value.
8 . The method of claim 1 , wherein the database of existing face embeddings includes an embedding of each user at various orientations.
9 . A non-transitory computer-readable medium comprising instructions that, responsive to execution by a processing device, cause the processing device to perform operations comprising:
receiving, from an image capture device, a captured image;
extracting a face image from the captured image;
aligning the extracted face image to a reference face model;
generating, using a machine learning model and based on the aligned extracted face image, a face embedding; and
identifying, based on the generated face embedding and a database of existing face embeddings, an individual associated with the face embedding.
10 . The non-transitory computer-readable medium of claim 9 , wherein aligning the extracted face image to a reference face model comprises:
identifying a set of landmarks from the extracted face image;
obtaining, from the set of landmarks, a subset of the set of landmarks;
determining, using the subset, the reference face model, and a homogenous transformation, parameters of homogenous transformation; and
applying the homogenous transformation with the determined parameters to each pixel of the extracted face image.
11 . The non-transitory computer-readable medium of claim 10 , wherein the subset comprises a left eye of the face image, a right eye of the face image, and a middle of a lip of the face image.
12 . The non-transitory computer-readable medium of claim 9 , wherein generating the face embedding comprises:
inputting, into the machine learning model, the aligned extracted face image to output the face embedding; and
reducing a dimension of the face embedding.
13 . The non-transitory computer-readable medium of claim 9 , wherein determining, based on the generated face embedding and the database of existing face embeddings, the individual associated with the face embedding comprises:
for each existing face embedding of the database of existing face embeddings, calculating a similarity score between the generated face embedding and a respective existing face embedding; and
comparing the calculated similarity score of between the generated face embedding and the respective existing face embedding to a similarity score threshold value of the respective existing face embedding.
14 . The non-transitory computer-readable medium of claim 9 , wherein determining, based on the generated face embedding and the database of existing face embeddings, the individual associated with the face embedding comprises:
for each cluster of existing face embeddings within the database of existing face embeddings, obtaining a representative face embedding for a respective cluster of existing face embeddings;
for each representative face embedding, calculating a similarity score between the generated face embedding and the representative face embedding; and
comparing the calculated similarity score of between the generated face embedding and the representative face embedding to a similarity score threshold value of the representative face embedding.
15 . The non-transitory computer-readable medium of claim 13 , wherein each cluster of existing face embeddings in the database of existing face embeddings corresponding to an individual is assigned a unique similarity threshold value.
16 . The non-transitory computer-readable medium of claim 9 , wherein the database of existing face embeddings includes an embedding of each user at various orientations.
17 . A system comprising:
an image capture device; and
a processing device coupled to the image capture device, wherein the processing device is to perform operations comprising:
receiving, from the image capture device, a captured image;
extracting a face image from the captured image;
aligning the extracted face image to a reference face model;
generating, using a machine learning model and based on the aligned extracted face image, a face embedding; and
identifying, based on the generated face embedding and a database of existing face embeddings, an individual associated with the face embedding.
18 . The system of claim 17 , wherein aligning the extracted face image to a reference face model comprises:
identifying a set of landmarks from the extracted face image;
obtaining, from the set of landmarks, a subset of the set of landmarks;
determining, using the subset, the reference face model, and a homogenous transformation, parameters of homogenous transformation; and
applying the homogenous transformation with the determined parameters to each pixel of the extracted face image.
19 . The system of claim 17 , wherein generating the face embedding comprises:
inputting, into the machine learning model, the aligned extracted face image to output the face embedding; and
reducing a dimension of the face embedding.
20 . The system of claim 17 , wherein determining, based on the generated face embedding and the database of existing face embeddings, the individual associated with the face embedding comprises:
for each cluster of existing face embeddings within the database of existing face embeddings, obtaining a representative face embedding for a respective cluster of existing face embeddings;
for each representative face embedding, calculating a similarity score between the generated face embedding and the representative face embedding; and
comparing the calculated similarity score of between the generated face embedding and the representative face embedding to a similarity score threshold value of the representative face embedding.