[ros-users] [Discourse.ros.org] [Next Generation ROS] Image and PointCloud2 performance on ROS2

Chris Ye ros.discourse at gmail.com
Tue Jul 17 11:07:05 UTC 2018



When I try to use big data message by python code such as Camera Image or PointCloud2 on ROS2, I found the performance is terrible.

Problem:
1. Launch [ros2_intel_realsense](https://github.com/intel/ros2_intel_realsense) by realsense_ros2_camera, and subscribe "/camera/depth/color/points" by "ros2 topic echo /camera/depth/color/points". It will cost dozens of seconds to print out the PointCloud2 (640x480) data. On ros 1, rostopic shows data immediately.
2. When write example code to subscribe "/camera/depth/color/points(sensor_msgs::msgs::PointCloud2)"  by both cpp subscribe api and python subscribe code, the fps is different. cpp-code is 4hz, but python-code only 0.4hz.

Debugging point to the time exhaust in the function convert_to_py while convert msg to python, in [_rclpy.c](https://github.com/ros2/rclpy/blob/master/rclpy/src/rclpy/_rclpy.c):2261

Is there any idea about fixing this performance issue? to make python support Camera messages converting well.





---
[Visit Topic](https://discourse.ros.org/t/image-and-pointcloud2-performance-on-ros2/5391/1) or reply to this email to respond.




More information about the ros-users mailing list