GithubHelp home page GithubHelp logo

dasupradyumna / yolov7-deepsort-human-tracking Goto Github PK

View Code? Open in Web Editor NEW
25.0 2.0 10.0 148 KB

A human detector and tracker, written in python, using YOLOv7 for detection and DeepSORT for tracking the detections from YOLO.

License: GNU General Public License v3.0

Python 99.17% Shell 0.83%
deepsort human-tracking yolo yolov7-deepsort computer-vision deep-learning machine-vision neural-networks pytorch

yolov7-deepsort-human-tracking's Introduction

Tracking People using YOLOv7 and DeepSORT

Table of Contents

  1. Overview
  2. Getting Started
  3. Code
  4. External Work

Overview

This repository implements a solution to the problem of tracking moving people in a low-quality video. It uses a state-of-the-art object detector YOLOv7 for detecting people in a frame, and fuses these robust detections with the bounding boxes of previously tracked people using the neural network version of SORT called DeepSORT tracker. The packages for YOLO and DeepSORT algorithms are located under yolo and deepsort folders, where the modules are adapted from the official repositories to fit the scripts here.

Getting Started

The necessary python environment required for working with this repository can be setup using the script setup_conda.sh. This script assumes that the system has a working conda distribution (Miniconda or Anaconda), and accepts one argument which will be used as the name for the newly created environment.
The installed conda environment will have the following major packages:

  1. TensorFlow 2.8.1 (with GPU support)
  2. CUDA 10.2 (with CuDNN 7.6.5)
  3. PyTorch 1.10.1 (with TorchVision 0.11.2)
  4. OpenCV 4.6.0
  5. Matplotib 3.6.3
  6. Pandas 1.5.3

Note (1): The script is not robust, and may fail when conda packages are updated in their respective channels.
Note (2): In case of import errors, it is recommended to have "channel_priority" set to "true" in ".condarc" file, with the channels priority being "pytorch" > "conda-forge" > "defaults", and rerun the setup script.

Code

After setting up the conda environment using the above script, the pipeline can be executed by -

python main.py --input-vid=/path/to/input/video/file --save-path=/path/to/output/video/file

This will read frames from the input video, detect people using a YOLO API, and track people using a DeepSORT API. These APIs can be found in api folder. The frames with people detected and tracked are saved to the specified video file.

Data and Results

Input video, versioned output videos, checkpoints and a README with versioning details can be found here. The checkpoints folder should be downloaded to the project root.

External Work

YOLOv7

Repository - Paper

All the modules related to this network can be found under yolo/, and the weights can be found at checkpoints/yolov7x.pt in the GDrive link. More details can be found in yolo/__init__.py.

DeepSORT

Repository - Paper

All the modules related to this network can be found under deepsort/, and the weights can be found at checkpoints/ReID.pb in the GDrive link. More details can be found in deepsort/__init__.py.

yolov7-deepsort-human-tracking's People

Contributors

dasupradyumna avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

yolov7-deepsort-human-tracking's Issues

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.