One of the biggest concerns related to FR solutions is privacy and storage of PII information. These are valid concerns, and to minimise them, we should only be storing images captured for FR when necessary and delete them when they’re no longer needed.
To ensure that’s the case, an additional function in AWS Lambda can be built to purge historical FR images. This includes defining a PASS comparison rate threshold (e.g. 90%), a PASS and a FAIL image cache periods (e.g. 3 days and 28 days, respectively). The reason why you might set the FAIL image cache period larger than the PASS image cache period is to allow for more time to potentially analyse and deal with failed scenarios. If that’s not a requirement in your app, then both the PASS and FAIL image cache periods can be the same.
The Lambda function then runs on a daily basis, iterates through the records in the Amazon RDS table and runs the following rules:
- If the comparison rate is above the defined PASS threshold and the PASS image cache period has passed, then access the corresponding image in S3 and delete it.
- If the comparison rate is below the defined PASS threshold and the FAIL image cache period has passed, then access the corresponding image in S3 and delete it.