Skip to main content

Video Object Tracking Toolkit

Project description

VidTracker

CI Python License

VidTracker is a Python package for object tracking


Tracker

Tracker Paper Description
DFSTracker Distribution Fields for Tracking (CVPR 2012) Smooth histogram fields with spatial/feature domain convolution
MILTracker Visual Tracking with Online Multiple Instance Learning (CVPR 2009) Online boosting with Haar features
LKTracker Based on Lucas-Kanade optical flow Tracks feature points and estimates affine transforms

Dataset

You can download the original MILTrack dataset (e.g., cliffbar) from:
--> https://bbabenko.github.io/miltrack.html

Extract the dataset into data/input/ to match the folder structure shown below.

Project Structure

.
├── config.json
├── data
   ├── input
      ├── cliffbar
         ├── cliffbar_frames.txt
         ├── cliffbar_gt.txt
         ├── cliffbar_MIL_TR*.txt
         ├── imgs/
             └── imgXXXXX.png
      ├── cliffbar.zip
   └── output/
      ├── cliffbar
         └── imgXXXXX.png
├── tests/
└── vidtracker/
    ├── cli.py
    ├── dfs.py
    ├── lk.py
    ├── mil.py
    ├── util.py
    └── video.py

Installation

From PyPI:

pip install vidtracker

From GitHub:

pip install git+https://github.com/keyneoei/vidtracker.git

Or locally:

git clone https://github.com/keyneoei/vidtracker.git
cd vidtracker
pip install .

CLI Usage

python -m vidtracker.cli --input=data/input/cliffbar/imgs --output=data/output/cliffbar --tracker=DFS --show_frames

Usage Example (Python)

from vidtracker import DFSTracker, MILTracker, LKTracker

tracker_type = "DFS"    # or "MIL", "LK"
frame = ...             # read video frame
init_bbox = ...         # init bbox
cfg = ...               # configuration (box)

if tracker_type == "DFS":
    tracker = DFSTracker(frame, init_bbox, cfg)
elif tracker_type == "MIL":
    tracker = MILTracker(frame, init_bbox, cfg)
elif tracker_type == "LK":
    tracker = LKTracker(frame, init_bbox, cfg)

# Process subsequent frames
x, y, w, h, angle = tracker.process_frame(next_frame)

References

  • DFS: Sevilla-Lara, L., Learned-Miller, E. (2012). Distribution Fields for Tracking. CVPR.
  • MIL: Babenko, B., Yang, M.-H., & Belongie, S. (2009). Visual Tracking with Online Multiple Instance Learning. CVPR.
  • LK: Lucas, B., & Kanade, T. (1981). An Iterative Image Registration Technique. DARPA.

License

This project is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vidtracker-0.1.2.tar.gz (16.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vidtracker-0.1.2-py3-none-any.whl (17.3 kB view details)

Uploaded Python 3

File details

Details for the file vidtracker-0.1.2.tar.gz.

File metadata

  • Download URL: vidtracker-0.1.2.tar.gz
  • Upload date:
  • Size: 16.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.8.18

File hashes

Hashes for vidtracker-0.1.2.tar.gz
Algorithm Hash digest
SHA256 87a54bc4d5cd62da799076c65f9a3a5fe822cddd1c8b4bfe830d6866717353bc
MD5 0f33eaaab0ca08ad3f8109803c61406f
BLAKE2b-256 76a37622205505bd9423abe2ff5d62558dd4b32bb14eb9258131d2fee47e4c64

See more details on using hashes here.

File details

Details for the file vidtracker-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: vidtracker-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 17.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.8.18

File hashes

Hashes for vidtracker-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 b3e424b129cd26bda739e2375ef726c915c14f8f381c3793120358af8a31c435
MD5 8d5f774014bc17a05e811221f2cca29b
BLAKE2b-256 de21426c9ccaf765f1726a3275b5317124c8763788f88619f075f23f18408a15

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page