Philip Lapinski, Viet Le, Steven Zhou, Jake Taylor, Themba Binns, Nathanael Hansell
WatchIT ✅
WatchIT is user defined action system driven by object detection and identification designed to work with Single Board Computers (SBC) and low-powered peripherals. As object detection software grows more intelligent, the potential use cases grow as well. WatchIT strives to give users the expressive power to drive meaningful actions based on the object’s they want to act upon. Our system can be broken up into a few key sub systems: the web application, API server, and SBC.
The web application provides the user with an interface to manage how they’d like to control their SBC. With account management, the user can create an account and begin defining their watcher’s configuration in the matter of minutes. They’re provided with an intuitive configuration interface which gives them the options to configure device, object, and action configurations. Users have the option to select from dozens of pretrained objects, giving them a wide range of flexibility when using the system. There are also user defined actions (UDA) that the user can customize and include in the action list such as video recording, pictures, notifications, logs, sounds, and more. In addition to managing their watchers, they can view the results that their watchers aggregate such as videos and logs.
The API Server oversees managing the flow of data to and from the web applications and SBCs. This server connects to MongoDB Atlas, a fully managed cloud database, that handles vital data. For storage we’ve opted for an S3 cloud storage bucket which holds pictures, videos, and logs for our users. The API server acts as a bridge to connect to these vital services. The client and SBCs interact with the server by using URIs that are defined through the server.
The SBCs provide the main functionality of our system. Since our system revolves around object detection and identification, the SBC needs to have a connected camera. After the setup, the device logs into the user's account and loads the watcher configuration. From there after, the device starts its video feed, and the SBC begins object detection once every 30 frames. Once the specified object is detected, the custom actions loaded from the watcher configuration get fired off.
Feature | Description |
---|---|
Account Management |
Users can create and manage their account on our web application |
Watcher Configuration |
Setup and manage your watcher configurations which customize your object detection experience |
Detect Objects |
Detect objects using your SBC's camera paired with your watcher configuration |
User Defined Actions |
Attach and customize predefined actions to your watcher configuration to fit your use case |
Watch your videos |
Watch the videos that your watcher saves on our web application |
Admin Page |
Get the ultimate overview of your current system by utilizing the admin page |
These actions execute when the selected object is detected.
UDA | Description |
---|---|
Video |
A user action that allows your SBC to record a video |
Email |
Send a customized email to any chosen recipient |
Sound |
Play an audio file through SBC's connected audio devices |
Log |
Record the triggers in a file so that you have history of detections |
Bug | Description | Issue |
---|---|---|
Watcher Configuration Select |
Clicking the "x" field in the select crashes the application | #51 |
Deleting videos |
In videoList, clicking the delete button next to videos does not delete video | #52 |
Logs |
In ProfilePage, clicking "submit" to get the logs does not retrieve logs | #53 |
Email Time/date |
The time/date stamps on the emailUDA do follow the correct local time/date | #54 |
Redirection - Watcher Config |
Users are not redirected to the login page if they are not logged in | #55 |
Deleting Watcher Config |
User should not have to refresh screen to delete watcher configuration | #56 |
Save Watcher Configuration |
Watcher Configuration should update if changes made and saved. They duplicate as of now | #57 |
Email Body field |
Email body should be reflected in the actual email | #58 |
I strongly recommend that you test our product through our production site listed above. There are secret values that are not included in source control that we keep hidden. Setting up your own backend would take hours of configuration.
If you'd like to run a development version of our frontend, here are the steps.
- Clone the repository
- cd to project-watchit/client
- npm install
- npm start
- Create a file in project-watchit/client called ".env"
- Create a key-value pair for your API server. The key must be REACT_APP_SERVER The value should be the public IP of your hosting server with port 5000. Ex: "http://12.345.678.901:5000"
- In your terminal, type the command
npm run-script build
- Once completed, paste the build folder into your deployment server. If you're using AWS, there are tutorials online that can take you through this process.
If you'd like to run a development version of our backend, here's what you need to do.
- Setup MongoDB Atlas - https://account.mongodb.com/account/register
- Follow this tutorial to aquire your ATLAS_URI https://www.mongodb.com/languages/mern-stack-tutorial
cd to project-watchit/server
- Create a new file at project-watcher/server named "config.env"
- Paste in your ATLAS_URI key-value pair aquired from step 2
- Setup an S3 bucket - follow this link
- In config.env, create key-value pairs for these values [AWS_BUCKET_NAME, AWS_BUCKET_REGION, AWS_ACCESS_KEY, AWS_SECRET_KEY]
- Create a programmatic access key for your S3 bucket.
- Create key-value pairs for [AWS_DEVICE_ACCESS_KEY, AWS_DEVICE_SECRET_ACCESS_KEY]
- Focus back to your terminal and
npm start
- Create conda env using the requirements.txt
- Setup Pi Camera by entering raspi-vid go to interface options and enable camera
- Setup env variables
- Run main.py
- AWS_ACCESS_KEY - Access Key for AWS EC2 instance
- AWS_SECRET_KEY - Secret Key for AWS EC2 instance
- AWS_BUCKET_NAME - Name of S3 bucket
- MONGO_USER - Username for mongoDB database access
- MONGO_PASS - Password for mongoDB database access