Continuing the previous #ArtificialIntelligence theme. Wanted to see what and how does Amazon’s rekognition work and different from the #AI offerings from the others, such as Microsoft.

Here is a #ProjectMurphy image’s confidence score. I am glad to see that there is a 99% confidence that this is a person.

Object and Scene detection

The request POST is quite simple:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
{
 "method": "POST",
 "path": "/",
 "region": "us-west-2",
 "headers": {
 "Content-Type": "application/x-amz-json-1.1",
 "X-Amz-Date": "Thu, 01 Dec 2016 22:21:01 GMT",
 "X-Amz-Target": "com.amazonaws.rekognitionservice.RekognitionService.DetectLabels"
 },
 "contentString": {
 "Attributes": [
 "ALL"
 ],
 "Image": {
 "Bytes": "..."
 }
 }
 }

And so is the response:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
{
 "Labels": [
 {
 "Confidence": 99.2780990600586,
 "Name": "People"
 },
 {
 "Confidence": 99.2780990600586,
 "Name": "Person"
 },
 {
 "Confidence": 99.27307891845703,
 "Name": "Human"
 },
 {
 "Confidence": 73.7669448852539,
 "Name": "Flyer"
 },
 {
 "Confidence": 73.7669448852539,
 "Name": "Poster"
 },
 {
 "Confidence": 68.23612213134765,
 "Name": "Art"
 },
 {
 "Confidence": 58.291263580322266,
 "Name": "Brochure"
 },
 {
 "Confidence": 55.91957092285156,
 "Name": "Modern Art"
 },
 {
 "Confidence": 53.9996223449707,
 "Name": "Blossom"
 },
 {
 "Confidence": 53.9996223449707,
 "Name": "Flora"
 },
 {
 "Confidence": 53.9996223449707,
 "Name": "Flower"
 },
 {
 "Confidence": 53.9996223449707,
 "Name": "Petal"
 },
 {
 "Confidence": 53.9996223449707,
 "Name": "Plant"
 },
 {
 "Confidence": 50.69965744018555,
 "Name": "Face"
 },
 {
 "Confidence": 50.69965744018555,
 "Name": "Selfie"
 }
 ]
}

Here is what the facial analysis shows;

Facial Analysis
Facial Analysis

However how does it handle something a little more complex perhaps?

Object and Scene detection
Object and Scene detection

And finally, what of the comparison? I think there might be some more work to be done on that front.

Face Comparison capture
Face Comparison capture

Here is the response:

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
{
 "FaceMatches": [
 {
 "Face": {
 "BoundingBox": {
 "Height": 0.3878205120563507,
 "Left": 0.2371794879436493,
 "Top": 0.22435897588729858,
 "Width": 0.3878205120563507
 },
 "Confidence": 99.79533386230469
 },
 "Similarity": 0
 }
 ],
 "SourceImageFace": {
 "BoundingBox": {
 "Height": 0.209781214594841,
 "Left": 0.4188888967037201,
 "Top": 0.13127413392066955,
 "Width": 0.18111111223697662
 },
 "Confidence": 99.99442291259765
 }
}