This document provides step-by-step instructions to set up the Python environment for this project.
Before setting up the project, ensure you have the following installed:
- Python: Version 3.10.11
- pip: Python's package manager (comes pre-installed with Python 3.4+)
You may also want to install a virtual environment tool like venv
or virtualenv
to isolate dependencies.
Clone the project repository to your local machine:
git clone <repository_url>
cd <project_directory>
Create and activate a virtual environment to isolate dependencies.
python3 -m venv .venv
source venv/bin/activate
python -m venv .venv
.venv\Scripts\activate
Install the required Python modules listed in requirements.txt
:
pip install -r requirements.txt
To enable model detection, you need to set up your Roboflow API key. Follow these steps:
- Install
python-dotenv
This package allows you to manage environment variables securely.pip install python-dotenv
- Create an
.env File
This file will store your API key.touch .env
- Add Your API Key & Photos Management Page PIN
Open the.env
file in any text editor and add the following line: Replace<YOUR_API_KEY>
with your actual Roboflow API key. Replace<YOUR_PIN>
with whatever PIN you want.ROBOFLOW_KEY=<YOUR_API_KEY> ADMIN_PASSWORD=<YOUR_PIN>
After completing the installation, you can run the project by executing the appropriate script:
python app.py