I am currently working on a small face recognition project using Kairos, and I can't figure out how to use my response data. This is based on the data of the picture i'm sending:
request = Request(url, data=values, headers=headers)
response_body = urlopen(request).read()
print(response_body)
My response is something like this, where I want to use the "confidence" value:
{
"images": [
{
"transaction": {
"status": "success",
"width": 327,
"topLeftX": 512,
"topLeftY": 466,
"gallery_name": "MyGallery",
"subject_id": "XXX",
"confidence": 0.70211,
"quality": -0.06333,
"eyeDistance": 145,
"height": 328
}
}
],
"uploaded_image_url": "https://XXX"
}
How do I extract the value "confidence" from this code?