Copyright | (c) 2013-2023 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Gets the path tracking results of a Amazon Rekognition Video analysis started by StartPersonTracking.
The person path tracking operation is started by a call to
StartPersonTracking
which returns a job identifier (JobId
). When the
operation finishes, Amazon Rekognition Video publishes a completion
status to the Amazon Simple Notification Service topic registered in the
initial call to StartPersonTracking
.
To get the results of the person path tracking operation, first check
that the status value published to the Amazon SNS topic is SUCCEEDED
.
If so, call GetPersonTracking and pass the job identifier (JobId
) from
the initial call to StartPersonTracking
.
GetPersonTracking
returns an array, Persons
, of tracked persons and
the time(s) their paths were tracked in the video.
GetPersonTracking
only returns the default facial attributes
(BoundingBox
, Confidence
, Landmarks
, Pose
, and Quality
). The
other facial attributes listed in the Face
object of the following
response syntax are not returned.
For more information, see FaceDetail in the Amazon Rekognition Developer Guide.
By default, the array is sorted by the time(s) a person's path is
tracked in the video. You can sort by tracked persons by specifying
INDEX
for the SortBy
input parameter.
Use the MaxResults
parameter to limit the number of items returned. If
there are more results than specified in MaxResults
, the value of
NextToken
in the operation response contains a pagination token for
getting the next set of results. To get the next page of results, call
GetPersonTracking
and populate the NextToken
request parameter with
the token value returned from the previous call to GetPersonTracking
.
Synopsis
- data GetPersonTracking = GetPersonTracking' {}
- newGetPersonTracking :: Text -> GetPersonTracking
- getPersonTracking_maxResults :: Lens' GetPersonTracking (Maybe Natural)
- getPersonTracking_nextToken :: Lens' GetPersonTracking (Maybe Text)
- getPersonTracking_sortBy :: Lens' GetPersonTracking (Maybe PersonTrackingSortBy)
- getPersonTracking_jobId :: Lens' GetPersonTracking Text
- data GetPersonTrackingResponse = GetPersonTrackingResponse' {}
- newGetPersonTrackingResponse :: Int -> GetPersonTrackingResponse
- getPersonTrackingResponse_jobStatus :: Lens' GetPersonTrackingResponse (Maybe VideoJobStatus)
- getPersonTrackingResponse_nextToken :: Lens' GetPersonTrackingResponse (Maybe Text)
- getPersonTrackingResponse_persons :: Lens' GetPersonTrackingResponse (Maybe [PersonDetection])
- getPersonTrackingResponse_statusMessage :: Lens' GetPersonTrackingResponse (Maybe Text)
- getPersonTrackingResponse_videoMetadata :: Lens' GetPersonTrackingResponse (Maybe VideoMetadata)
- getPersonTrackingResponse_httpStatus :: Lens' GetPersonTrackingResponse Int
Creating a Request
data GetPersonTracking Source #
See: newGetPersonTracking
smart constructor.
GetPersonTracking' | |
|
Instances
Create a value of GetPersonTracking
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:maxResults:GetPersonTracking'
, getPersonTracking_maxResults
- Maximum number of results to return per paginated call. The largest
value you can specify is 1000. If you specify a value greater than 1000,
a maximum of 1000 results is returned. The default value is 1000.
GetPersonTracking
, getPersonTracking_nextToken
- If the previous response was incomplete (because there are more persons
to retrieve), Amazon Rekognition Video returns a pagination token in the
response. You can use this pagination token to retrieve the next set of
persons.
$sel:sortBy:GetPersonTracking'
, getPersonTracking_sortBy
- Sort to use for elements in the Persons
array. Use TIMESTAMP
to sort
array elements by the time persons are detected. Use INDEX
to sort by
the tracked persons. If you sort by INDEX
, the array elements for each
person are sorted by detection confidence. The default sort is by
TIMESTAMP
.
$sel:jobId:GetPersonTracking'
, getPersonTracking_jobId
- The identifier for a job that tracks persons in a video. You get the
JobId
from a call to StartPersonTracking
.
Request Lenses
getPersonTracking_maxResults :: Lens' GetPersonTracking (Maybe Natural) Source #
Maximum number of results to return per paginated call. The largest value you can specify is 1000. If you specify a value greater than 1000, a maximum of 1000 results is returned. The default value is 1000.
getPersonTracking_nextToken :: Lens' GetPersonTracking (Maybe Text) Source #
If the previous response was incomplete (because there are more persons to retrieve), Amazon Rekognition Video returns a pagination token in the response. You can use this pagination token to retrieve the next set of persons.
getPersonTracking_sortBy :: Lens' GetPersonTracking (Maybe PersonTrackingSortBy) Source #
Sort to use for elements in the Persons
array. Use TIMESTAMP
to sort
array elements by the time persons are detected. Use INDEX
to sort by
the tracked persons. If you sort by INDEX
, the array elements for each
person are sorted by detection confidence. The default sort is by
TIMESTAMP
.
getPersonTracking_jobId :: Lens' GetPersonTracking Text Source #
The identifier for a job that tracks persons in a video. You get the
JobId
from a call to StartPersonTracking
.
Destructuring the Response
data GetPersonTrackingResponse Source #
See: newGetPersonTrackingResponse
smart constructor.
GetPersonTrackingResponse' | |
|
Instances
newGetPersonTrackingResponse Source #
Create a value of GetPersonTrackingResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:jobStatus:GetPersonTrackingResponse'
, getPersonTrackingResponse_jobStatus
- The current status of the person tracking job.
GetPersonTracking
, getPersonTrackingResponse_nextToken
- If the response is truncated, Amazon Rekognition Video returns this
token that you can use in the subsequent request to retrieve the next
set of persons.
$sel:persons:GetPersonTrackingResponse'
, getPersonTrackingResponse_persons
- An array of the persons detected in the video and the time(s) their path
was tracked throughout the video. An array element will exist for each
time a person's path is tracked.
GetPersonTrackingResponse
, getPersonTrackingResponse_statusMessage
- If the job fails, StatusMessage
provides a descriptive error message.
$sel:videoMetadata:GetPersonTrackingResponse'
, getPersonTrackingResponse_videoMetadata
- Information about a video that Amazon Rekognition Video analyzed.
Videometadata
is returned in every page of paginated responses from a
Amazon Rekognition Video operation.
$sel:httpStatus:GetPersonTrackingResponse'
, getPersonTrackingResponse_httpStatus
- The response's http status code.
Response Lenses
getPersonTrackingResponse_jobStatus :: Lens' GetPersonTrackingResponse (Maybe VideoJobStatus) Source #
The current status of the person tracking job.
getPersonTrackingResponse_nextToken :: Lens' GetPersonTrackingResponse (Maybe Text) Source #
If the response is truncated, Amazon Rekognition Video returns this token that you can use in the subsequent request to retrieve the next set of persons.
getPersonTrackingResponse_persons :: Lens' GetPersonTrackingResponse (Maybe [PersonDetection]) Source #
An array of the persons detected in the video and the time(s) their path was tracked throughout the video. An array element will exist for each time a person's path is tracked.
getPersonTrackingResponse_statusMessage :: Lens' GetPersonTrackingResponse (Maybe Text) Source #
If the job fails, StatusMessage
provides a descriptive error message.
getPersonTrackingResponse_videoMetadata :: Lens' GetPersonTrackingResponse (Maybe VideoMetadata) Source #
Information about a video that Amazon Rekognition Video analyzed.
Videometadata
is returned in every page of paginated responses from a
Amazon Rekognition Video operation.
getPersonTrackingResponse_httpStatus :: Lens' GetPersonTrackingResponse Int Source #
The response's http status code.