# Algorithm for object tracking

In a video sequence, I would like to track an object. Right now, my detection algorithm can correctly locate the object in approximately 10% of the frames, and incorrectly find something else in 5% of the frames.

The incorrect detections are scattered around in the image, while my object movements are constrained by physics.

I've tried implementing a simple tracker based on distance from last detection (frames and pixels), but since my object moves in a 3d world, the velocity can vary a lot.

I think there is a rather simple approach for tracking this, but I don't have a lot of prior tracking knowledge. Where would I start?

(I appologize if this is not for DSP, please redirect me in that case)

• can you post two consecutive frame? I want to see what transformation models the objects movements, Commented Oct 31, 2016 at 15:37
• Due to rights, I cannot post video material. Assume the FoV of a human being, watching a soccer match from the sideline. The object (e.g. ball or player) will (pixelwise) move slowly in the distance (>30 meters) and very fast near the human (<5 meter). Does this explain what you request? Commented Oct 31, 2016 at 15:47
• You mean, how many pixels the ball moves from frame i to frame i+1? Commented Oct 31, 2016 at 15:52
• Do you have the model of the object (e.g. a 3d mesh) or a prior on the object shape? Commented Jan 30, 2017 at 1:20

assuming you have a relative high frame rate video (the object is moving relatively slow between two consecutive images) some standard tracking algorithms can be applied.

1. Mean shift [Wikepedia - Mean shift]

Use some template of the object you are tracking to create a likelihood function for the object location and track the object.

if you need more advanced method that can be more robust, e.g. object occlusions you can use more advanced methods:

1. kalman filter [Wikipedia - Kalman filter]

In short kalman filter uses a dynamic model that is composed of prediction step and update step to track an object in an unsertain enviroment.

More advanced option you can consider, if you have couple of objects you want to track at the same time is particle filter

you can use this two trackers

• TLD ( Tracking learning and dedication )
• Kalman filter

and these twos are available in opencv 3.2