Computer Vision project to automate the dispense and retrieval of rental equipment for selected ball sports.
Clone the repository via HTTPS:
git clone https://github.com/emberfox205/ballsports-rental.git
Alternatively, if you have SSH installed:
git clone git@github.com:emberfox205/ballsports-rental.git
[Optional] Set up a virtual environment of your choice (e.g. venv, conda, etc.). Make sure the Python version is 3.12.0.
Install dependencies:
pip install -r requirements.txt
In the file check_database.json
, set {"database_init": 0}
.
This repository only offers the web application interface for the ball classification and logo detection models.
To use the application, download the required models here: ballsports-rental-ai
In your local repo, setup a folder named models
.
Move the 2 models into models
.
Rename the ball classification model into model.keras
.
Rename the logo detection model into logo.keras
.
As the application utilizes the device's integrated webcam, you are required to generate an https certificate and key.
Use OpenSSL:
- Windows:
- Linux:
Note
If you follow the usage guide for Windows, the key and certificate should be found in C:\\Users\\USER
.
USER
may differ on your device.
Now you should have a certificate (*.crt
) and private key (*.key
).
In your local repo, setup a folder named certs
.
Move the certificate and key into certs
.
Rename the certificate into certificate.crt
.
Rename the key into private.key
.
While in your local repo, enter into the terminal:
python dashboard.py
Follow either of the addresses following Flask's warning in the terminal.
Upon browser's warning, click 'Advanced', then 'Continue/Proceed to ...'.
Allow for Camera permission if asked.