Skip to content

Person Detection & Recognition

BETA PRODUCT

Be aware that this project is currently in BETA. If you would like to try this service, please contact us at tech@ximilar.com

Identity Detection & Recognition service provides a face and person detection API on the image.

API reference

This is documentation of the Ximilar Identity Detection & Recognition API. The API follows the general rules of Ximilar API as described in Section First steps.

Face Detection endpoint - /v2/face/

This endpoint executes a face detection and it is the main endpoint of entire detection system. You can pass an image in _url, _file or _base64 fields. API endpoint /identity/v2/face gets JSON-formatted body where you need to specify records to process (up to 10).

Parameters:

  • records: A list of real-life photos to find similar products; each record
    • must contain either of _url, _file or _base64 field

curl -H "Content-Type: application/json" -H "authorization: Token __API_TOKEN__" https://api.ximilar.com/identity/v2/face -d '{"records": [ {"_url": "https://bit.ly/2IymQJv" } ] }'

The result has similar json structure:

CLICK TO SHOW JSON RESULT

{
  "records": [
    {
      "_url": "__SOME_URL__",
      "_status": {
        "code": 200,
        "text": "OK"
      },
      "_width": 2736,
      "_height": 3648,
      "_objects": [
        {
          "name": "face",
          "bound_box": [
            2103,
            467,
            2694,
            883
          ],
          "prob": 0.9890862107276917
        },
        {
          "name": "face",
          "bound_box": [
            100,
            100,
            500,
            883
          ],
          "prob": 0.9890862107276917
        }
      ]
    }
  ]
}

Person Detection endpoint - /v2/person/

This endpoint executes a person detection. You can pass an image in _url, _file or _base64 fields. API endpoint /identity/v2/person gets JSON-formatted body where you need to specify records to process (up to 10).

Parameters:

  • records: A list of real-life photos to find similar products; each record
    • must contain either of _url, _file or _base64 field

curl -H "Content-Type: application/json" -H "authorization: Token __API_TOKEN__" https://api.ximilar.com/identity/v2/person -d '{"records": [ {"_url": "https://bit.ly/2IymQJv" } ] }'

The result has similar json structure:

CLICK TO SHOW JSON RESULT

{
  "records": [
    {
      "_url": "__SOME_URL__",
      "_status": {
        "code": 200,
        "text": "OK"
      },
      "_width": 2736,
      "_height": 3648,
      "_objects": [
        {
          "name": "person",
          "bound_box": [
            2103,
            467,
            2694,
            883
          ],
          "prob": 0.9890862107276917
        },
        {
          "name": "person",
          "bound_box": [
            100,
            100,
            500,
            883
          ],
          "prob": 0.9890862107276917
        }
      ]
    }
  ]
}