HoEmpire / pedestrian_tracking_and_localizaiton

A package for pedestrian detection, tracking, and re-identification.
12 stars 1 forks source link

pedestrian tracking and localizaiton

visualization

Content

Introduction

A ROS package based on C++ for pedestrian detection, tracking and re-identification (The python package ptl_reid is deprecated, for reference, it remains in this project.). This package is designed for the task of counting the total numbers of pedestrians in an area, and showing their locations on a map.

Just imagining such a condition, you have a wheeled robot equipping with a lidar and a camera (or an RGBD camera). You ask it to go into a building and explore the building thoroughly. When the robot is exploring the building, it will detect and track the pedestrian in its sight, and report the locations of the pedestrians on a map. And after it finishes the exploration, it will tell you how many people are in the building, and the location where the robot see them most recently. This is what this project aims for.

Pipeline

pipeline

Prerequisite

Usage

1. Build

  1. Install the prerequisites

  2. Build a workspace

    mkdir -p ptl_ws/src
  3. Clone this repository in /ws/src

    cd ptl_ws/src
    git clone https://github.com/HoEmpire/pedestrian_tracking_and_localizaiton.git
  4. Build the files

    catkin_make

2. Config

The config files of each package can be found in ${PROJECT_NAME}/config/config.yaml

3. Run

  1. Copy the .weight file of yolo to ptl_ws/src/pedestrain_tracking_and_localizaiton/src/ptl_detector/asset. Copy the .onnx file of re-identification model (which can be obtained from fast-reid model zoo. You can also train your own model using fast-reid.) to ptl_ws/src/pedestrain_tracking_and_localizaiton/src/ptl_reid_cpp/asset

  2. Launch the node

    cd ptl_ws
    source devel/setup.zsh
    roslaunch ptl_node ptl_node
  3. visualize the result

    rosrun rviz rviz -d full_vis_2.rviz

Reference