>>Made by Joven Soh, DESU-CLUB, MartinZhouuuuu and Waldeinsamkeit-917
A project to assist Hwa Chong in automating their Covid-19 monitoring operations in the canteen
The code written here is to check the social distancing of students and to detect the number of students in the canteen.
To find the code where the students are tracked by the DEEPSORT algorithm, please head over to the branch found here
- Download YOLOv3 weights from here (yolo.h5 model file with tf-1.4.0) , put it into model_data folder.
- cd to School YOLO folder
- Run the code with cmd (Recommended if your computer has a powerful GPU):
pip install -r requirements.txt
python3 Combined_GUI.py
After a while, the video files should be outputted in output_videos folder
You can view the files named detections.mov and minimap.mov
Using Google Colab:
- Remember to make a copy of the file before starting
To do so, go to 'File' (Right under name of the Colab file)
Click on 'Save a copy in Drive' - Put a sample video in /input_videos
- Run it with the instructions given
- Video Path Flag
Input video path here:
Just input the path of the video to be processed here
- Calibration Flag
Do you wish to calibrate the input?(Y/N):
This flag is to check whether user would like to modify the Bird Eyes View Transformation of the image
- Social-Distancing Flag
Do you want to check the social distance (Y/N):
This flag is to check whether user would like to include a visual representation of whether students are socially distanced
2 files, named detections.mov and minimap.mov
This code can only be run on Python 3.7, with the following dependencies:
tensorflow==1.13.2
numpy==1.18.1
opencv_python==4.1.2.30
Keras==2.3.1
scipy==1.4.1
matplotlib==3.1.2
Pillow==7.2.0
scikit_learn==0.23.1
Some baseline code was pulled from QiDian's respository found here
This project was made by:
Soh Wei Kiat
Warren Low
Zhou Chengyang
Xue Yuqing
Copyright 2020 HCIRS ML Division
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.