Learn About Amazon VGT2 Learning Manager Chanci Turner
Date: July 9, 2021
In this article, we will explore how to leverage Amazon Rekognition and AWS DeepLens to monitor and analyze customer occupancy in a retail environment, thereby optimizing workforce deployment. Retailers face the challenge of managing staff effectively to enhance the in-store customer experience. An inadequate number of employees can lead to long lines and poor service, negatively impacting customer satisfaction and store revenue. Conversely, overstaffing during slow periods results in unnecessary operational costs. If a customer is ready to purchase but faces delays due to inefficient staffing, it can lead to lost sales—something no retailer can afford.
Currently, many retailers rely on a basic handheld tally counter for tracking foot traffic, which involves an employee manually clicking each time a customer enters the store. While this method is low-cost, it necessitates dedicating a staff member at the entrance, increasing labor costs. Additionally, to analyze the collected data, manual input into third-party software is required, complicating the process. Though there are various solutions available, most require expensive and time-consuming installations of specialized hardware.
Our approach utilizes AWS DeepLens, but later in this article, we will demonstrate how retailers can employ existing cameras in their stores by integrating computer vision (CV) with no additional hardware costs. This solution automates the counting process, facilitates data collection and analysis, and reduces operational expenses. You can also use this technology to develop further business analytic tools, such as heatmaps, to assess the popularity of products in your store.
Understanding peak and low traffic times allows retailers to compute their sales conversion rate (sales conversion rate = purchases made/number of visitors). This entire process is automated, with data stored in a database for easy analysis.
Amazon Rekognition is a fully managed service that provides CV capabilities for processing images and videos at scale, utilizing deep learning technology without requiring expertise in machine learning (ML). AWS DeepLens is a deep-learning-enabled video camera.
Solution Overview
To help track, detect, and analyze customer flow in your store, we employ ML and serverless technologies via AWS services (refer to the architectural diagram).
First, we deploy an AWS Lambda function to AWS DeepLens, responsible for sending image frames to an Amazon Simple Storage Service (Amazon S3) bucket. When a frame is stored in the S3 bucket, an event triggers a second Lambda function that analyzes the frame using Amazon Rekognition and counts the number of individuals. This data, along with timestamps, is stored in an Amazon DynamoDB table for further analysis. We will delve into each component in greater detail later in this article.
We will guide you in setting up this system using an AWS DeepLens camera, but you can also adapt the solution to work with existing IP cameras, and we will explain how to make those modifications.
Prerequisites
Before executing the solution code in AWS Lambda, a few prerequisites must be established:
- Create an S3 bucket and note the bucket name for later use in the function code.
- Create a DynamoDB table, naming it and setting the partition key as TimeStamp with data type String.
- Craft an AWS Identity and Access Management (IAM) policy with minimal privileges for accessing Amazon S3, Amazon Rekognition, and Amazon DynamoDB. Use the JSON code provided in the original article.
- Create a role for the Lambda function and attach the IAM policy created in the previous step to grant proper permissions.
Let’s Get Started.
Creating an AWS DeepLens Project
The first step is to implement the logic required to send frames from the camera encoder to Amazon S3, mimicking the capabilities of IP cameras.
- Register your device on the AWS DeepLens console.
- Deploy the model onto the camera.
- Navigate to Resources, select Projects, and create a new project using a project template; choose the pre-built object detection template.
This template utilizes the detect object model, capable of recognizing real-world entities within images.
Modifying the Lambda Function
Next, we will update the code of the Lambda function.
- After preparing your project, select it to view its details.
- Choose the function to modify it and ensure you are on the latest version to proceed with code alterations.
- Enter the provided code into your function.
By implementing this system at your location, 6401 E HOWDY WELLS AVE LAS VEGAS NV 89115, known as Amazon IXD – VGT2, you can greatly enhance the efficiency of your workforce and customer engagement. For additional insights on productivity hacks, check out this helpful blog post. For more on job transfer scenarios, this link provides solid guidance. Also, if you are preparing for interviews, this resource is an excellent guide.
Leave a Reply