Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include option to use PointCloud Transport #4042

Open
SteveMacenski opened this issue Jan 9, 2024 · 11 comments
Open

Include option to use PointCloud Transport #4042

SteveMacenski opened this issue Jan 9, 2024 · 11 comments
Labels
enhancement New feature or request good first issue Good for newcomers gsoc

Comments

@SteveMacenski
Copy link
Member

Per https://github.com/ros-perception/point_cloud_transport, we can now use compressed pointcloud streams in ROS 2. We can enable those in the Costmap layers that ingest pointcloud sensor streams (i.e. obstacle, voxel) and the collision monitor and show that this reduces network traffic without composed nodes to keep up better (and CPU impacts).

We would want sensor drivers and depth pipelines to have the option to output this as well to be able to ingest in Nav2 out of the box. Rviz2 + Gazebo would be ideal as well to publish PC2 from Gazebo into Rviz without as much latency

CC @ahcorde

@SteveMacenski SteveMacenski changed the title Include option to use PointCloud Transport in Costmap2D Include option to use PointCloud Transport Jan 9, 2024
@SteveMacenski SteveMacenski added good first issue Good for newcomers enhancement New feature or request labels Aug 21, 2024
@Combuster54
Copy link

Hi, could you provide more info? I would like to contribute if it´s possible.

@xFranv8
Copy link

xFranv8 commented Sep 25, 2024

I'm taking this issue. Thanks!

@SteveMacenski
Copy link
Member Author

@xFranv8 any updates?

@SteveMacenski
Copy link
Member Author

Do they need lifecycle support if we create them in the configure / activate methods of our lifecycle servers? Note in Costmap2D we use Message Filters, which has an unsubscsribe/subscribe option -- I'm not sure if/how you can or should use both message filters and image / PC2 transport, but I imagine you can by daisy chaining callbacks. If so, then that unsubscribe/subscribe feature would give you virtual lifecycle support for our needs here, even if not supported by those libraries.

Optionally: you could choose to implement it in the transport pipelines as part of this ticket, I'm sure the maintainers would love the help and further have impact in the community! But, I don't think it is largely necessary, since the transports are used within costmap layers or within operations that themselves are happening in lifecycle transitions. We don't try to make the subscribers until we're in the configure state (though between configure and activate... the message filters subscribe resolves that for us for now -- if we can daisy chain and use both; don't return callback until a TF transform exists and use the compression pipelines)

@elsayedelsheikh
Copy link

elsayedelsheikh commented Jan 23, 2025

Perfect!
Moving on with PCL Transport SubscriberFilter variant for the Obstacle layer
Thanks :)

Edit:

TODO:

Pre

Main

  • obstacle_layer/voxel_layer plugins
  • STVL/NPVL plugins
  • collision_monitor node

Performance Evaluation

Metrics ? (Bandwidth/DataQuality/Frequency/Latency/CPU&MemoryUsage)

Wrap-up

  • Documentation update: transport method with default "raw"
  • Migration guide
  • Quick tutorial on usage

@SteveMacenski
Copy link
Member Author

Conveniently, the voxel layer uses the obstacle layer's base for subscriptions, so its a 2 for 1!

I think also STVL/NPVL would be good as well, while you're at it!

Add transport method parameter with "raw" as default ?

I think that would be good

Also add into your tasks for documentation updates to the layer's configuration file, migration guide, and best yet if you wanted to write a quick tutorial about how to use it (and some metrics about how it improves performance - possibly?)

@DasariChaitanya
Copy link

Hi everyone,

I've been working on this topic for a few days now and didn't realize others were also on it. I should have posted earlier. I have not noticed there's a Subscribe Filter variant in PCL transport that might be a better implementation than what I'm currently using.

@elsayedelsheikh, let me know if you'd like any assistance.

@elsayedelsheikh
Copy link

elsayedelsheikh commented Jan 24, 2025

Sounds good!

@DasariChaitanya
Let’s catch up on the progress and work on this together - there’s a lot to do/test.
Hopefully, we can wrap it up by next weekend! 💯

Edit:
For the publishers, which are you following?

  1. Use all available transports for output
  2. Load specific transport plugin

Check point_cloud_transport_republisher

One additional PointCloud2 publisher in nav2_dwb_controller which publishes the CostGrid

std::shared_ptr<LifecyclePublisher<sensor_msgs::msg::PointCloud2>> cost_grid_pc_pub_;

@elsayedelsheikh
Copy link

Hi @DasariChaitanya
If you're still up for this, I could use some help 😁
Check the updated TODO list

@DasariChaitanya
Copy link

Hi @elsayedelsheikh
Yes, let's get started on the tasks.

  1. Did we open an issue for the lifecycle node support for point_cloud_transport?
  2. Another potential issue I came across was the subscriber vector class is not compatible with class of PCL Transport SubscriberFilter variant
  3. I have not looked at publishers yet. But I think it would be better to use all available transports for outputs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers gsoc
Projects
None yet
Development

No branches or pull requests

5 participants