Items with no label
3335 Discussions

Save fixed_frame of Euclid

GSR
Beginner
1,633 Views

Hi there,

I'm trying to display a previously stored PointCloud2 scene in RViz, but I found out that unless I have my Euclid connected, RViz doesn't know what the fixed_frame "camera_depth_frame" is (obviously), therefore not displaying anything. That's why I need to know if there's any way to save the tf that the Euclid makes to its PointClouds so I can display it again offline.

Thanks!

0 Kudos
10 Replies
Meitav_K_Intel
Employee
643 Views

Hi George,

You can use rosbag record , to register any of the topics you need to use with rviz, then replay them again from any device with rosbag play

Let me know if that's what you wanted to do.

Regards,

Meitav

Intel Euclid Development Team

0 Kudos
GSR
Beginner
643 Views

Hi Meitav,

I was thinking more of using pcl_ros's pointcloud_to_pcd, but making it self-containing, i.e, being able to replay the data in any kind of machine with, say, map / world fixed frame (it really can be anything, I just want it to be oriented the way it was when storing the data)

Thanks in advance.

0 Kudos
Meitav_K_Intel
Employee
643 Views

Hi George,

You can do all that with rosbag, unless I'm missing something or not understanding something. As long as it's a ros topic, you can record it into one rosbag and play it again on any machine you want.

Meitav

Intel Euclid Development Team

0 Kudos
GSR
Beginner
643 Views

Hi there,

with rosbag, what I'm actually doing is "recording a video" of my pointcloud. What I want to do, instead, is saving XYZ values of each point of a single frame of my interest. That way I can work with that data with the PCL Library, and, unless I'm mistaken, rosbag doesn't record data in such easy format (correct me if I'm wrong).

Thanks

0 Kudos
Meitav_K_Intel
Employee
643 Views

Hi George,

Okay, so you basically want to grab a single pointcloud message and dump it into a file? That shouldn't be too hard, yeah. What you basically need to do is create a rosnode that subscribes to the topic and exports any messages there into a simple file format for you to use.

Rosbag essentially records the messages in the topics and replays them as they were. It's not something you can use to dump images for processing in, say, matlab.

I actually intend on posting a rosnode that records the different topics into easy file formats for post processing but it is currently in testing.

Regards,

Meitav

Intel Euclid Development Team

0 Kudos
GSR
Beginner
643 Views

Hi Meitav,

Exactly. Grabbing those points isn't a problem. The thing is that I have to use somehow a tf in order to save them in my desired orientation. I already managed to save a PCD file (http://wiki.ros.org/pcl_ros http://wiki.ros.org/pcl_ros) . Problem is, as soon as I disconnect the Euclid, that fixed frame "camera_depth_frame" is lost, and when displaying that PCD file, it appears to be upside down, or maybe 90 degrees rotated, it depends. So that's why I'm asking if there's any way to store it with an already-correct orientation.

Thanks

0 Kudos
Meitav_K_Intel
Employee
643 Views

Hi George,

First off I apologize for the late reply, I haven't been available in the last week and I appreciate your patience.

If you can register the matching camera_depth_frame that corresponds to the pcd file, then you should be all set.

You could also try and use /tf topic that can be published by the realsense_slam node, but I'm not sure if it correlates to the pointcloud you were trying to register.

Regards,

Meitav

Intel Euclid Development Team

0 Kudos
GSR
Beginner
643 Views

Hi Meitav,

Don't worry for your late reply, I'm grateful for your help. Unfortunately, I don't understand what you mean by "register the matching camera_depth_frame that corresponds to the pcd file". How can I do that? Is there a parameter in pcl_ros or should I write a code specifically to it?

Thanks in advance.

0 Kudos
Meitav_K_Intel
Employee
643 Views

Hi George,

I think you'd need to write specific code for this. If you are running the slam rosnode for Euclid, you should be able to save data from the /tf topic, and I think it will give you the position that you were looking for.

Meitav

Intel Euclid Development Team

0 Kudos
GSR
Beginner
643 Views

Hi Meitav,

Thanks for taking the time. I think everything's clear now.

Greetings.

0 Kudos
Reply