Unit 4 - EKF and UKF - error in ukf_filtering

Hi,

I am currently working on Kalman Filters course and on the section 4.11 Configuring the robot_localization package.

Summary / TLDR:
Running roslaunch ukf_filtering ukf_filtering.launch produces this error:
[FATAL] [1678106298.789320387, 2411.050000000]: Could not read sensor update configuration for topic odom0 (type: 7, expected: 7). Error was type error
The error is confusing as expected type and provided type are the same.

==========

After configuring, building and running ukf_filtering package as stated in the course notes, I get the following error.

Webshell 1 Output (NO ERROR HERE):

user:~$ roslaunch ekf_ukf auxiliary_nodes.launch
... logging to /home/user/.ros/log/1b54c978-bc16-11ed-83d8-0242c0a8e007/roslaunch-4_xterm-8514.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://4_xterm:40635/

SUMMARY
========

PARAMETERS
 * /robot_description: <?xml version="1....
 * /rosdistro: kinetic
 * /rosversion: 1.12.14

NODES
  /
    noisy_odom_node (ekf_ukf/noisy_odom_republisher.py)
    robot_state_publisher (robot_state_publisher/robot_state_publisher)
    spawn_urdf (gazebo_ros/spawn_model)

ROS_MASTER_URI=http://4_simulation:11311

process[spawn_urdf-1]: started with pid [8524]
process[robot_state_publisher-2]: started with pid [8525]
process[noisy_odom_node-3]: started with pid [8528]
[INFO] [1678106283.200705, 2395.606000]: Started noisy odometry publisher node
[spawn_urdf-1] process has finished cleanly
log file: /home/user/.ros/log/1b54c978-bc16-11ed-83d8-0242c0a8e007/spawn_urdf-1*.log

Webshell 2 Output (ERROR HERE):

user:~/catkin_ws$ roslaunch ukf_filtering ukf_filtering.launch
... logging to /home/user/.ros/log/1b54c978-bc16-11ed-83d8-0242c0a8e007/roslaunch-4_xterm-8599.log
Checking log directory for disk usage. This may take awhile.
Press Ctrl-C to interrupt
Done checking log file disk usage. Usage is <1GB.

started roslaunch server http://4_xterm:35335/

SUMMARY
========

CLEAR PARAMETERS
 * /ukf_localization_node/

PARAMETERS
 * /rosdistro: kinetic
 * /rosversion: 1.12.14
 * /ukf_localization_node/base_link_frame: base_link
 * /ukf_localization_node/frequency: 50
 * /ukf_localization_node/imu0: /mobile_base/sens...
 * /ukf_localization_node/imu0_config: [False, False, Fa...
 * /ukf_localization_node/imu0_differential: False
 * /ukf_localization_node/initial_estimate_covariance: ['1e-9', 0, 0, 0,...
 * /ukf_localization_node/odom0: /odom_noisy
 * /ukf_localization_node/odom0_config: [False, False, 'f...
 * /ukf_localization_node/odom0_differential: False
 * /ukf_localization_node/odom_frame: odom
 * /ukf_localization_node/process_noise_covariance: [0.05, 0, 0, 0, 0...
 * /ukf_localization_node/publish_tf: False
 * /ukf_localization_node/two_d_mode: True
 * /ukf_localization_node/world_frame: odom

NODES
  /
    ukf_localization_node (robot_localization/ukf_localization_node)

ROS_MASTER_URI=http://4_simulation:11311

process[ukf_localization_node-1]: started with pid [8608]
[FATAL] [1678106298.789320387, 2411.050000000]: Could not read sensor update configuration for topic odom0 (type: 7, expected: 7). Error was type error

The error seems confusing to me as it says “type: 7 and expected: 7” and that there is a “type error”. If the expected type and provided type are the same (7 here), why do I get this error?

Thanks,
Girish

Hi,

I have solved this problem.

The mistake was I did not have commas in the following lines:

odom0_config: [false, false, false # missing comma here
               false, false, false # missing comma here
               true,  true,  false # missing comma here
               false, false, true # missing comma here
               false, false, false]

I did not pay attention to the commas there, which was my mistake.

I copy-pasted the above from the course notes:
As you can see, there are no commas here.
image

But the final file had the commas:
image

So, to fix this problem, I just added the commas.

– Girish

Hello @girishkumar.kannan,

Thank you very much for reporting this, I have fixed this error by adding the missing commas.
Corrected unit should be already online.

Regards,

Roberto

1 Like