Skip to content

Commit

Permalink
refactor(autoware_launch): organize arguments for planning (autowaref…
Browse files Browse the repository at this point in the history
…oundation#165)

* refactor(tier4_planning_launch): organize arguments

Signed-off-by: Takayuki Murooka <[email protected]>

* update

Signed-off-by: Takayuki Murooka <[email protected]>

Signed-off-by: Takayuki Murooka <[email protected]>
  • Loading branch information
takayuki5168 authored Jan 18, 2023
1 parent 7d393a7 commit 39a3b28
Show file tree
Hide file tree
Showing 6 changed files with 301 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
/**:
ros__parameters:
planning_hz: 10.0
backward_path_length: 5.0
forward_path_length: 300.0
backward_length_buffer_for_end_of_lane: 5.0
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
<?xml version="1.0"?>
<root main_tree_to_execute="BehaviorTree">
<!-- ////////// -->
<BehaviorTree ID="BehaviorTree">
<Fallback>
<ReactiveSequence>
<Condition ID="PullOver_Request"/>
<Action ID="PullOver_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="PullOut_Request"/>
<Action ID="PullOut_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="SideShift_Request"/>
<Action ID="SideShift_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="LaneChange_Request"/>
<Action ID="LaneChange_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="Avoidance_Request"/>
<Action ID="Avoidance_Plan" output="{output}"/>
</ReactiveSequence>
<Action ID="LaneFollowing_Plan" output="{output}"/>
</Fallback>
</BehaviorTree>
<!-- ////////// -->
<BehaviorTree ID="a">
<ReactiveFallback>
<Condition ID="LaneChange_CheckApproval"/>
<KeepRunningUntilFailure>
<Action ID="LaneChange_PlanCandidate" output="{output}"/>
</KeepRunningUntilFailure>
</ReactiveFallback>
</BehaviorTree>
<!-- ////////// -->
<BehaviorTree ID="b">
<ReactiveFallback>
<Condition ID="Avoidance_CheckApproval"/>
<KeepRunningUntilFailure>
<Action ID="Avoidance_PlanCandidate" output="{output}"/>
</KeepRunningUntilFailure>
</ReactiveFallback>
</BehaviorTree>
<!-- ////////// -->
<TreeNodesModel>
<Condition ID="Avoidance_CheckApproval"/>
<Action ID="Avoidance_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="Avoidance_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="Avoidance_Request"/>
<Condition ID="ExternalApproval"/>
<Condition ID="LaneChange_CheckApproval"/>
<Action ID="LaneChange_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="LaneChange_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="LaneChange_Request"/>
<Action ID="LaneFollowing_Plan">
<output_port name="output" type="boost::optional&lt;tier4_planning_msgs::PathWithLaneId_&lt;std::allocator&lt;void&gt; &gt; &gt;">desc</output_port>
</Action>
<Action ID="LaneFollowing_PlanCandidate">
<output_port name="output_candidate" type="boost::optional&lt;tier4_planning_msgs::PathWithLaneId_&lt;std::allocator&lt;void&gt; &gt; &gt;">desc</output_port>
</Action>
<Condition ID="LaneFollowing_Request"/>
<Action ID="PullOut_Plan">
<output_port name="output"/>
</Action>
<Condition ID="PullOut_Request"/>
<Action ID="PullOver_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="PullOver_Request"/>
<Condition ID="SideShift_CheckApproval"/>
<Action ID="SideShift_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="SideShift_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="SideShift_Request"/>
<SubTree ID="SubTree"/>
<SubTree ID="a"/>
<SubTree ID="b"/>
</TreeNodesModel>
<!-- ////////// -->
</root>
Original file line number Diff line number Diff line change
@@ -0,0 +1,86 @@
<?xml version="1.0"?>
<root main_tree_to_execute="BehaviorTree">
<!-- ////////// -->
<BehaviorTree ID="BehaviorTree">
<Fallback>
<ReactiveSequence>
<Condition ID="PullOver_Request"/>
<Action ID="PullOver_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="PullOut_Request"/>
<Action ID="PullOut_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="LaneChange_Request"/>
<Action ID="LaneChange_Plan" output="{output}"/>
</ReactiveSequence>
<Action ID="LaneFollowing_Plan" output="{output}"/>
</Fallback>
</BehaviorTree>
<!-- ////////// -->
<BehaviorTree ID="a">
<ReactiveFallback>
<Condition ID="LaneChange_CheckApproval"/>
<KeepRunningUntilFailure>
<Action ID="LaneChange_PlanCandidate" output="{output}"/>
</KeepRunningUntilFailure>
</ReactiveFallback>
</BehaviorTree>
<!-- ////////// -->
<BehaviorTree ID="b">
<ReactiveFallback>
<Condition ID="Avoidance_CheckApproval"/>
<KeepRunningUntilFailure>
<Action ID="Avoidance_PlanCandidate" output="{output}"/>
</KeepRunningUntilFailure>
</ReactiveFallback>
</BehaviorTree>
<!-- ////////// -->
<TreeNodesModel>
<Condition ID="Avoidance_CheckApproval"/>
<Action ID="Avoidance_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="Avoidance_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="Avoidance_Request"/>
<Condition ID="ExternalApproval"/>
<Condition ID="LaneChange_CheckApproval"/>
<Action ID="LaneChange_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="LaneChange_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="LaneChange_Request"/>
<Action ID="LaneFollowing_Plan">
<output_port name="output" type="boost::optional&lt;tier4_planning_msgs::PathWithLaneId_&lt;std::allocator&lt;void&gt; &gt; &gt;">desc</output_port>
</Action>
<Action ID="LaneFollowing_PlanCandidate">
<output_port name="output_candidate" type="boost::optional&lt;tier4_planning_msgs::PathWithLaneId_&lt;std::allocator&lt;void&gt; &gt; &gt;">desc</output_port>
</Action>
<Condition ID="LaneFollowing_Request"/>
<Action ID="PullOut_Plan">
<output_port name="output"/>
</Action>
<Condition ID="PullOut_Request"/>
<Action ID="PullOver_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="PullOver_Request"/>
<Condition ID="SideShift_CheckApproval"/>
<Action ID="SideShift_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="SideShift_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="SideShift_Request"/>
<SubTree ID="SubTree"/>
<SubTree ID="a"/>
<SubTree ID="b"/>
</TreeNodesModel>
<!-- ////////// -->
</root>
Original file line number Diff line number Diff line change
@@ -0,0 +1,100 @@
<?xml version="1.0"?>
<root main_tree_to_execute="BehaviorTree">
<!-- ////////// -->
<BehaviorTree ID="BehaviorTree">
<Fallback>
<ReactiveSequence>
<Condition ID="PullOver_Request"/>
<Condition ID="PullOver_Ready"/>
<Action ID="PullOver_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="PullOut_Request"/>
<Condition ID="PullOut_Ready"/>
<Action ID="PullOut_Plan" output="{output}"/>
</ReactiveSequence>
<ReactiveSequence>
<Condition ID="LaneChange_Request"/>
<Fallback>
<Condition ID="LaneChange_Ready"/>
<Condition ID="ForceLaneChange_ForceApproval"/>
</Fallback>
<Action ID="LaneChange_Plan" output="{output}"/>
</ReactiveSequence>
<Action ID="LaneFollowing_Plan" output="{output}"/>
</Fallback>
</BehaviorTree>
<!-- ////////// -->
<BehaviorTree ID="a">
<ReactiveFallback>
<Condition ID="LaneChange_CheckApproval"/>
<KeepRunningUntilFailure>
<Action ID="LaneChange_PlanCandidate" output="{output}"/>
</KeepRunningUntilFailure>
</ReactiveFallback>
</BehaviorTree>
<!-- ////////// -->
<BehaviorTree ID="b">
<ReactiveFallback>
<Condition ID="Avoidance_CheckApproval"/>
<KeepRunningUntilFailure>
<Action ID="Avoidance_PlanCandidate" output="{output}"/>
</KeepRunningUntilFailure>
</ReactiveFallback>
</BehaviorTree>
<!-- ////////// -->
<TreeNodesModel>
<Condition ID="Avoidance_CheckApproval"/>
<Action ID="Avoidance_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="Avoidance_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="Avoidance_Ready"/>
<Condition ID="Avoidance_Request"/>
<Condition ID="ExternalApproval"/>
<Condition ID="ForceApproval"/>
<Condition ID="ForceLaneChange_ForceApproval"/>
<Condition ID="LaneChange_CheckApproval"/>
<Action ID="LaneChange_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="LaneChange_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="LaneChange_Ready"/>
<Condition ID="LaneChange_Request"/>
<Action ID="LaneFollowing_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="LaneFollowing_PlanCandidate">
<output_port name="output_candidate" type="boost::optional&lt;tier4_planning_msgs::PathWithLaneId_&lt;std::allocator&lt;void&gt; &gt; &gt;">desc</output_port>
</Action>
<Condition ID="LaneFollowing_Ready"/>
<Condition ID="LaneFollowing_Request"/>
<Action ID="PullOut_Plan">
<output_port name="output"/>
</Action>
<Condition ID="PullOut_Ready"/>
<Condition ID="PullOut_Request"/>
<Action ID="PullOver_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="PullOver_Ready"/>
<Condition ID="PullOver_Request"/>
<Condition ID="SideShift_CheckApproval"/>
<Action ID="SideShift_Plan">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Action ID="SideShift_PlanCandidate">
<output_port name="output" type="behavior_path_planner::BehaviorModuleOutput">desc</output_port>
</Action>
<Condition ID="SideShift_Ready"/>
<Condition ID="SideShift_Request"/>
<SubTree ID="SubTree"/>
<SubTree ID="a"/>
<SubTree ID="b"/>
</TreeNodesModel>
<!-- ////////// -->
</root>
8 changes: 8 additions & 0 deletions autoware_launch/launch/autoware.launch.xml
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,14 @@
<arg name="vehicle_param_file" value="$(find-pkg-share $(var vehicle_model)_description)/config/vehicle_info.param.yaml"/>
<arg name="use_pointcloud_container" value="$(var use_pointcloud_container)"/>
<arg name="pointcloud_container_name" value="$(var pointcloud_container_name)"/>
<arg
name="behavior_path_planner_tree_param_path"
value="$(find-pkg-share autoware_launch)/config/planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/behavior_path_planner_tree.xml"
/>
<arg name="cruise_planner_type" value="obstacle_stop_planner"/>
<arg name="enable_fully_automated_lane_change" value="false"/>
<arg name="use_surround_obstacle_check" value="true"/>
<arg name="smoother_type" value="JerkFiltered"/>
</include>
</group>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,13 @@
<arg name="vehicle_param_file"/>
<arg name="use_pointcloud_container"/>
<arg name="pointcloud_container_name"/>
<arg name="smoother_type" default="JerkFiltered" description="options: JerkFiltered, L2, Analytical, Linf(Unstable)"/>
<!-- behavior -->
<arg name="behavior_path_planner_tree_param_path"/>
<!-- motion -->
<arg name="cruise_planner_type" description="options: obstacle_stop_planner, obstacle_cruise_planner, none"/>
<arg name="use_surround_obstacle_check"/>
<arg name="smoother_type" description="options: JerkFiltered, L2, Analytical, Linf(Unstable)"/>
<arg name="enable_fully_automated_lane_change" default="false"/>

<include file="$(find-pkg-share tier4_planning_launch)/launch/planning.launch.xml">
<arg name="vehicle_param_file" value="$(var vehicle_param_file)"/>
Expand Down Expand Up @@ -41,6 +47,7 @@
name="drivable_area_expansion_param_path"
value="$(find-pkg-share autoware_launch)/config/planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/drivable_area_expansion.param.yaml"
/>
<arg name="behavior_path_planner_tree_param_path" value="$(var behavior_path_planner_tree_param_path)"/>
<arg
name="behavior_path_planner_param_path"
value="$(find-pkg-share autoware_launch)/config/planning/scenario_planning/lane_driving/behavior_planning/behavior_path_planner/behavior_path_planner.param.yaml"
Expand Down Expand Up @@ -104,6 +111,10 @@
name="obstacle_cruise_planner_param_path"
value="$(find-pkg-share autoware_launch)/config/planning/scenario_planning/lane_driving/motion_planning/obstacle_cruise_planner/obstacle_cruise_planner.param.yaml"
/>
<arg name="cruise_planner_type" value="$(var cruise_planner_type)"/>
<arg name="use_surround_obstacle_check" value="$(var use_surround_obstacle_check)"/>
<arg name="enable_fully_automated_lane_change" value="$(var enable_fully_automated_lane_change)"/>
<arg name="smoother_type" value="$(var smoother_type)"/>

<!-- motion velocity smoother -->
<arg name="motion_velocity_smoother_param_path" value="$(find-pkg-share autoware_launch)/config/planning/scenario_planning/common/motion_velocity_smoother/motion_velocity_smoother.param.yaml"/>
Expand Down

0 comments on commit 39a3b28

Please sign in to comment.