Profile ROS node using Callgrind - AD-EYE/AD-EYE_Core GitHub Wiki
Run the following cmd cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo
To profile with a launch file add on the .launch in the definition of the node :
with children (launch-prefix="valgrind --tool=callgrind --callgrind-out-file='callgrind.manager_children.%p' --trace-children=yes python2") [create a file for each node called] without children (launch-prefix="valgrind --tool=callgrind --callgrind-out-file='callgrind.manager.%p' --trace-children=yes python2" ) [Only one file]
the files are in ~/.ros
To open it : kcachegrind .pid