3 from jsk_recognition_msgs.msg
import BoundingBoxArray
4 from jsk_topic_tools
import ConnectionBasedTransport
11 super(AddBoundingBoxArray, self).
__init__()
12 self.
_pub = self.advertise(
'~output', BoundingBoxArray, queue_size=1)
15 topics = rospy.get_param(
'~topics')
20 use_async = rospy.get_param(
'~approximate_sync',
False)
21 queue_size = rospy.get_param(
'~queue_size', 100)
23 slop = rospy.get_param(
'~slop', 0.1)
24 sync = message_filters.ApproximateTimeSynchronizer(
25 self.
subs, queue_size, slop)
35 out_msg = BoundingBoxArray()
36 out_msg.header = bboxes_msgs[0].header
37 for bboxes_msg
in bboxes_msgs:
38 out_msg.boxes.extend(bboxes_msg.boxes)
39 self._pub.publish(out_msg)
42 if __name__ ==
'__main__':
43 rospy.init_node(
'add_bounding_box_array')
def _decompose(self, bboxes_msgs)