0
$\begingroup$

Rosanswers logo

Hello

I'm trying to use the navigation stack with the odometry given by an EKF that fuses three sensors: the encoder based odometry, an IMU, and a GPS. The output of the EKF seems to be nice, and if it's relevant publishes the position in UTM's.

The problems start when I use the AMCL for doing the localization on the map. When I run the AMCL, the particles cloud begins to diverge, and then the localization is very poor and the move_base package can't make the robot move very well. Furthermore, the estimated position of the robot jumps around the real pose of the robot, and that makes even worse the localization. I've filtered the output of the EKF and this problem persists.

And sometimes, while I'm running the move_base with the AMCL I get this warning:

[ WARN] [1352195952.098814110, 3250.301000000]: The origin for the sensor at (182092.21, -2410790.70) is out of map bounds. So, the costmap cannot raytrace for it.

I only get this warning sometimes, don't know the reason. After this warning the robot tries again to move, so I think that the AMCL has made a jump outside the map but in the next iteration it has corrected itself. But it just a supposition, I don't know exactly why I get this warning or if that's the reason why I cant make work the EKF with the AMCL.

I've tested to use the encoder based odometry only and all this problems disappear, I have this problems only when I run the EKF and the AMCL simultaneously.

Does anyone have the same problem?

Here you have the parameters of the AMCL:

<launch>
<node pkg="amcl" type="amcl" name="amcl" output="screen">

  <remap from="scan" to="tof_camera/fake_laser" />
  <remap from="cmd_vel" to="summit_xl_ctrl/command" />

  <!-- Publish scans from best pose at a max of 10 Hz -->
  <param name="odom_model_type" value="diff"/>
  <param name="odom_alpha5" value="0.1"/>
  <param name="transform_tolerance" value="0.2" />
  <param name="gui_publish_rate" value="10.0"/>
  <param name="laser_max_beams" value="30"/>
  <param name="min_particles" value="500"/>
  <param name="max_particles" value="5000"/>
  <param name="kld_err" value="0.5"/>
  <param name="kld_z" value="0.999"/> 
  <param name="odom_alpha1" value="0.2"/>
  <param name="odom_alpha2" value="0.2"/>
  <!-- translation std dev, m -->
  <param name="odom_alpha3" value="0.8"/>
  <param name="odom_alpha4" value="0.2"/>
  <param name="laser_z_hit" value="0.5"/>
  <param name="laser_z_short" value="0.05"/>
  <param name="laser_z_max" value="0.05"/>
  <param name="laser_z_rand" value="0.5"/>
  <param name="laser_sigma_hit" value="1.0"/>
  <param name="laser_lambda_short" value="0.1"/>
  <param name="laser_model_type" value="likelihood_field"/>
  <!-- <param name="laser_model_type" value="beam"/> -->
  <param name="laser_likelihood_max_dist" value="2.0"/>
  <param name="update_min_d" value="0.6"/>
  <param name="update_min_a" value="0.5"/>
  <param name="odom_frame_id" value="odom_combined"/>
  <param name="base_frame_id" value="base_footprint"/>
  <param name="global_frame_id" value="map"/>
  <param name="resample_interval" value="1"/>
  <param name="transform_tolerance" value="0.6"/>
  <param name="recovery_alpha_slow" value="0.0"/> 
  <param name="recovery_alpha_fast" value="0.0"/>  

  <param name="initial_pose_x" value ="0.0"/>
  <param name="initial_pose_y" value ="0.0"/>
  <param name="initial_pose_a" value ="0.0"/>

</node>
</launch>

I'm on Ubuntu 12.04 and ROS Fuerte.

Thanks in advance!


Originally posted by g.aterido on ROS Answers with karma: 229 on 2012-11-06

Post score: 0

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

I guess the output of robot_pose_ekf is inconsistent or you have a problem with your laser sensor. A few things I would try:

  • Try use AMCL together with unfiltered odometry. If it is working, the problem lies in your EKF implementation. Otherwise it is probably caused by your laser sensor.

  • Make sure your units are correct, i.e. the output of odometry (and of the filtered odometry coming from the EKF) must be in meters, velocities must be in m/s. Laser range data must also be in meters.

  • Make sure that your laser sensor is configured properly. Visualize it using rviz and check if obstacles appear at correct positions.

  • If the problem lies in EKF, consider disabling GPS and only use IMU and raw odometry. Consider trying robot_pose_ekf just to verify that the problem is not caused by the integration of GPS.


Originally posted by Lorenz with karma: 22731 on 2012-11-06

This answer was ACCEPTED on the original site

Post score: 4


Original comments

Comment by g.aterido on 2012-11-06:
The problem must lie in the EKF, because with unfiltered odometry it works fine. The laser is not the problem, because when I visualize it with rviz all seems to be ok. When I use the EKF without the GPS the problem disappears, but then I loose the absolute reference for localization

Comment by Lorenz on 2012-11-06:
When adding GPS does maybe the behavior of your covariance matrix change? I'm not sure if AMCL actually uses it, it's just a guess. When using GPS, are your coordinates maybe really big? Can you maybe map them to some artificial origin close to your location to avoid possible numerical problems?

Comment by g.aterido on 2012-11-19:
Well, I used a simplified version of the EKF, and the problem was solved. So as you said, the problem lies in the EKF, but don't know why. Using the big UTMs coordinates was not the problem, with this new version I use the same coordinates and all works fine. Thanks anyway for the hints ;)

$\endgroup$
0
$\begingroup$

Rosanswers logo

use AMCL's filter and do the sensor fusion by raw data. it doesn't really make sense to use an already filtered pose as input.If you already have a map and would like to localize your robot in it, you should use amcl_pose. As for the /odom topic, it is subscribed by move_base not for the pose information but for the velocity


Originally posted by cagatay with karma: 1850 on 2012-11-06

This answer was NOT ACCEPTED on the original site

Post score: 1


Original comments

Comment by Lorenz on 2012-11-06:
AMCL and the EKF are definitely not doing the same thing. It is really common to use them together, e.g. on the turtlebot or the PR2 (without GPS though). AMCL does particle-filter based localization using laser and odometry, i.e. it uses features of the environment for global localization.

Comment by cagatay on 2012-11-06:
Sorry, I mean that they both filter the odometry data

$\endgroup$

Your Answer

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