提交 1677090e 编写于 作者: J Jiangtao Hu 提交者: Yifei Jiang

fix perception topic name and publish by pb directly.

上级 cd5f0875
......@@ -5,6 +5,7 @@ CONTROL control_cmd_pb2.ControlCommand() /apollo/control 10
LOCALIZATION localization_pb2.LocalizationEstimate() /apollo/localization/pose 10
MONITOR monitor_pb2.MonitorMessage() /apollo/monitor 10
PLANNING planning_pb2.ADCTrajectory() /apollo/planning 200
PERCEPTION perception_obstacle_pb2.PerceptionObstacles() /apollo/perception/obstacles 200
Pad pad_msg_pb2.PadMessage() /apollo/control/pad 500
Odometry gps_pb2.Gps() /apollo/sensor/gnss/odometry 10
IMU imu_pb2.Imu() /apollo/sensor/gnss/corrected_imu 10
......@@ -217,9 +217,7 @@ def perception_publisher(perception_topic, files, period):
while not rospy.is_shutdown():
perception = generate_perception(perception_description, perception)
print str(perception)
s = String()
s.data = perception.SerializeToString()
pub.publish(s)
pub.publish(perception)
rate.sleep()
......@@ -228,7 +226,7 @@ if __name__ == '__main__':
prog="replay_perception.py")
parser.add_argument("files", action="store", type=str, nargs="*",
help="obstacle description files")
parser.add_argument("-t", "--topic", action="store", type=str, default="/perception/obstacles",
parser.add_argument("-t", "--topic", action="store", type=str, default="/apollo/perception/obstacles",
help="set the perception topic")
parser.add_argument("-p", "--period", action="store", type=float, default=0.1,
help="set the perception topic publish time duration")
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册