4 from dwb_msgs.msg
import LocalPlanEvaluation
7 print '\n\n=====================================================\n\n' 8 for i
in [msg.best_index, msg.worst_index]:
9 print 'Name | Raw | Scale | Scaled Score' 10 print '---------------------|--------|--------|-------------' 11 for s
in msg.twists[i].scores:
12 print '{:20} | {:6.2f} | {:6.2f} | {:12.2f}'.format(s.name, s.raw_score, s.scale, s.raw_score * s.scale)
13 print '--------------------------------------- total: {:6.2f}'.format(msg.twists[i].total)
18 rospy.init_node(
'print_dwb_scores', anonymous=
True)
19 rospy.Subscriber(
'move_base_node/DWBLocalPlanner/evaluation', LocalPlanEvaluation, eval_cb)
20 rospy.loginfo(
'print_dwb_scores ready.')
24 if __name__ ==
'__main__':