Copyright | (c) 2013-2016 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Language | Haskell2010 |
For a given input face ID, searches the specified collection for matching faces. You get a face ID when you add a face to the collection using the IndexFaces
operation. The operation compares the features of the input face with faces in the specified collection.
The operation response returns an array of faces that match, ordered by similarity score with the highest similarity first. More specifically, it is an array of metadata for each face match that is found. Along with the metadata, the response also includes a confidence
value for each face match, indicating the confidence that the specific face matches the input face.
For an example, see example3
.
This operation requires permissions to perform the rekognition:SearchFaces
action.
- searchFaces :: Text -> Text -> SearchFaces
- data SearchFaces
- sfFaceMatchThreshold :: Lens' SearchFaces (Maybe Double)
- sfMaxFaces :: Lens' SearchFaces (Maybe Natural)
- sfCollectionId :: Lens' SearchFaces Text
- sfFaceId :: Lens' SearchFaces Text
- searchFacesResponse :: Int -> SearchFacesResponse
- data SearchFacesResponse
- sfrsFaceMatches :: Lens' SearchFacesResponse [FaceMatch]
- sfrsSearchedFaceId :: Lens' SearchFacesResponse (Maybe Text)
- sfrsResponseStatus :: Lens' SearchFacesResponse Int
Creating a Request
Creates a value of SearchFaces
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
sfFaceMatchThreshold
- Optional value specifying the minimum confidence in the face match to return. For example, don't return any matches where confidence in matches is less than 70%.sfMaxFaces
- Maximum number of faces to return. The API will return the maximum number of faces with the highest confidence in the match.sfCollectionId
- ID of the collection to search.sfFaceId
- ID of a face to find matches for in the collection.
data SearchFaces Source #
See: searchFaces
smart constructor.
Request Lenses
sfFaceMatchThreshold :: Lens' SearchFaces (Maybe Double) Source #
Optional value specifying the minimum confidence in the face match to return. For example, don't return any matches where confidence in matches is less than 70%.
sfMaxFaces :: Lens' SearchFaces (Maybe Natural) Source #
Maximum number of faces to return. The API will return the maximum number of faces with the highest confidence in the match.
sfCollectionId :: Lens' SearchFaces Text Source #
ID of the collection to search.
Destructuring the Response
Creates a value of SearchFacesResponse
with the minimum fields required to make a request.
Use one of the following lenses to modify other fields as desired:
sfrsFaceMatches
- An array of faces that matched the input face, along with the confidence in the match.sfrsSearchedFaceId
- ID of the face that was searched for matches in a collection.sfrsResponseStatus
- -- | The response status code.
data SearchFacesResponse Source #
See: searchFacesResponse
smart constructor.
Response Lenses
sfrsFaceMatches :: Lens' SearchFacesResponse [FaceMatch] Source #
An array of faces that matched the input face, along with the confidence in the match.
sfrsSearchedFaceId :: Lens' SearchFacesResponse (Maybe Text) Source #
ID of the face that was searched for matches in a collection.
sfrsResponseStatus :: Lens' SearchFacesResponse Int Source #
- - | The response status code.