I'm using amcl package in ROS to localize a mobile robot. I've changed min_particles and max_particles several times then calculated the output difference with odomotry to evaluate these parameters. The table below demonstrate results; As you see, there is no notable change in the output and if you ignore the first row of the table, output variance is small. enter image description here
And this is the Particle Filter output on the map:
enter image description here


2 Answers 2


Once you have enough particles to resolve your position, the effect of adding more particles shrinks to zero. You are likely seeing the best possible results that your particle filter can achieve.

It looks like the smallest adequate number of particles for your simulation is somewhere between 120 and 1200, and my guess is that if you plotted the Odom difference vs max_particles, you would see a curve that was near-vertical at max_particles = 1, decreasing past 172 at max_particles = 120and near-horizontal at 149 by the time max_particles got to 1200.


It is not completely clear what your question is, but I assume you wanted to ask: Why does the output not change with the number of particles above a certain number of particles?

By allowing amcl to use more samples, you decrease the errors (or inaccuracies) that are caused by the fact that the particle filter approximates your probability distributions using Monte Carlo sampling. Above a certain number of samples, these errors from Monte Carlo approximation are so small that they are negligible compared to other sourceof uncertainty, e.g. measurement, system, or odometry uncertainty.

Thousands of particles are in my experience many more than you need for local localization in 2D (when the robot has a rough estimate of where it is already). You will likely only need so many particles for global localization, i.e. when the robot does not know anything (for example during initialization).


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.