Re: [ros-users] octomap

Top Page
Attachments:
Message as email
+ (text/plain)
Delete this message
Reply to this message
Author: User discussions
Date:  
To: User discussions
CC: Raphael Favier
Subject: Re: [ros-users] octomap
Hi Raphael,
> It indeed worked fine, except that the function becomes very slow and fill
> out all my memory (4GB) if the leaf size is small (0.01) and the number of
> scan points large (> 75 000).
> Nevertheless, I have a good and fast processing speed with leaf size around
> 0.05.

Of course there's a tradeoff between memory efficiency and resolution,
and while OctoMap surely improves it compared to a full 3D voxel grid,
it cannot get rid of the complexity of 3D mapping. If the leaf size is
slightly larger than the spacing of your scan endpoints and you
integrate multiple scans, the compression of the tree ("pruning") could
help you better.

> I would still have a few general questions related to octomap:
>
> I would like to use octomap in order to build precise indoor maps using a
> robotic base with a mounted Kinect on it.
> What would be the best strategy according to you?
>    a) add points in an Octree on the fly, using insertScan for each.
>    b) generate a log file of all scans on the fly, and create a tree offline
> using log2graph and graph2tree
>    c) generate a ScanGraph on the fly and create a tree from it offline.
>    d) other way?

Sounds exciting! It will all have the same result, as everything uses
insertScan in the end. It mainly depends on what tools you want to use,
how comfortable you are working with live data vs. log files, and what
log format you prefer (our plain text, binary scan, or ROS bags). Using
log2graph on plain text log files will enable you to open the file
incrementally in our octovis viewer and insert scan after scan, which
renders faster and is easier to use than octomap_server with RViz.

> Also, I woud like to store a color information in my nodes.
> Should I create a node class that inherits from octomap::OcTreeDataNode< T>
> and add a color field or is there a way to do it directly?

That should be the way, either use an OcTreeDataNode< pair<float, color>
> and reimplement what you need for occupancy mapping, or inherit from

OcTreeNode and add a color member (see OcTreeNodeLabeled as example,
though it's not much more than that - an example). In any case, this
will all probably require changes to the tree class, viewer, and the IO
methods if you want to use our binary files.

Best regards,
Armin

--
Armin Hornung
Humanoid Robots Lab, Albert-Ludwigs-Universität Freiburg
Contact: http://www.informatik.uni-freiburg.de/~hornunga