ComeçarComece de graça

Cat detector

Sam has been getting more and more challenging projects as a result of her popularity and success.

The newest request is from the animal control team. They want to receive notifications when an image comes in from the Get It Done application contains a cat. They can find feral cats and go rescue them. They provided her with two images that she can test her system with. One contains a cat, one does not. Both images are referenced in variables image1 and image2 respectively.

Sam has also created the boto3 Rekognition client in the rekog variable.

Help Sam use Rekognition to enable the animal control team to rescue stray cats!

Este exercício faz parte do curso

Introduction to AWS Boto in Python

Ver curso

Exercício interativo prático

Experimente este exercício completando este código de exemplo.

# Use Rekognition client to detect labels
image1_response = rekog.____(
    # Specify the image as an S3Object; Return one label
    ____=image1, MaxLabels=____)

# Print the labels
print(image1_response['Labels'])
Editar e executar o código