Open TomCC7 opened 1 year ago
Current control process
steering_control
Possible refactor plan: decision tree for each vehicle
Scenario
object and loaded into behavior treeAtomic Behavior
which executes corresponding commandThe parser is separated into several stages:
It uses Behavior Tree and a corresponding lib called py-trees to compose scenarios. An example from scenario runner is displayed below:
[-] behavior
(o) behavior
(-) ParametersInit
--> InitialParameterSettings Done?
[-] OneShot
(o) ParametersInit
--> Mark Done
(-) EnvironmentBehavior
--> InitialEnvironmentSettings Done?
[-] OneShot
(o) EnvironmentBehavior
(-) ChangeWeather
--> InitialWeather Done?
[-] OneShot
--> ChangeWeather
--> Mark Done
(-) ChangeRoadFriction
--> InitRoadFriction Done?
[-] OneShot
--> ChangeRoadFriction
--> Mark Done
--> Mark Done
(-) InitBehaviour
--> InitialActorSettings Done?
[-] OneShot
(o) InitBehaviour
[-] InitActoradversary
--> ChangeActorControl
[-] InitActorstanding
--> ChangeActorControl
[-] InitActorhero
--> ChangeActorControl
--> Mark Done
(o) OSCStories
(-) MyStory
--> >MyStory Done?
[-] OneShot
(o) MyStory
[-] Act StartConditions and behaviours
(o) StartConditions Group
(o) StartConditions
(o) Condition Group
(-) OverallStartCondition
--> Behavior>None>None>OverallStartCondition Done?
[-] OneShot
--> OverallStartCondition
--> Mark Done
(-) SimulationTimeCondition
--> Behavior>None>None>StartTime Done?
[-] OneShot
--> SimulationTimeCondition
--> Mark Done
(o) Maneuver + EndConditions Group
--> Maneuvers
(o) Maneuvers
(-) ManeuverSequence
--> Behavior>ManeuverSequence Done?
[-] ManeuverSequence
[-] RepeatableBehaviour of Behavior>ManeuverSequence
--> ManeuverSequence
(o) ManeuverSequence
(-) Maneuver LaneChangeSimpleManeuver
--> Behavior>ManeuverSequence>LaneChangeSimpleManeuver Done?
[-] OneShot
--> Maneuver LaneChangeSimpleManeuver
(o) Maneuver LaneChangeSimpleManeuver
(-) Event AdversaryAccelerates
--> Behavior>ManeuverSequence>AdversaryAccelerates Done?
[-] Event AdversaryAccelerates
(o) Parallel Condition Groups
(o) Condition Group
(-) StartCondition
--> Behavior>ManeuverSequence>AdversaryAccelerates>None>None>StartCondition Done?
[-] OneShot
--> StartCondition
--> Mark Done
--> Actions
(o) Actions
(-) AdversaryAccelerates
--> Behavior>ManeuverSequence>AdversaryAccelerates>AdversaryAccelerates>0 Done?
[-] OneShot
--> AdversaryAccelerates
--> AdversaryAccelerates
--> Mark Done
--> Mark Done
(-) Event AdversaryChangesLane
--> Behavior>ManeuverSequence>AdversaryChangesLane Done?
[-] Event AdversaryChangesLane
(o) Parallel Condition Groups
(o) Condition Group
(-) completeStateCondition
--> Behavior>ManeuverSequence>AdversaryChangesLane>None>None>AfterAdversaryAccelerates Done?
[-] OneShot
--> completeStateCondition
--> Mark Done
--> Actions
(o) Actions
(-) AdversaryChangesLane
--> Behavior>ManeuverSequence>AdversaryChangesLane>AdversaryChangesLane>0 Done?
[-] OneShot
--> AdversaryChangesLane
--> AdversaryChangesLane
--> Mark Done
--> Mark Done
--> Mark Done
--> Clear Descendant Variables of Behavior>ManeuverSequence
--> Mark Done
(o) EndConditions
(o) Condition Group
(-) EndCondition
--> Behavior>None>None>EndCondition Done?
[-] OneShot
--> EndCondition
--> Mark Done
--> Mark Done
--> TimeOut
--> WeatherBehavior
--> UpdateAllActorControls
(o) EndConditions (Criteria Group)
(o) Evaluation Criteria for multiple ego vehicles
--> RunningStopTest
(o) Evaluation Criteria for multiple ego vehicles
--> RunningRedLightTest
(o) Evaluation Criteria for multiple ego vehicles
--> WrongLaneTest
(o) Evaluation Criteria for multiple ego vehicles
--> OnSidewalkTest
(o) Evaluation Criteria for multiple ego vehicles
--> CheckKeepLane
(o) Evaluation Criteria for multiple ego vehicles
--> CollisionTest
(o) Evaluation Criteria for multiple ego vehicles
--> CheckDrivenDistance
Task Description
The current vehicle planning & control code is a bit messy and hard to extend. As we are going to add new features and more vehicle behaviors, it's time to refactor and improve the planning code.
Subtasks: