Skip to main content

Table 1 Meanshift algorithm for finding the maximization of probability distribution

From: Object tracking system using a VSW algorithm based on color and point features

 

Given the distribution {q u }u = 1,...,mof a detected object and the location y0 of the detected object in the previous frame.

 

Step 1. Compute the distribution p u in the current frame with y0 and compute the Bhattacharyya distance (= ρ) between p u and q u as follows:

ρ p ( y 0 ) , q = u = 1 n p u ( y 0 ) q u .

 

Step 2. Compute the weight (w i ) is defined as follow:

w i = u = 1 m δ b ( x i ) - u q u p u ( y 0 ) ,

where b(x i ) is the color bin of the color at x i .

 

Step 3. Derive the new location y1 can be defined as follow:

y 1 = i = 1 n x i w i g y 0 - x i h 2 i = 1 n w i g y 0 - x i h 2 ,

where h is a window radius and g() is a kernel G.

 

Step 4. Compute the Bhattacharyya distance (= ρ) between p u and q u in the new location y1.

 

Step 5. While ρ|p(y0), q| <ρ|p(y1), q|

Do y1 = 1/2(y0+y1).

 

Step 6. If ||y1-y0|| <ε Stop.

Otherwise, y0 = y1 and go to Step 1.