An Architecture for Modern Cloud Education and Wildlife Identification

Author by Nathan Lasnoski

A few years ago I got an idea… there were birds on my bird feeder that I didn’t know the name of. There were some times of the year they showed up and others where they didn’t. I wanted to get a better understanding of why certain birds showed up at certain times, where the hot spots were, and what kinds were prevalent. I started recording by hand and used a book but quickly got tired, or was just forgetful. So I thought… what if I could automate this?

Another problem surfaced itself… so many students leaving college or high school are completely unprepared for productive technology life. Neither had adequately prepared them with skills that are relevant and I wanted to think about how students could get exposure to modern cloud architectures with an intuitive learning program.

Then, I thought… what if I could kill two birds with one stone (pun intended). What if I could build a lightweight way to track wildlife (birds, deer, rodents, fox, etc.) and educate at the same time. Perhaps this could even get more interesting and capable… so I set out to build an architecture.

The Starting Architecture

So, I thought the best thing was to combine commodity with commodity and enable something almost anyone could build, but also took some work. Here is the high level:

  • Remote capture platform (iphone, deer cam, etc.)
  • Storage of photos moved, synced, or sent to OneDrive (other platforms supported too)
  • Logic App fires on storage of files in OneDrive
  • Logic App sends data to Microsoft AI for Earth classification
  • Information captured and Azure Function pulls EXIF data from image, especially GPS
  • Image data stored in Cosmos DB for later analysis
  • Notebooks / Power BI used for analysis
  • Prod/NonProd with automated release where possible

Here is another diagram of the same:

Seems simple enough, right?

Logic App Structure

So, I set off to accomplish this project in weekends and spare time. It ultimately looked a lot like this:

Build Plan

  1. Install Visual Studio Code on laptop
  2. Install Python and pre-reqs
  3. Setup an Azure subscription or free trial
  4. Ensure access to Azure subscription targets and login with Visual Studio Code (login to your subscription)
  5. Capture images with an iphone (manual), iphone (motion sensor) or with deer cam. Ensure the settings are on jpg and you are copying them to your target OneDrive account.
  6. Create a OneDrive account to upload the images to (could be something else vs. OneDrive). Capture this login properly.
  7. Build Cosmos DB and configure Logic App to store data
  8. Provision an Azure Storage environment for captured images
  9. Create Azure Function to retrieve data and find GPS coordinates from an image stored in Azure Storage
  10. Build Logic App components + Azure Function to interpret the data and response, leveraging Microsoft’s AI for Earth capabilities
  11. Test runs and analyze (let’s validate your production application against images from your OneDrive).
  12. Create copy of production in NonProd
  13. Validate deployment approach with DevOps into both targets vs manually

And…. we’re off! So, after a few weeks of tinkering all the gotchas were eliminated and we had an initial production environment. With the steps above, you should be able to create your own and succeed at duplicating it for your education environment.

Nathan Lasnoski

Author

Nathan Lasnoski

Chief Technology Officer