start_face_detection
async
¶
start_face_detection(
video: Video,
*,
config_overrides: Optional[AsyncRekognitionClientConfig] = None,
client_request_token: Optional[ClientRequestToken] = None,
notification_channel: Optional[NotificationChannel] = None,
face_attributes: Optional[FaceAttributes] = None,
job_tag: Optional[JobTag] = None,
) -> StartFaceDetectionResponse
Starts asynchronous detection of faces in a stored video.
Amazon Rekognition Video can detect faces in a video stored in an Amazon S3 bucket. Use Video to specify the bucket name and the filename of the video. StartFaceDetection returns a job identifier (JobId) that you use to get the results of the operation. When face detection is finished, Amazon Rekognition Video publishes a completion status to the Amazon Simple Notification Service topic that you specify in NotificationChannel. To get the results of the face detection operation, first check that the status value published to the Amazon SNS topic is SUCCEEDED. If so, call GetFaceDetection and pass the job identifier (JobId) from the initial call to StartFaceDetection.
For more information, see Detecting faces in a stored video in the Amazon Rekognition Developer Guide.
Parameters:
-
video(Video) –The video in which you want to detect faces. The video must be stored in an Amazon S3 bucket.
-
client_request_token(Optional[ClientRequestToken], default:None) –Idempotent token used to identify the start request. If you use the same token with multiple
StartFaceDetectionrequests, the sameJobIdis returned. UseClientRequestTokento prevent the same job from being accidently started more than once. -
notification_channel(Optional[NotificationChannel], default:None) –The ARN of the Amazon SNS topic to which you want Amazon Rekognition Video to publish the completion status of the face detection operation. The Amazon SNS topic must have a topic name that begins with AmazonRekognition if you are using the AmazonRekognitionServiceRole permissions policy.
-
face_attributes(Optional[FaceAttributes], default:None) –The face attributes you want returned.
DEFAULT- The following subset of facial attributes are returned: BoundingBox, Confidence, Pose, Quality and Landmarks.ALL- All facial attributes are returned. -
job_tag(Optional[JobTag], default:None) –An identifier you specify that's returned in the completion notification that's published to your Amazon Simple Notification Service topic. For example, you can use
JobTagto group related jobs and identify them in the completion notification.
Raises:
-
AccessDeniedException–You are not authorized to perform the action.
-
IdempotentParameterMismatchException–A
ClientRequestTokeninput parameter was reused with an operation, but at least one of the other input parameters is different from the previous call to the operation. -
InternalServerError–Amazon Rekognition experienced a service issue. Try your call again.
-
InvalidParameterException–Input parameter violated a constraint. Validate your parameter before calling the API operation again.
-
InvalidS3ObjectException–Amazon Rekognition is unable to access the S3 object specified in the request.
-
LimitExceededException–An Amazon Rekognition service limit was exceeded. For example, if you start too many jobs concurrently, subsequent calls to start operations (ex:
StartLabelDetection) will raise aLimitExceededExceptionexception (HTTP status code: 400) until the number of concurrently running jobs is below the Amazon Rekognition service limit. -
ProvisionedThroughputExceededException–The number of requests exceeded your throughput limit. If you want to increase this limit, contact Amazon Rekognition.
-
ThrottlingException–Amazon Rekognition is temporarily unable to process the request. Try your call again.
-
VideoTooLargeException–The file size or duration of the supplied media is too large. The maximum file size is 10GB. The maximum duration is 6 hours.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_rekognition/_services/async_rekognition.py
4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 | |