tesseract_ros icon indicating copy to clipboard operation
tesseract_ros copied to clipboard

how to manager the octomap updates from pointcloud of camera?

Open xibeisiber opened this issue 3 years ago • 4 comments

Hi all, I wonder how to create the collision information in tesseract_environment::Environment automatically from the pointcloud of a camera.

I saw in the example that I can manually convert the pointcloud to octomap and use tesseract_environment::AddLinkCommand to add the collision info to tesseract_monitoring::EnvironmentMonitor. But if the enviroment is changing, should I write a ros subscriber callback function to update the EnvironmentMonitor consistently?

Moveit use a sensor_plugin: occupancy_map_monitor/pointcloudoctomapupdater to update the octomap from pointcloud. Is it possible and how to use the plugin in tesseract?

Thanks! Jiying

xibeisiber avatar Sep 01 '21 06:09 xibeisiber

This is one feature we plan to integrate but the best option at the moment is using a callback to replace the link.

Levi-Armstrong avatar Sep 01 '21 13:09 Levi-Armstrong

@Levi-Armstrong Thanks for your reply. Now I'm using the callback method to create the collision information.

But there is still another problem: the pointcloud from the camera may include the manipulator itself... so do I need to get rid of the points that belong to the manipulater before passing the octomap to tesseract_monitoring::EnvironmentMonitor? or will the monitor do this automatically?

xibeisiber avatar Sep 07 '21 02:09 xibeisiber

@Levi-Armstrong One other practical issue with this is memory usage. In my experience, adding and removing octree links is infeasible because it blows up the command history. Memory usage grows very quickly. At least for my application, we are going to have to either implement the dynamic link or a squash command history functionality to solve this problem. Personally, I think we should probably do both.

mpowelson avatar Sep 07 '21 17:09 mpowelson

I have been thinking about this and it may be better to add the ability to contain a octomap in the planning server and then when a planning request is made it would add a command to the applied to environment adding the octomaps content.

Levi-Armstrong avatar Oct 26 '21 03:10 Levi-Armstrong