How to change the default number of particles in gmapping launch file?

I would like to ask is this is the correct coding to change the number of particles of the gmapping package in launch file?

<launch>
  <!-- Arguments -->
  <arg name="model" default="$(env TURTLEBOT3_MODEL)" doc="model type [burger, waffle, waffle_pi]"/>
  <arg name="configuration_basename" default="turtlebot3_lds_2d.lua"/>
  <arg name="set_base_frame" default="base_footprint"/>
  <arg name="set_odom_frame" default="odom"/>
  <arg name="set_map_frame"  default="map"/>

  <!-- Gmapping -->
  <node pkg="gmapping" type="slam_gmapping" name="turtlebot3_slam_gmapping" output="screen">
    <param name="base_frame" value="$(arg set_base_frame)"/>
    <param name="odom_frame" value="$(arg set_odom_frame)"/>
    <param name="map_frame"  value="$(arg set_map_frame)"/>
    <param name="particles"  value="100"/>
    <rosparam command="load" file="$(find turtlebot3_slam)/config/gmapping_params.yaml" />
  </node>
</launch>

Im adding <param name="particles" value="100"/> in the launch file as above.
Thank you.

Yes, particles is a parameter to change the number of particles in the filter. You can check all parameters here:

http://wiki.ros.org/gmapping

1 Like

thank you sir for replying my question

This topic was automatically closed after 7 days. New replies are no longer allowed.