Skip to content
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

feat(lane_change): using frenet planner to generate lane change path when ego near terminal #9767

Open
wants to merge 19 commits into
base: main
Choose a base branch
from

Conversation

zulfaqar-azmi-t4
Copy link
Contributor

@zulfaqar-azmi-t4 zulfaqar-azmi-t4 commented Dec 24, 2024

Description

This PR adds frenet planner to generate candidate path when ego is near terminal.

Related launcher's PR. autowarefoundation/autoware_launch#1290

Related links

Parent Issue:

  • Link

How was this PR tested?

  1. PSIM
  2. Evaluator TIER IV Internal link

Notes for reviewers

None.

ROS Parameter Changes

Additions and removals

Change type Parameter Name Type Default Value Description
Added trajectory.th_prepare_curvature double 0.03 If the maximum curvature of the prepare segment exceeds the threshold, the prepare segment is invalid.
Added frenet.enable bool 0.03 Enable frenet planner if ego is near terminal start.
Added frenet.th_yaw_diff bool 10.0 If the yaw diff between of the prepare segment's end and lane changing segment's start exceed the threshold , the lane changing segment is invalid.
Added frenet.th_curvature_smoothing bool 0.1 Filters and appends target path points with curvature below the threshold to candidate path.

Effects on system behavior

None.

@github-actions github-actions bot added the component:planning Route planning, decision-making, and navigation. (auto-assigned) label Dec 24, 2024
Copy link

github-actions bot commented Dec 24, 2024

Thank you for contributing to the Autoware project!

🚧 If your pull request is in progress, switch it to draft mode.

Please ensure:

@zulfaqar-azmi-t4 zulfaqar-azmi-t4 force-pushed the RT1-5068-lane-change-frenet branch 2 times, most recently from 4cae773 to 11e2774 Compare December 25, 2024 10:45
@zulfaqar-azmi-t4 zulfaqar-azmi-t4 changed the title frenet planner feat(lane_change): using frenet planner to generate lane change path when ego near terminal Dec 26, 2024
@zulfaqar-azmi-t4 zulfaqar-azmi-t4 marked this pull request as ready for review December 26, 2024 04:28
@zulfaqar-azmi-t4 zulfaqar-azmi-t4 force-pushed the RT1-5068-lane-change-frenet branch 3 times, most recently from 66b4fe2 to 881afe1 Compare December 27, 2024 02:02
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
@zulfaqar-azmi-t4 zulfaqar-azmi-t4 force-pushed the RT1-5068-lane-change-frenet branch from 6453e15 to 3253f79 Compare January 5, 2025 23:24
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
@github-actions github-actions bot added the type:documentation Creating or refining documentation. (auto-assigned) label Jan 6, 2025
@zulfaqar-azmi-t4 zulfaqar-azmi-t4 added the run:deploy-docs Mark for deploy-docs action generation. (used-by-ci) label Jan 6, 2025
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
@@ -906,6 +939,7 @@ The following parameters are configurable in [lane_change.param.yaml](https://gi
| `trajectory.max_longitudinal_acc` | [m/s2] | double | maximum longitudinal acceleration for lane change | 1.0 |
| `trajectory.min_longitudinal_acc` | [m/s2] | double | maximum longitudinal deceleration for lane change | -1.0 |
| `trajectory.lane_changing_decel_factor` | [-] | double | longitudinal deceleration factor during lane changing phase | 0.5 |
| `trajectory.th_prepare_curvature` | [-] | double | If the maximum curvature of the prepare segment exceeds the threshold, the prepare segment is invalid. | 0.03 |
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm unsure about the use of this parameter, prepare segment is usually just a section of the current reference path, so why would it have invalid curvature?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes it might when the lanelet itself have high curvature.|
For example
image

const LineString2d & lane_boundary, const bool shift_to_left)
{
const auto distance = (0.5 * common_data_ptr->bpp_param_ptr->vehicle_width + 0.1);
const auto offset = (shift_to_left ? 1.0 : -1.0) * distance; // invert direction
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

why not use sign() function from here

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done 999cf89


std::vector<lane_change::TrajectoryGroup> generate_frenet_candidates(
const CommonDataPtr & common_data_ptr, const PathWithLaneId & prev_module_path,
const std::vector<LaneChangePhaseMetrics> & metrics)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

better to specify prep_metrics

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done 7037ea0

Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
Signed-off-by: Zulfaqar Azmi <zulfaqar.azmi@tier4.jp>
@zulfaqar-azmi-t4 zulfaqar-azmi-t4 added the run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci) label Jan 6, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:planning Route planning, decision-making, and navigation. (auto-assigned) run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci) run:deploy-docs Mark for deploy-docs action generation. (used-by-ci) type:documentation Creating or refining documentation. (auto-assigned)
Projects
Status: To Triage
Development

Successfully merging this pull request may close these issues.

3 participants