Giter Club home page Giter Club logo

yolo8-tracking-counting-speed_estimation's Introduction

Yolo8 multi-object, segmentation and pose tracking - counting - speed estimation


Repository Description

This repository is a derivative of the mikel-brostrom/yolo_tracking by mikel-brostrom. It builds upon their work and incorporates additional features and modifications specific to this project.

Introduction

This repository contains a highly configurable two-stage-tracker that adjusts to different deployment scenarios. It can jointly perform multiple object tracking and instance segmentation (MOTS). The detections generated by YOLOv8, a family of object detection architectures and models pretrained on the COCO dataset, are passed to the tracker of your choice. Supported ones at the moment are: DeepOCSORT LightMBN, BoTSORT LightMBN, StrongSORT LightMBN, OCSORT and ByteTrack. They can track any object that your Yolov8 model was trained to detect.

Installation

Install with pip:

git clone https://github.com/trinhtuanvubk/yolo8-tracking-counting-speed_estimation.git
cd yolo8-tracking-counting-speed_estimation
pip install -r requirements.txt  # install dependencies

Install with Docker:

git clone https://github.com/trinhtuanvubk/yolo8-tracking-counting-speed_estimation.git
cd yolov8-tracking-counting-speed_estimation
docker build -t <image-tag-name> .
docker run --restart always -itd -v $(pwd):/yolo8-tracking-counting-speed_estimation --name <container-name> -w/yolo8-tracking-counting-speed_estimation <image-tag-name>

If you get errors raised by opencv and ffmpeg, you can pull this image:

git clone https://github.com/trinhtuanvubk/yolo8-tracking-counting-speed_estimation.git
cd yolov8-tracking-counting-speed_estimation
docker pull trinhtuanvubk/vutt-yolo8-opencv
docker run --restart always -itd -v $(pwd):/yolo8-tracking --name <container-name> -w/yolov8-tracking-counting-speed_estimation trinhtuanvubk/vutt-yolo8-opencv:tracking

Tracking, Counting, Speed Estimation

-To run:

$ python3 main.py --scenario track \
--yolo-model weights/yolov8n.pt \
--tracking-method bytetrack \
--speed-method transform_3d \
--source test_data/test1.mp4 \
--classes 0 1 2 3 5 6 7 \
--name test1_line \
--save \
--save-txt \
  • Flag:
    • --scenario: select method(track, eval, evolve). Just support track now
    • --yolo-model: select model (yolov8n, yolo_nas_n, yolox_n, yolov8n-seg, yolov8n-pose) or other yolo models.
    • --tracking-method: select tracking method (bytetrack, deepocsort, strongsort, ocsort, botsort )
    • --speed-method: select speed estimation method (twopoints, twolines, birdeyes, transform_3d)
    • --source: select source type (0, img.jpg, vid.mp4, path/, path/*.jpg, 'https://youtu.be/Zgi9g1ksQHc', 'rtsp://example.com/media.mp4') corresponding to webcam, image, video, directory, glob, youtube, rtsp-rtmp-http stream
    • --class: select subset of classes corresponding index of classes in COCO dataset
    • --name: the ouput directory name
    • --save: flag to save output image/video
    • --save-txt: flag to write the result as .txt file

yolo8-tracking-counting-speed_estimation's People

Contributors

trinhtuanvubk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

tfgbestneal

yolo8-tracking-counting-speed_estimation'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.