- Clone the repository.
- Navigate to Open-Detection-API directory.
- Install Anaconda Navigator and run the following commands in Anaconda Prompt.
# Tensorflow CPU (If you don't have GPU)
conda env create -f conda-cpu.yml
conda activate yolov3-cpu
# TensorFlow CPU
pip install -r requirements.txt
If you have a GPU, run the following commands
# Tensorflow GPU
conda env create -f conda-gpu.yml
conda activate yolov3-gpu
# TensorFlow GPU
pip install -r requirements-gpu.txt
For Linux: Let's download official yolov3 weights pretrained on COCO dataset.
# yolov3
wget https://pjreddie.com/media/files/yolov3.weights -O weights/yolov3.weights
# yolov3-tiny
wget https://pjreddie.com/media/files/yolov3-tiny.weights -O weights/yolov3-tiny.weights
For Windows:
You can download the yolov3 weights by clicking here and yolov3-tiny here then save them to the weights folder.
Learn How To Train Custom YOLOV3 Weights Here: https://www.youtube.com/watch?v=zJDUhGL26iU Add your custom weights file to weights folder and your custom .names file into data/labels folder.
Load the weights using load_weights.py
script. This will convert the yolov3 weights into TensorFlow .ckpt model files!
# yolov3
python load_weights.py
# yolov3-tiny
python load_weights.py --weights ./weights/yolov3-tiny.weights --output ./weights/yolov3-tiny.tf --tiny
After executing one of the above lines, you should see .tf files in your weights folder.
- Running the Flask App
Initialize and run the Flask app on port 5000 of your local machine by running the following command from the root directory of this repo in a command prompt or shell.
python app.py
Navigate back to the repo and run the following command
python frontend/app.py
Boom! You are ready to go!
- Tensorflow
- OpenCV
- gTTS
- Flask
Live Working Demo : Click Me