1. Introduction
The particle filter is a sequential Monte Carlo algorithm, i.e. a sampling method for approximating a distribution that makes use of its temporal structure. A particle representation” of distributions is used. In particular, we will be concerned with the distribution where
is the unobserved state at time
, and
is the sequence of observations from time
to time
.
2. Explanation of Project
a. Problem : Track specified color using Particle Filter
This project is aimed to track a red target object with RGB value .

b. Program Flow
– Initialize particles
;
;
;
;
– Sampling (Prediction)
;
;
Velocity (v) of each particle is used to predict where and how fast the particle moves, even the object kidnapped from scene. Transition is obtained from minimum distance of particles, it means that if the object disappears from the scene or closed by something else, its distances will be higher and we have to attempt larger uncertainty for next sampling.
– Calculation of likelihood (correction)
Distance calculation of each particle :
;
Likelihood calculation :
;
;
– Resampling
Make another set of particles with replacement using weights/sum of likelihood as probabilities. This step is a way of keeping the number of effective sample constant.
– Drawing
Draw each position of particle as yellow dot, and make estimation of object current position by green circle. Here is the result for number of particles 500, 1000, and 2000.
N=500
N=1000
N=2000
Please don’t hesitate to make a discussion
Reference :
This tutorial based on Final Project of Advance Robotics Course on Toyohashi University of Technology
