Ask Your Question

Problem generating PCD from rgbdslam

asked 2011-04-13 02:39:37 -0600

Shark gravatar image

updated 2014-01-28 17:09:31 -0600

ngrennan gravatar image

I've currently been using a bag file approach to run rgbdslam. The procedure I use is as follows:

I record a bag file with rgbdslam using the command:

rosbag record /rgbdslam/batch_clouds /tf

And then I use the command:

rosrun pcl_ros bag_to_pcd <bag_file_name> /rgbdslam/batch_clouds <destination_directory>

However, the error I get when running the above command is as follows:

[ERROR] [######]: Frame id /base_link does not exist! When trying to transform between /batch_transform and /base_link.

I assume this problem likely has to do with applying the correct transform from the /tf recorded in the bag file. Is there an simple solution to this, or will I need to make an edit to the bag_to_pcd code to work for this specific case?


edit retag flag offensive close merge delete

3 answers

Sort by ยป oldest newest most voted

answered 2011-04-13 22:05:39 -0600

will I need to make an edit to the bag_to_pcd code to work for this specific case?

Yes, open bag_to_pcd.cpp and replace the one occurence of /base_link by /openni_camera

edit flag offensive delete link more

answered 2011-04-14 00:10:21 -0600

Shark gravatar image

updated 2011-04-14 00:29:24 -0600

So the bag_to_pcd code is working fine with the bag file provided on the rgbd6dlsm webpage. However, when I try recording it on bag files I've generated, I get a bunch of errors that look like as follows:

[ WARN] [1302782687.209693801]: TF_OLD_DATA ignoring data from the past for frame /openni_depth_frame at time 1.30278e+09 according to authority /bag_to_pcd Possible reasons are listed at

[ERROR] [1302782687.243355116]: You requested a transform that is 103.609 seconds in the past, but the tf buffer only has a history of 0.288 seconds. When trying to transform between /batch_transform and /openni_camera.

Is this likely an error during data collection? As indicated in the original post, I execute the command to start recording before I hit CTRL+P. After I have sent the world model (CTRL+S), I then ctrl+c out of the rosbag record.

And I forgot to thank you for your help in my earlier posts. Your help is very much appreciated

Edit: Nevermind, the converter seems work on occasion with my own bag files.


edit flag offensive delete link more


Not exactly sure why, but restarting roscore seems to remedy this problem. Just a heads up for anyone else who might run into this problem. Shark ( 2011-04-14 02:52:39 -0600 )edit
Could it be that you still had roslaunch openni_camera openni_node.launch running? Then the kinect_base_linkX nodes publish transforms with newer timestamps Felix Endres ( 2011-04-14 03:16:24 -0600 )edit
Ahh yes, you're right. I had my openni_camera.launch running too (so turning off roscore inadvertently made me turn off the openni_camera too). Shark ( 2011-04-15 10:51:30 -0600 )edit

answered 2011-04-13 23:32:49 -0600

Shark gravatar image

updated 2011-04-13 23:42:10 -0600

So I implemented this as my own package called "bag_to_pcd2." I just want to confirm, but should the output be a series of pcd files? I was under the assumption that it would be one combined pcd file.

If not, I guess I can right my own pcd combiner.

edit flag offensive delete link more


If so, they should all be in the same frame. Write the pcd files to ascii and you could even concatenate the point clouds with a text editor Felix Endres ( 2011-04-13 23:57:48 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

[hide preview]


Asked: 2011-04-13 02:39:37 -0600

Seen: 473 times

Last updated: Apr 14 '11