-
Notifications
You must be signed in to change notification settings - Fork 61
RJD-1388/follow_trajectory #1449
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
Checklist for reviewers ☑️All references to "You" in the following text refer to the code reviewer.
|
Signed-off-by: Mateusz Palczuk <[email protected]>
… RJD-1388/follow_trajectory Signed-off-by: Mateusz Palczuk <[email protected]>
… RJD-1388/follow_trajectory Signed-off-by: Mateusz Palczuk <[email protected]>
…jectory Signed-off-by: Mateusz Palczuk <[email protected]>
Signed-off-by: Mateusz Palczuk <[email protected]>
…jectory' into RJD-1388/follow_trajectory
… RJD-1388/follow_trajectory
015fe3f
to
8877083
Compare
16b36d9
to
30e865e
Compare
Failure optional scenariosNote This is an experimental check and does not block merging the pull-request. scenario failed: execution_time_test <failure type="SimulationFailure" message="CustomCommandAction typed "exitFailure" was triggered by the named Conditions {"update time checker", "avoid startup"}: {"update time checker": Is the /simulation/interpreter/execution_time/update (= 0.007315000000000000321409565629) is greaterThan 0.005?}, {"avoid startup": Is the simulation time (= 4.249999999999992894572642398998) is greaterThan 1.000000000000000000000000000000?}" /> |
Failure optional scenariosNote This is an experimental check and does not block merging the pull-request. scenario failed: execution_time_test <failure type="SimulationFailure" message="CustomCommandAction typed "exitFailure" was triggered by the named Conditions {"update time checker", "avoid startup"}: {"update time checker": Is the /simulation/interpreter/execution_time/update (= 0.005664999999999999896749258710) is greaterThan 0.005?}, {"avoid startup": Is the simulation time (= 13.600000000000058264504332328215) is greaterThan 1.000000000000000000000000000000?}" /> |
|
|
Description
Abstract
This PR contains refactoring of
follow_trajectory
namespace - in particular themakeUpdatedStatus
function.scenario_simulator_v2/simulation/traffic_simulator/src/behavior/follow_trajectory.cpp
Lines 46 to 583 in 12ff08c
Details
As functionalities have been divided into several files, this namespace now has its own
follow_trajectory
directory containing the following files:Below, these files have been described in detail.
follow_trajectory
File follow_trajectory contains the new entry point of the algorithm, namely the function
follow_trajectory::makeUpdatedEntityStatus
. It replaces the recursion from the originalmakeUpdatedStatus
with a while loop, iterating over the trajectory.scenario_simulator_v2/simulation/traffic_simulator/src/behavior/follow_trajectory/follow_trajectory.cpp
Lines 40 to 59 in 00c3329
validated_entity_status
File validated_entity_status defines
ValidatedEntityStatus
structure, which purpose is to validate the passed-inEntityStatus
and build the updated status based ondesired_local_velocity
.makeUpdatedStatus
.scenario_simulator_v2/simulation/traffic_simulator/src/behavior/follow_trajectory/validated_entity_status.cpp
Lines 38 to 54 in 00c3329
EntityStatus
.scenario_simulator_v2/simulation/traffic_simulator/include/traffic_simulator/behavior/follow_trajectory/validated_entity_status.hpp
Lines 43 to 53 in 00c3329
ValidatedEntityStatus
is passed as an argument tofollow_trajectory::makeUpdatedEntityStatus
.scenario_simulator_v2/simulation/traffic_simulator/src/entity/ego_entity.cpp
Lines 177 to 193 in 00c3329
polyline_trajectory_positioner
File polyline_trajectory_positioner consists of a structure
PolylineTrajectoryPositioner
that is responsible for a single step in the aforementioned while loop.makeUpdatedStatus
function.scenario_simulator_v2/simulation/traffic_simulator/src/behavior/follow_trajectory/polyline_trajectory_positioner.cpp
Lines 35 to 66 in 00c3329
PolylineTrajectoryPositioner::isNearestWaypointReachable
contains the core logic of the previous implementation.scenario_simulator_v2/simulation/traffic_simulator/src/behavior/follow_trajectory/polyline_trajectory_positioner.cpp
Lines 142 to 177 in 00c3329
follow_waypoint_controller
File follow_waypoint_controller remains mostly unchanged, only minor style changes have been made.
References
Regressions TODO