rudy-patel / imageAnalysisSystem

This system is a low-footprint versatile system involving hardware and software developments for recognition of shapes and/or faces through machine learning algorithms.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Build Issues Pull Requests Repo Size License

Image Analysis System

This system is a low-footprint versatile application involving hardware and software components for recognition of shapes and/or faces through machine learning algorithms.

Web interface

Home

After logging in, you will be greeted with the home page. Here, you can see the livestream of your primary camera (if online), any recent events, and also switch classification modes between facial/shape detection!

Home screen

Events

On the events page, you can sort/search your way through any captured events from your cameras!

Events

Cameras

On the cameras page, you can see all of the cameras associated with your account, along with seeing their online/offline status, recognition mode, and when it was last online.

Cameras

Train

On the train page, you can upload your own reference images to retrain the machine learning models to recognize new faces or simply improve the accuracy.

Train

First time setup

Setup the hardware unit by following the instructions here.

Place the AWS config and credentials in the aws file:

On Windows:

  1. Navigate to C:/Users/*Your username*/.aws/
  2. copy the config and credentials files into this directory

On Linux/MacOS:

  1. sudo mkdir ~/.aws
  2. copy the config and credentials files into this directory

This project runs inside a Python virtual environment. To set up your environment, follow these steps:

  1. Navigate to the root directory in terminal
  2. Create a virtual environment using: python3 -m venv env

(Optional) To setup a new AWS instance + account, follow the instructions in AWS Setup.

On Linux/MacOS:

  • Run source env/bin/activate to start the Python virtual environment.
  • export FLASK_APP=server.main.py
  • export DB_PASSWORD=*insert DB_password here*
  • Run deactivate to stop the Python virtual environment.
  • If you need to set an environment variable use: export <variable>=<value>. This is only saved in your current terminal.

On Windows:

  • Run .\env\Scripts\activate to start the Python virtual environment.
  • set FLASK_APP=server.main.py
  • set DB_PASSWORD=*insert DB_password here*
  • Run deactivate to stop the Python virtual environment.
  • If you need to set an environment variable use: set <variable>=<value>. This is only saved in your current terminal.

You have now created the virtual environment in the project directory, continue following the steps to run the server.

Running the server (web interface)

To run the server:

  1. Navigate to the root directory in terminal.
  2. Start the Python virtual environment, following the instructions in First Time Setup.
  3. Install the dependencies by running pip install -r requirements.txt.
  4. Run python3 -m server.main to start the server.

You're all set! The server should now be running on 127.0.0.1:5000.

Running the client (camera unit)

Running the Client over LAN (preferred):

  1. Navigate to the root directory in terminal.
  2. Navigate to the client/ folder and run python client.py <ip_address> <port>. Note that <ip_address> and <port> should be typed out as additional arguments to tell the client the ip/port to connect to.

Additional instructions for running the client/server can be found here.

Running tests

To run tests, in your virtual environment run:

python -m pytest

Project overview

This capstone project also has an associated poster with additional information: overview

Resources

Contributors

Name Email Github
Rudy Patel rutvik@ualberta.ca @rudy-patel
Kaden Dreger kaden@ualberta.ca @kaden-dreger
Jacob Paetsch jpaetsch@ualberta.ca @jpaetsch
Braden Stolte bstolte@ualberta.ca @b-stolte

About

This system is a low-footprint versatile system involving hardware and software developments for recognition of shapes and/or faces through machine learning algorithms.

License:Apache License 2.0


Languages

Language:Python 72.6%Language:HTML 24.3%Language:CSS 2.4%Language:Mako 0.8%