Identify face

This method is available on following paths:
  • POST /v1/identify/
  • POST /v1/faces/gallery/{gallery}/identify/

This method searches through the face dataset. The method returns at most n faces (one by default), which are the most similar to the specified face, and the similarity confidence is above the specified threshold.

Parameters

Parameter Description Type Accepted in
photo

Url of the photo or the photo itself as multipart upload

Example:
http://static.findface.pro/sample.jpg
url file json body multipart query
mf_selector

Specifies behavior in case if multiple faces are detected on the photo; one of:

  • reject return an error and a list of faces if more than one face is detected on the provided photo
  • biggestdefault search using the biggest face on the photo
  • all search for each face found on the photo.

Example:
all
string json body multipart query
bbox

[optional]: array of bounding boxes specifying faces coordinates on the photo.

Note that bbox only accepts rectangles returned by /detect/ method. Arbitrary values are not supported.

Examples:
[[225, 345, 307, 428]]
[{"x1": 225,"y1": 345,"x2": 307,"y2": 428}]
bboxes.lists bboxes.dicts json body multipart query
threshold

[optional]: one of "strict", "medium", "low" [default], "none" or a value between 0 and 1

Example:
0.75
float json body multipart query
n

[optional]: maximum number of most similar faces to return, 1 by default

Example:
10
int json body multipart query

Responses

Status code Description
200

List of faces found on photo

Example:
{
  "results": {
    "[610, 157, 796, 342]": [
      {
        "confidence": 1,
        "face": {
          "galleries": [
            "default",
            "ppl"
          ],
          "id": 2333,
          "meta": "Sam Berry",
          "photo": "http://static.findface.pro/sample.jpg",
          "photo_hash": "dc7ac54590729669ca869a18d92cd05e",
          "thumbnail": "https://static.findface.pro/57726179d6946f02f3763824/dc7ac54590729669ca869a18d92cd05e_thumb.jpg",
          "timestamp": "2016-06-13T11:06:42.075754",
          "x1": 225,
          "x2": 307,
          "y1": 345,
          "y2": 428
        }
      }
    ]
  }
}