@@ -0,0 +1,1579 @@
+#!/usr/bin/env python%0A%0A###############################################################################%0A# Copyright 2017 The Apollo Authors. All Rights Reserved.%0A#%0A# Licensed under the Apache License, Version 2.0 (the %22License%22);%0A# you may not use this file except in compliance with the License.%0A# You may obtain a copy of the License at%0A#%0A# http://www.apache.org/licenses/LICENSE-2.0%0A#%0A# Unless required by applicable law or agreed to in writing, software%0A# distributed under the License is distributed on an %22AS IS%22 BASIS,%0A# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.%0A# See the License for the specific language governing permissions and%0A# limitations under the License.%0A###############################################################################%0A%0Aimport rospy%0Afrom std_msgs.msg import String%0Afrom modules.planning.proto.planning_pb2 import ADCTrajectory%0Afrom modules.routing.proto.routing_pb2 import RoutingResponse%0A%0A%0Aclass Extractor(object):%0A%0A    def __init__(self):%0A        self.routing = rospy.Publisher(%0A            '/apollo/routing_response', RoutingResponse, queue_size=1)%0A%0A    def callback_planning(self, data):%0A        self.routing.publish(data.debug.planning_data.routing)%0A        print %22New Planning%22%0A%0A%0Adef main():%0A    %22%22%22%0A    Main function%0A    %22%22%22%0A    extract = Extractor()%0A    rospy.init_node('extract_routing', anonymous=True)%0A    planning_sub = rospy.Subscriber(%0A        '/apollo/planning',%0A        ADCTrajectory,%0A        extract.callback_planning,%0A        queue_size=1)%0A    rospy.spin()%0A%0A%0Aif __name__ == '__main__':%0A    main()%0A

Add tool to extract routing from planning debug