ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Unorganized point clouds for octomap

asked 2012-10-23 03:22:11 -0500

Sudhan gravatar image

updated 2014-01-28 17:14:02 -0500

ngrennan gravatar image

Following, Felix's answer for this question(http://answers.ros.org/question/12995/2d-map-from-octomap/), I tried to generate a 2d map from octomap for localization.

As explained in that answer, I wrote a node to listen the output of the node 'rgbdslam'. This node uses the passthrough filter from pcl library to take a slice of the 3d point cloud. I used the same parameters in the launch file octomap_server.launch from rgbdslam package. I can view the required point clouds in pcd viewer, i.e) thin slice of the 3d octomap. While, I try to save it as a map using nodes octomap_server and saver, it shows only single point as a map.

While trying to find the problem, I note that the point cloud which is send as input to the octomap_server is an unorganized point cloud. I think this might be a problem.

If so, Is there any idea to convert unorganized point cloud to orgainized point cloud or any other solution for this problem?

Thanks in advance for your suggesstions.


UPDATED: While, running the normal rgbdslam algorithm as described in (http://www.ros.org/wiki/rgbdslam). After doing $roslaunch rgbdslam octomap_server.launch, I opened rviz and viewed the topic '/octomap_point_cloud_centers'. In rviz, I could view the complete point cloud whatever I see in the rgbdslam GUI. But, While try to view those point clouds after the 'new_node' (node which I wrote), I could able to view only the initial sliced part of the point cloud. I think this is due to the high frequency publishing of a topic 'rgbdslam/batch_clouds'.

Any solutions for this problem?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2012-10-23 05:35:07 -0500

updated 2012-10-23 13:02:15 -0500

Hi Sudhan,

Edit: I found a bug, where the tf frames of the old openni_camera driver are hardcoded. Because of this, octomap_server will not find a transformation between /map and the point cloud frame when using openni_launch. I'll try to release a fix soon.

in general, rgbdslam does not alter the received point cloud. Therefore they are sent out as structured (check width and height values are both > 1). Maybe you are wondering about the "is_dense" property, which is defined as "does not contain NaN values" and is set by the openni driver. Anyway structured or not, dense or not, this should not be the problem.

edit flag offensive delete link more

Comments

I use '/tf' from 'rgbdslam' and 'sliced_batch_clouds' from the 'new_node' as input for 'octomap_server' node using 'octomap_server.launch'. The property of 'sliced_batch_cloud'

  1. height is 1

  2. is_dense is true

If I do $ rostopic echo sliced_batch_clouds, I can see some numbers. (contd..)

Sudhan gravatar image Sudhan  ( 2012-10-24 01:14:56 -0500 )edit

..(contd..).. I tried writing the point cloud as '.pcd' file before publishing it to a rostopic. There I see a sliced piece of point cloud.

Note: The 'new_node' just subscribes and edit the topic 'rgbdslam/batch_clous' and publishes 'sliced_batch_clouds' using passthrough filter.

Sudhan gravatar image Sudhan  ( 2012-10-24 01:20:21 -0500 )edit

Well, in that case it is the passthrough filter that destroys the structuredness. And hence there is no point in keeping the NaN values anymore, so it probably makes it dense as well.

Felix Endres gravatar image Felix Endres  ( 2012-10-24 02:39:22 -0500 )edit

If I view the topics '/map' and '/octomap_point_cloud_centers' from 'octomap_server' using 'rviz', I could see the required map and point clouds repsectively. I think so, this might be helpful for you in fixing bugs.

Sudhan gravatar image Sudhan  ( 2012-10-24 22:34:30 -0500 )edit

Could you update and let me know whether it works?

Felix Endres gravatar image Felix Endres  ( 2012-10-25 02:45:27 -0500 )edit

I didn't understand that what should I update?

Sudhan gravatar image Sudhan  ( 2012-10-25 03:11:20 -0500 )edit

Your copy of rgbdslam with "svn up"

Felix Endres gravatar image Felix Endres  ( 2012-10-25 12:17:34 -0500 )edit

I would like to know, where you publish the topic "rgbdslam/batch_clouds"? I can find something about it in file "parameter_server.cpp". But I would like to change the queue size of publishing data, there is no option for that in this file. So, where to change the queue size of the publishing data?

Sudhan gravatar image Sudhan  ( 2012-10-29 04:59:57 -0500 )edit

Question Tools

Stats

Asked: 2012-10-23 03:22:11 -0500

Seen: 1,276 times

Last updated: Oct 25 '12