amazonka-rekognition-1.4.5: Amazon Rekognition SDK.

Copyright(c) 2013-2016 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone
LanguageHaskell2010

Network.AWS.Rekognition.SearchFaces

Contents

Description

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.

Synopsis

Creating a Request

searchFaces #

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 #

See: searchFaces smart constructor.

Instances

Eq SearchFaces # 
Data SearchFaces # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SearchFaces -> c SearchFaces #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SearchFaces #

toConstr :: SearchFaces -> Constr #

dataTypeOf :: SearchFaces -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c SearchFaces) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SearchFaces) #

gmapT :: (forall b. Data b => b -> b) -> SearchFaces -> SearchFaces #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SearchFaces -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SearchFaces -> r #

gmapQ :: (forall d. Data d => d -> u) -> SearchFaces -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SearchFaces -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SearchFaces -> m SearchFaces #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SearchFaces -> m SearchFaces #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SearchFaces -> m SearchFaces #

Read SearchFaces # 
Show SearchFaces # 
Generic SearchFaces # 

Associated Types

type Rep SearchFaces :: * -> * #

Hashable SearchFaces # 
ToJSON SearchFaces # 
NFData SearchFaces # 

Methods

rnf :: SearchFaces -> () #

AWSRequest SearchFaces # 
ToQuery SearchFaces # 
ToPath SearchFaces # 
ToHeaders SearchFaces # 

Methods

toHeaders :: SearchFaces -> [Header] #

type Rep SearchFaces # 
type Rep SearchFaces = D1 (MetaData "SearchFaces" "Network.AWS.Rekognition.SearchFaces" "amazonka-rekognition-1.4.5-7kQQXfpD3s0BAUEtxNCePO" False) (C1 (MetaCons "SearchFaces'" PrefixI True) ((:*:) ((:*:) (S1 (MetaSel (Just Symbol "_sfFaceMatchThreshold") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Double))) (S1 (MetaSel (Just Symbol "_sfMaxFaces") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Nat)))) ((:*:) (S1 (MetaSel (Just Symbol "_sfCollectionId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)) (S1 (MetaSel (Just Symbol "_sfFaceId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 Text)))))
type Rs SearchFaces # 

Request Lenses

sfFaceMatchThreshold :: Lens' SearchFaces (Maybe Double) #

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) #

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 #

ID of the collection to search.

sfFaceId :: Lens' SearchFaces Text #

ID of a face to find matches for in the collection.

Destructuring the Response

searchFacesResponse #

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:

data SearchFacesResponse #

See: searchFacesResponse smart constructor.

Instances

Eq SearchFacesResponse # 
Data SearchFacesResponse # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SearchFacesResponse -> c SearchFacesResponse #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SearchFacesResponse #

toConstr :: SearchFacesResponse -> Constr #

dataTypeOf :: SearchFacesResponse -> DataType #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c SearchFacesResponse) #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SearchFacesResponse) #

gmapT :: (forall b. Data b => b -> b) -> SearchFacesResponse -> SearchFacesResponse #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SearchFacesResponse -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SearchFacesResponse -> r #

gmapQ :: (forall d. Data d => d -> u) -> SearchFacesResponse -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> SearchFacesResponse -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> SearchFacesResponse -> m SearchFacesResponse #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SearchFacesResponse -> m SearchFacesResponse #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SearchFacesResponse -> m SearchFacesResponse #

Read SearchFacesResponse # 
Show SearchFacesResponse # 
Generic SearchFacesResponse # 
NFData SearchFacesResponse # 

Methods

rnf :: SearchFacesResponse -> () #

type Rep SearchFacesResponse # 
type Rep SearchFacesResponse = D1 (MetaData "SearchFacesResponse" "Network.AWS.Rekognition.SearchFaces" "amazonka-rekognition-1.4.5-7kQQXfpD3s0BAUEtxNCePO" False) (C1 (MetaCons "SearchFacesResponse'" PrefixI True) ((:*:) (S1 (MetaSel (Just Symbol "_sfrsFaceMatches") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe [FaceMatch]))) ((:*:) (S1 (MetaSel (Just Symbol "_sfrsSearchedFaceId") NoSourceUnpackedness SourceStrict DecidedStrict) (Rec0 (Maybe Text))) (S1 (MetaSel (Just Symbol "_sfrsResponseStatus") NoSourceUnpackedness SourceStrict DecidedUnpack) (Rec0 Int)))))

Response Lenses

sfrsFaceMatches :: Lens' SearchFacesResponse [FaceMatch] #

An array of faces that matched the input face, along with the confidence in the match.

sfrsSearchedFaceId :: Lens' SearchFacesResponse (Maybe Text) #

ID of the face that was searched for matches in a collection.

sfrsResponseStatus :: Lens' SearchFacesResponse Int #

  • - | The response status code.