0
$\begingroup$

Rosanswers logo

Unable to get any point in the cloud. The periodic_snapshotter node gives the message: Published Cloud with 0 points My aim is to make a point cloud from the tilt_laser topic published by the bag file. (See below)

This is my launch file:

<launch>


 <node pkg="laser_assembler" type="laser_scan_assembler" output="screen"  name="laser_scan_assembler">
 
   <param name="max_scans" type="int" value="400" />
    <param name="fixed_frame" type="string" value="map" />
  </node>

 <node pkg="laser_assembler" type="periodic_snapshotter" output="screen" name="periodic_snapshotter" />
 
<node pkg="tf" type="static_transform_publisher" name="baselink_laser_broadcaster" args="0 0 1 0 0 0 map odom_combined 10"/>

</launch>

I am using following bag file from MIT: http://infinity.csail.mit.edu/data/2011/2011-01-24-06-18-27.bag

This is my tf frames: https://onedrive.live.com/redir?resid=BBBC11C59055486D!36796&authkey=!AHmnv__kiryoPwE&ithint=file%2cpdf

EDIT=================================== The following is being published by the MIT bag file that I am using:

topics: /base_odometry/odom 21032 msgs : nav_msgs/Odometry
/base_odometry/odometer 224 msgs : pr2_mechanism_controllers/Odometer
/base_odometry/state 224 msgs : pr2_mechanism_controllers/BaseOdometryState /base_scan 4489 msgs : sensor_msgs/LaserScan
/robot_pose_ekf/odom_combined 6333 msgs : geometry_msgs/PoseWithCovarianceStamped
/tf 12687 msgs : tf/tfMessage
/tilt_scan 4489 msgs : sensor_msgs/LaserScan
/torso_lift_imu/data 22451 msgs : sensor_msgs/Imu
/torso_lift_imu/is_calibrated 1 msg : std_msgs/Bool
/wide_stereo/left/camera_info_throttle 220 msgs : sensor_msgs/CameraInfo
/wide_stereo/left/image_rect_throttle 220 msgs : sensor_msgs/Image
/wide_stereo/right/camera_info_throttle 220 msgs : sensor_msgs/CameraInfo
/wide_stereo/right/image_rect_throttle 220 msgs : sensor_msgs/Image


Originally posted by Shantnu on ROS Answers with karma: 86 on 2016-06-08

Post score: 1

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

It worked finally!!!. The tutorial (http://wiki.ros.org/laser_assembler/Tutorials/HowToAssembleLaserScans) documentation is little confusing. After reading the tutorial, it feels like the input topic to the laser_assembler is tilt_scan. However, if you see the code in laser_scan_assembler.cpp, it turns out that the subscribed topic is /scan.

After realizing that the required topic is scan and not tilt_scan, I tried to do remapping as follows:

    <launch>


 <node pkg="laser_assembler" type="laser_scan_assembler" output="screen"  name="laser_scan_assembler">
 <remap from="tilt_scan" to="scan"/>
   <param name="max_scans" type="int" value="400" />
    <param name="fixed_frame" type="string" value="map" />
  </node>

 <node pkg="laser_assembler" type="periodic_snapshotter" output="screen" name="periodic_snapshotter" />

<node pkg="tf" type="static_transform_publisher" name="baselink_laser_broadcaster" args="0 0 1 0 0 0 map odom_combined 10"/>

</launch>

However, it still produced 0 point clouds. Finally, running the bag file as rosbag play --clock bagfiles/b.bag /tilt_scan:=/scan helped me get the point clouds. Don't do remapping inside the launch file. Just do it when you are playing bag file..

Let me know if anyone faces problem in using laser_assembler. Below is the launch file that worked for me using the MIT bag file that I have attached above

<launch>


 <node pkg="laser_assembler" type="laser_scan_assembler" output="screen"  name="laser_scan_assembler">
    <param name="max_scans" type="int" value="400" />
    <param name="fixed_frame" type="string" value="map" />
  </node>

 <node pkg="laser_assembler" type="periodic_snapshotter" output="screen" name="periodic_snapshotter" />
 
<node pkg="tf" type="static_transform_publisher" name="baselink_laser_broadcaster" args="0 0 0 0 0 0 map odom_combined 10"/>

</launch>

Originally posted by Shantnu with karma: 86 on 2016-06-08

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by Burgos on 2017-08-07:
What branch of the laser_assembler are you using? I'm trying to follow all the steps you mention, but the periodic snapshotter still says that it is publishing a cloud with 0 points... I'm in Ubuntu 16.04 with ROS Kinetic

$\endgroup$

Your Answer

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