AI for ANYONE with Azure Percept
Published Apr 27 2022 08:00 AM 2,807 Views
Copper Contributor

Azure Percept is an end-to-end rapid-prototyping solution for deploying AI models on Edge

 

Screen Shot 2022-04-04 at 12.29.53.jpeg

 

Just like any other tech hub, our workplace runs on coffee, but often times when I want to go make a cup of coffee, there is queue at the machine.  Since I tend to have only few mins between meetings or coding sessions to grab coffee, waiting in line is not ideal. 

 

Tricky problem, right?  *My developer brain thinks of a fun project*

I built an office coffee bot with Azure Percept using in-built people detection AI model that can tell me when the coffee machine is unoccupied.  AI + coffee - fun combo, isn’t it?  Now, let’s get to details.

 

Azure Percept CoffeeBot Setup

 

The development kit comes with AI models that include people detection, object classification, etc., and can be easily integrated with Azure services.  

 

Using Azure Percept studio, you can manage your devices and deploy custom models built with Azure Custom Vision.  I decided to deploy the people detection model on Percept for my use case and configured it to continuously stream detection data onto Azure IoT Hub. On IoT hub, you can configure a device to receive these events.

 

Gaya24_0-1650869157719.png

 

Next, I plugged Stream Analytics to IoT Hub to in order to run queries on streaming data. The input of the stream analytics job is set as IoT Hub device I had created earlier.  The output of the job is sent to CosmosDB in this usecase.

 

Gaya24_1-1650869157725.png

 

Gaya24_2-1650869157733.png

Stream Analytics job query counting number of people detected every 3 minutes

 

Gaya24_3-1650869157749.png

 

The data is stored as CosmosDB documents

 

Gaya24_4-1650869157759.png

 

In order to finalise my bot, I setup a Microsoft Teams bot that calls an Azure Function App via HTTP trigger in order to instantly answer whether the coffee machine is free.  

 

This is how the whole setup looks -

Gaya24_5-1650869157768.png

The people counter data in Cosmos DB can also be visualised over a period of time using PowerBI or similar tool to know when people are most at the coffee machine which can lead to other automation possibilities such as - when to stock up coffee beans or to schedule cleaning of machine. 

 

Voila! Coffee mission accomplished

 

Other use cases

 

This is just a fun project in order to demonstrate how Azure Percept comes in handy and it was extremely easy to build this prototype. There are a variety of other use cases where Azure Percept can come in handy such as finding available meeting rooms, stock detection or defect detection in retail and other scenarios where AI is really powerful.

 

If you want to get started on developing AI models on Azure Percept:

Setup Azure Percept 

Overview of AI models 

 

Other use cases where Azure Percept is used 

Retail self checkout 

 

About me

 

Gaya works as Data Engineer and has around 9 years of experience in building data engineering and infrastructure solutions for different companies.

When not drinking coffee, she likes to go cycling, hiking and to other outdoor activities

 

Co-Authors
Version history
Last update:
‎Apr 28 2022 05:28 AM
Updated by: