Simple Object detector app utilizing trained YOLO v3 or YOLO v4 CNN models.
- darknet Github repository
- yolov4_darknet Github repository
- YOLO: Real Time Object detection - The tutorial also explains how supervised learning can be applied for the YOLO architecture to generate a custom trained model with
.weights
(weights of the nodes determined by backward pass),.cfg
(contains network architecture details, hyperparameters, input and output configuration, training settings) and.names
(model classes utilized for training) files.
- Ensure you have a WebCam
pip install -r requirements.txt
Following links can be utilized to download the .weights
files:
Copy those weights in the cfg
folder in this project.
Following steps can be considered in order to retrieve the.cfg
and .names
files:
- Clone both mentioned Github repositories in the Reference section
- In
darknet/cfg
andyolov4_darknet/cfg
you can find the cfg files which you can copy to the cfg folder if not already existing - In
darknet/data
andyolov4_darknet/data
you can find the.names
(list of classes) files, e.g.coco.names
Execute the object detection application utilizing any of the downloaded YOLO weights:
python object_detector_app.py --help
# Object detection with yolov4
python object_detector_app.py --model yolov4-tiny