Code Monkey home page Code Monkey logo

prabhatap20 / social-distance-detection Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 92.14 MB

Abstract: The paper presents a methodology for social distancing detection using deep learning to evaluate the distance between people to mitigate the impact of this coronavirus pandemic.

Python 97.00% PowerShell 0.04% Shell 0.02% C 1.61% Fortran 0.07% Cython 1.07% Makefile 0.01% MATLAB 0.02% TeX 0.17%
social-distancing-detection covid-19 social-distance-monitoring

social-distance-detection's Introduction

Social-distance-detection

Abstract: The paper presents a methodology for social distancing detection using deep learning to evaluate the distance between people to mitigate the impact of this coronavirus pandemic. The detection tool was developed to alert people to maintain a safe distance with each other by evaluating a video feed. The video frame from the camera was used as input, and the open-source object detection pre-trained model based on the YOLOv3 algorithm was employed for pedestrian detection. Later, the video frame was transformed into top-down view for distance measurement from the 2D plane. The distance between people can be estimated and any noncompliant pair of people in the display will be indicated with a red frame and red line. The proposed method was validated on a pre-recorded video of pedestrians walking on the street. The result shows that the proposed method is able to determine the social distancing measures between multiple people in the video. The developed technique can be further developed as a detection tool in realtime application.

To run this code in your terminal:

  • *Open your terminal
  • Change directory to where you have downloaded this code
  • Install python3 if you have not, if installed already then it's ok!
  • Run python3 -m venv venv to create a virtual environment named venv.
  • Run source venv/bin/activate to activate your environment!
  • Write pip install -r requirements.txt to install the python dependencies related to this project like opencv,numpy,scipy etc.
  • Run the command time python social_distance_detector.py --input pedestrians.mp4 --output output.avi --display 1 to run your social distance detection project

For yolov3.weigths file

https://pjreddie.com/darknet/yolo/

  • run commands on terminal
  • then copy yolov3.weights files
  • copy in yolo-coco files name
  • then run on above commands

After you run the last line of command,a window eill pop up and after execution of the file a output.avi file will be showing up in your directory like this:

Output avi gif

Contacts:

social-distance-detection's People

Contributors

prabhatap20 avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.