ServiceQuotaExceededException - AssociateFaces

1

Hi Team,

In my application,

  1. I index images first when processing, in the next step, I'm using search "Search Users API" using faceIds detected in indexing stage.
  2. If the UserId with the similarFaceThreshold of 99% is detected, we're making "AssociateFaces API" call to associate the FaceId with the matched UserId.
  3. If there is no match for the FaceId, we're creating a new user and associating the faceId to it and storing in the collection.

But, As the AssociateFaces has a limit of 100 faces per user, we're getting the "ServiceQuotaExceededException" if the user appears in more than 100 images.

So what could be the solution here?

Below is the error:

An error occurred during image processing: An error occurred (ServiceQuotaExceededException) when calling the AssociateFaces operation: The maximum limit of faces that can be associated with this user has been reached
asked 9 days ago57 views
1 Answer
6
Accepted Answer

To resolve the "ServiceQuotaExceededException" error you're encountering with the "AssociateFaces" API due to the limit of 100 faces per user, consider the following solutions:

1.Distribute Faces Across Multiple Users: Instead of associating all faces with a single user, distribute the faces across multiple users. Create a new user when the face count for an existing user exceeds the limit of 100 faces. Implement a mechanism to manage the association of faces with users dynamically based on the face count.

2.Implement Face Grouping: Group similar faces together based on facial features or other characteristics. Assign each group of faces to a separate user, ensuring that no user exceeds the limit of 100 faces. Limit Face Indexing:

3.Limit the number of faces indexed per image to avoid exceeding the limit for any individual user. Prioritize faces for indexing based on factors such as image quality or relevance.

4.Use Multiple Face Collections: Instead of storing all faces in a single collection associated with a user, use multiple face collections. Distribute faces across these collections to prevent exceeding the limit for any individual user.

5.Monitor and Manage Quotas: Implement monitoring and alerting to track the number of faces associated with each user. Implement mechanisms to automatically handle quota limits, such as splitting users or creating new users when necessary.

6.Request Quota Increase: If none of the above solutions are feasible, consider requesting a quota increase for the "AssociateFaces" API limit from AWS support. Provide justification for the increase, explaining your use case and why the default limit is insufficient.

Implementing one or a combination of these solutions should help you overcome the quota limitation and prevent the "ServiceQuotaExceededException" error when using the "AssociateFaces" API. Choose the solution(s) that best fit your application's requirements and constraints.

profile picture
answered 9 days ago
  • Thanks for the response Kranthi.

    But additional question is the below one

    For

    1. Distribute Faces Across Multiple Users: Instead of associating all faces with a single user, distribute the faces across multiple users. Create a new user when the face count for an existing user exceeds the limit of 100 faces. Implement a mechanism to manage the association of faces with users dynamically based on the face count.

    Actually, I'm already creating multiple users. But the When the specific user appears in more than 100 images, the faceId will be unique and when we associate that faceId with the UserId, beyond 100, it is throwing this error.

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions