Open martinheidegger opened 2 years ago
@martinheidegger for KYC and identification purposes we do not have situations where there is more than one face in the image. Neither ID nor a selfie should contain more than one face. Due to that, I think the interface can be simplified. Didn't I suggest in the past what the interface could be like, in view of the need for 1:1 and 1:N matching?
The matching itself is 1:1 matching - match_faces(self, face_1_features, face_2_features)
) - and 1:N matching - find_face(self, features)
.
The input images may contain multiple faces or no faces. If the API were to return error cases like NO_FACE_FOUND
, or TOO_MANY_FACES_FOUND
it would complicate the API but also make it less flexible. By providing the list of all faces in an image a user interface could show which images are found and maybe help debug if something that wasn't supposed to be a face be treated as a face.
Hello @fyr91 - what do you think about this as a Python high-level API:
I imagine this API could allows to get the embedding/features for the images based on input images, it would allow a two-step process where the embedding can be created and matched as well as put into a bigger matching database.
Part of the API design was thought to also have easy means to put a CLI, HTTP or other interface on top of it.
Do you think this could hold up? Is this a good idea?