Code Monkey home page Code Monkey logo

ros_iou_tracking's Introduction

ros_iou_tracking

A ROS package that applies multiple object tracking (MOT) to YOLO detection

Requirements

1. Realtime object detector

leggedrobotics/darknet_ros: A ROS package for YOLO detection

2. Multiple object tracker

abewley/sort: simple online realtime tracker

Pipeline

  1. train YOLO with your own data
  2. launch darknet_ros with well-trained YOLO
  3. launch ros_sort

1. Webcam test

ROS package usb_cam is used to launch webcam. The image topic name should also be changed in darknet_ros/darknet_ros/config/ros.yaml.

roslaunch usb_cam usb_cam-test.launch
roslaunch darknet_ros darknet_ros.launch
rosrun ros_iou_tracking iou_tracker.py

Video

2. Gazebo test (rosbag)

roslaunch ros_iou_tracking rosbag_pbr_test.launch

image

Semi-automatic annotation (todo)

  1. train YOLO with a small set of annotations
  2. automate annotation augmentation using offline object tracking
  3. correct automatic annotations if necessary
  4. retrain YOLO with previous and augmented data

Topics

Node: /iou_tracker_node
Publications:

  • /iou_tracker/bounding_boxes [darknet_ros_msgs/BoundingBoxes]
  • /iou_tracker/detection_image [sensor_msgs/Image]

Subscriptions:

  • /bounding_boxes_drop [darknet_ros_msgs/BoundingBoxes]
  • /darknet_ros/detection_image [sensor_msgs/Image]

Related work

Mutiple object tracking

  1. bochinski/iou-tracker
    The original IoU tracker is also using IoU information. However, it does not have Kalman filter (and Hungarian algorithm) for tracking, and only uses IoU for target association. It has several strict requirements:
    (1) there should be no detection gaps among frames; otherwise the tracked target will be removed.
    (2) the frame rate should be high enough so the IoU thresholds are guaranteed between successive frames.
    The extended work allows detection gaps by allowing bounding boxes that do not have new detections stay at the last position for several frames. Not only does it fill the detection gaps forward, it also does so backwards, which makes it less ideal for realtime tracking. Also, compared with SORT, predicting bounding box using Kalman filter that has considered the bounding box velocity is a better appoach to having undetected bounding box stay at the last position, when the camera motion is smooth.

Acknowledgement

[sort.py] is adapted from abewley/sort to support large detection gaps.

ros_iou_tracking's People

Stargazers

Steve Nogar avatar  avatar  avatar redrouge avatar

Watchers

James Cloos avatar Zhiang Chen avatar

ros_iou_tracking's Issues

i am getting this issue when running rosrun ros_iou_tracking iou_tracker.py

[ERROR] [1689158125.566860]: bad callback: <bound method IoUTracker.__raw_image_callback of <main.IoUTracker object at 0x7f7d729780>>
Traceback (most recent call last):
File "/opt/ros/melodic/lib/python2.7/dist-packages/rospy/topics.py", line 750, in _invoke_callback
cb(msg)
File "/home/dtd/catkin_ws/src/ros_iou_tracking/src/iou_tracker.py", line 110, in __raw_image_callback
raw_image = self.bridge.imgmsg_to_cv2(data).astype(np.uint8)
File "/home/dtd/catkin_ws/src/vision_opencv/cv_bridge/python/cv_bridge/core.py", line 163, in imgmsg_to_cv2
dtype, n_channels = self.encoding_to_dtype_with_channels(img_msg.encoding)
File "/home/dtd/catkin_ws/src/vision_opencv/cv_bridge/python/cv_bridge/core.py", line 99, in encoding_to_dtype_with_channels
return self.cvtype2_to_dtype_with_channels(self.encoding_to_cvtype2(encoding))
File "/home/dtd/catkin_ws/src/vision_opencv/cv_bridge/python/cv_bridge/core.py", line 91, in encoding_to_cvtype2
from cv_bridge.boost.cv_bridge_boost import getCvType
ModuleNotFoundError: No module named 'cv_bridge.boost.cv_bridge_boost'


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.