0
$\begingroup$

Rosanswers logo

I am trying to understand the reason for an extreme slowdown in visualization of the turtlebot view.

I am very new to ROS. I have a recently assembled turtlebot that I can tele-operate. It took me some time to figure out how to launch its 3d camera (Orbbec Astra); I only managed to do it by installing astra_camera and astra_launch packages. I am now trying to visualize what the robot sees using rviz. After launching the camera on the robot (roslaunch astra_launch astra.launch) I launch rviz on the workstation: roslaunch turtlebot_rviz_launchers view_robot.launch.

The problem is that visualization works extremely slow. I only tried Image and DepthCloud. Visualization starts with just a few frames per second, quickly degrading to less than a frame per second, then freezing. Occasionally unfreezing to show a few frames, then freezing again. DepthCloud is probably even worse than Image.

It seems to me there is some problem in communication between the workstation and turtlebot. I observed what happens to ping readings when I use rviz. When there is no stream of data (Image and DepthCloud are unchecked in rviz), everything is fine, ping time is in order of milliseconds, and I have no problem tele-operating the robot. When I turn on the data stream (check Image or DepthCloud), ping time quickly climbs to hundreds or thousands of milliseconds, rviz shows something, then freezes for sometime, like I described above. At this point I either cannot control the bot via teleop, or there is a lag of up to many seconds. If I interrupt the data stream by unchecking corresponding boxes in rviz, everything comes back to normal and I can teleop again.

Can somebody help me understand this behavior and how it can be fixed? I have ubuntu 14.04, ROS-indigo. The turtlebot is new, and the workstation is not very old.


Originally posted by underactuated on ROS Answers with karma: 18 on 2017-07-21

Post score: 0

$\endgroup$

1 Answer 1

0
$\begingroup$

Rosanswers logo

I partially resolved my issue. When displaying the camera feed in RViz, I had to choose appropriate settings for the Transports hints. Namely, I had to switch from raw to compressed, or compressedDepth (for the DepthCloud). This setting affects which topic rviz subscribes to. For example, if you are displaying Image, and Transport Hint is set to raw, rviz will subscribe to /camera/rgb/image_rect_color; while if Transport Hint is set to compressed, rviz will subscribe to /camera/rgb/image_rect_color/compressed. I guess the compressed stream transmits much faster. You can also verify with 'rostopic hz' command that the publishing rate for the compressed topic is substantially higher.

Perhaps it was a trivial issue, but as I said I am new to ROS.


Originally posted by underactuated with karma: 18 on 2017-07-23

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.