ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Measuring topic reading rate

asked 2020-10-22 05:47:54 -0500

UncleIzzy gravatar image

Hello,

There is a way to measure a ROS topic publishing rate using rostopic hz <topic-name>. Is there a way to measure the topic reading rate by a node?

Thanks, Izzy

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2020-10-22 18:28:42 -0500

No, because the reading rate is the same as the publishing rate. A node cannot choose to ignore some of the inbound messages, at least not at the communication layer. Internally of course it can do whatever it wants with those messages, including ignoring them, but that's node specific and cannot be measured by a general tool.

edit flag offensive delete link more

Comments

Just adding to this answer, if what you want to do is measure how faster your callback is running, you could in the first line get the time, and in the last line count how much time it takes.

Teo Cardoso gravatar image Teo Cardoso  ( 2020-10-22 19:04:05 -0500 )edit

Question Tools

1 follower

Stats

Asked: 2020-10-22 05:47:54 -0500

Seen: 435 times

Last updated: Oct 22 '20