README.md 1.94 KB
Newer Older
Prieur Maxime's avatar
Prieur Maxime committed
1
# YOLOV3 : Real-time Firearm Detection
Prieur Maxime's avatar
Prieur Maxime committed
2

Prieur Maxime's avatar
Prieur Maxime committed
3
## Summary
Prieur Maxime's avatar
Prieur Maxime committed
4

Prieur Maxime's avatar
Prieur Maxime committed
5
This project aim to study the YOLOV3 architecture, and use it with transfert
Prieur Maxime's avatar
Prieur Maxime committed
6 7
learning to be able to detect a new type of object : firearm. This project could be
usefull to alert the police when an arm robbery take place and a  firearm can be
Prieur Maxime's avatar
Prieur Maxime committed
8 9
detected on a surveillance camera.

Prieur Maxime's avatar
Prieur Maxime committed
10
## Files on the repository
Prieur Maxime's avatar
Prieur Maxime committed
11 12

You can find the keras implementation of the YOLOV3 architecture with the 
Prieur Maxime's avatar
Prieur Maxime committed
13 14
custom weight and anchors obtained by transfer-learning, the dataset with the 
hand made labels, the presentation and a short document explaining the
Prieur Maxime's avatar
Prieur Maxime committed
15
architecture.
Prieur Maxime's avatar
Prieur Maxime committed
16

Prieur Maxime's avatar
Prieur Maxime committed
17 18 19 20 21 22
## Examples of images processed by the trained model
<img src="img1.png" width="300">
<img src="img4.png" width="300">
<img src="img2.png" width="300">
<img src="img3.png" width="300">
<img src="img5.png" width="300">
Prieur Maxime's avatar
Prieur Maxime committed
23 24 25

## User Guide

Prieur Maxime's avatar
Prieur Maxime committed
26
### Packages
Prieur Maxime's avatar
Prieur Maxime committed
27 28 29 30
- Python 3.5.2
- Keras 2.1.5
- tensorflow 1.6.0

Prieur Maxime's avatar
Prieur Maxime committed
31 32 33 34 35 36 37 38 39 40 41
### Hardware
- Can be use either with a CPU or GPU (it is quicker with GPU)

### Steps
- Create your virtual env / conda env
- In the keras folder : 
 <code> python yolo_video.py [OPTIONS...] --image, for image detection mode, OR
python yolo_video.py [video_path] [output_path (optional)]</code>

 - You might have to modify the code to analyse custom video...

Prieur Maxime's avatar
Prieur Maxime committed
42
## Possible improvements
Prieur Maxime's avatar
Prieur Maxime committed
43
- The architecture is only a keras adaptation of the Darknet architecture and using the original with transfer learning might be more efficient.
Prieur Maxime's avatar
Prieur Maxime committed
44 45 46
- A lot of new architecture have been released since YOLOV3 and could provide better results. It would be interesting to train model like CenterNet ResNet-18 or  DSOD300 + VoVNet-27-slim.
- Only a few pictures has been labeled and with not that much diversity on the content. Create a larger dataset would make a more robust model.

Prieur Maxime's avatar
Prieur Maxime committed
47 48 49 50
## Thanks
We would like to thanks the INSA of Rouen and Clément Chatelain our Machine-Learning 
teacher for giving us the time and opportunity to work on a project on our own.

Prieur Maxime's avatar
Prieur Maxime committed
51
## GIT used
Prieur Maxime's avatar
Prieur Maxime committed
52
[Qqwweee git](https://github.com/qqwweee)