Apollo 10.0
自动驾驶开放平台
decision.proto
浏览该文件的文档.
1syntax = "proto2";
2
3package apollo.planning;
4
8
9message TargetLane {
10 // lane id
11 optional string id = 1;
12 optional double start_s = 2; // in meters
13 optional double end_s = 3; // in meters
14 optional double speed_limit = 4; // in m/s
15}
16
17message ObjectIgnore {}
18
19enum StopReasonCode {
20 STOP_REASON_HEAD_VEHICLE = 1;
21 STOP_REASON_DESTINATION = 2;
22 STOP_REASON_PEDESTRIAN = 3;
23 STOP_REASON_OBSTACLE = 4;
24 STOP_REASON_PREPARKING = 5;
25 STOP_REASON_SIGNAL = 100; // only for red signal
26 STOP_REASON_STOP_SIGN = 101;
27 STOP_REASON_YIELD_SIGN = 102;
28 STOP_REASON_CLEAR_ZONE = 103;
29 STOP_REASON_CROSSWALK = 104;
30 STOP_REASON_CREEPER = 105;
31 STOP_REASON_REFERENCE_END = 106; // end of the reference_line
32 STOP_REASON_YELLOW_SIGNAL = 107; // yellow signal
33 STOP_REASON_PULL_OVER = 108; // pull over
34 STOP_REASON_SIDEPASS_SAFETY = 109;
35 STOP_REASON_PRE_OPEN_SPACE_STOP = 200;
36 STOP_REASON_LANE_CHANGE_URGENCY = 201;
37 STOP_REASON_EMERGENCY = 202;
38}
39
40message ObjectStop {
41 optional StopReasonCode reason_code = 1;
42 optional double distance_s = 2; // in meters
43 // When stopped, the front center of vehicle should be at this point.
44 optional apollo.common.PointENU stop_point = 3;
45 // When stopped, the heading of the vehicle should be stop_heading.
46 optional double stop_heading = 4;
47 repeated string wait_for_obstacle = 5;
48}
49
50// dodge the obstacle in lateral direction when driving
51message ObjectNudge {
52 enum Type {
53 LEFT_NUDGE = 1; // drive from the left side to nudge a static obstacle
54 RIGHT_NUDGE = 2; // drive from the right side to nudge a static obstacle
55 DYNAMIC_LEFT_NUDGE = 3; // drive from the left side to nudge a dynamic obstacle
56 DYNAMIC_RIGHT_NUDGE = 4; // drive from the right side to nudge a dynamic obstacle
57 };
58 optional Type type = 1;
59 // minimum lateral distance in meters. positive if type = LEFT_NUDGE
60 // negative if type = RIGHT_NUDGE
61 optional double distance_l = 2;
62}
63
64message ObjectYield {
65 optional double distance_s = 1; // minimum longitudinal distance in meters
66 optional apollo.common.PointENU fence_point = 2;
67 optional double fence_heading = 3;
68 optional double time_buffer = 4; // minimum time buffer required after the
69 // obstacle reaches the intersect point.
70}
71
72message ObjectFollow {
73 optional double distance_s = 1; // minimum longitudinal distance in meters
74 optional apollo.common.PointENU fence_point = 2;
75 optional double fence_heading = 3;
76}
77
78message ObjectOvertake {
79 optional double distance_s = 1; // minimum longitudinal distance in meters
80 optional apollo.common.PointENU fence_point = 2;
81 optional double fence_heading = 3;
82 optional double time_buffer = 4; // minimum time buffer required before the
83 // obstacle reaches the intersect point.
84}
85
86message ObjectSidePass {
87 enum Type {
88 LEFT = 1;
89 RIGHT = 2;
90 };
91 optional Type type = 1;
92}
93
94// unified object decision while estop
95message ObjectAvoid {}
96
97message ObjectStatus {
98 optional ObjectMotionType motion_type = 1;
99 optional ObjectDecisionType decision_type = 2;
100}
101
102message ObjectStatic {}
103
104message ObjectDynamic {}
105
106message ObjectMotionType {
107 oneof motion_tag {
108 ObjectStatic static = 1;
109 ObjectDynamic dynamic = 2;
110 }
111}
112
113message ObjectDecisionType {
114 oneof object_tag {
115 ObjectIgnore ignore = 1;
116 ObjectStop stop = 2;
117 ObjectFollow follow = 3;
118 ObjectYield yield = 4;
119 ObjectOvertake overtake = 5;
120 ObjectNudge nudge = 6;
121 ObjectAvoid avoid = 7;
122 ObjectSidePass side_pass = 8;
123 }
124}
125
126message ObjectDecision {
127 optional string id = 1;
128 optional int32 perception_id = 2;
129 repeated ObjectDecisionType object_decision = 3;
130}
131
132message ObjectDecisions {
133 repeated ObjectDecision decision = 1;
134}
135
136message MainStop {
137 optional StopReasonCode reason_code = 1;
138 optional string reason = 2;
139 // When stopped, the front center of vehicle should be at this point.
140 optional apollo.common.PointENU stop_point = 3;
141 // When stopped, the heading of the vehicle should be stop_heading.
142 optional double stop_heading = 4;
143 optional apollo.routing.ChangeLaneType change_lane_type = 5;
144}
145
146message EmergencyStopHardBrake {}
147
148message EmergencyStopCruiseToStop {}
149
150message MainEmergencyStop {
151 // Unexpected event happened, human driver is required to take over
152 enum ReasonCode {
153 ESTOP_REASON_INTERNAL_ERR = 1;
154 ESTOP_REASON_COLLISION = 2;
155 ESTOP_REASON_ST_FIND_PATH = 3;
156 ESTOP_REASON_ST_MAKE_DECISION = 4;
157 ESTOP_REASON_SENSOR_ERROR = 5;
158 }
159 optional ReasonCode reason_code = 1;
160 optional string reason = 2;
161 oneof task {
162 EmergencyStopHardBrake hard_brake = 3; // hard brake
163 EmergencyStopCruiseToStop cruise_to_stop = 4; // cruise to stop
164 }
165}
166
167message MainCruise {
168 // cruise current lane
169 optional apollo.routing.ChangeLaneType change_lane_type = 1;
170}
171
172// This message is deprecated
173message MainChangeLane {
174 enum Type {
175 LEFT = 1;
176 RIGHT = 2;
177 };
178 optional Type type = 1;
179 repeated TargetLane default_lane = 2;
180 optional MainStop default_lane_stop = 3;
181 optional MainStop target_lane_stop = 4;
182}
183
184message MainMissionComplete {
185 // arrived at routing destination
186 // When stopped, the front center of vehicle should be at this point.
187 optional apollo.common.PointENU stop_point = 1;
188 // When stopped, the heading of the vehicle should be stop_heading.
189 optional double stop_heading = 2;
190}
191
192message MainNotReady {
193 // decision system is not ready.
194 // e.g. wait for routing data.
195 optional string reason = 1;
196}
197
198message MainParking {
199 enum ParkingStatus {
200 // TODO(QiL): implement and expand to more enums
201 IN_PARKING = 1;
202 }
203 optional ParkingStatus status = 1;
204}
205
206message MainDecision {
207 oneof task {
208 MainCruise cruise = 1;
209 MainStop stop = 2;
210 MainEmergencyStop estop = 3;
211 MainChangeLane change_lane = 4 [deprecated = true];
212 MainMissionComplete mission_complete = 6;
213 MainNotReady not_ready = 7;
214 MainParking parking = 8;
215 }
216 repeated TargetLane target_lane = 5 [deprecated = true];
217}
218
219message DecisionResult {
220 optional MainDecision main_decision = 1;
221 optional ObjectDecisions object_decision = 2;
222 optional apollo.common.VehicleSignal vehicle_signal = 3;
223}
syntax
Definition decision.proto:1
apollo::common
class register implement
Definition arena_queue.h:37