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

fix(motion_velocity_smoother): fix terminal velocity optimization #2989

Merged
merged 3 commits into from
Mar 2, 2023

Conversation

purewater0901
Copy link
Contributor

@purewater0901 purewater0901 commented Mar 2, 2023

Description

Before this PR, motion velocity smoother computes optimal velocity with the terminal velocity = 0.1[m/s] even though we set the terminal velocity as 0.0[m/s]. This is caused by a inappropriate terminal velocity approximation in the optimization setting. In this PR, I fixed it by ignoring the terminal decision variable when the v_max is less than 0.01[m/s].

  • Before the PR
[motion_velocity_smoother-26] v[0]: 0.25
[motion_velocity_smoother-26] v[1]: 0.287228
[motion_velocity_smoother-26] v[2]: 0.409081
[motion_velocity_smoother-26] v[3]: 0.544225
[motion_velocity_smoother-26] v[4]: 0.676198
[motion_velocity_smoother-26] v[5]: 0.802665
[motion_velocity_smoother-26] v[6]: 0.918985
[motion_velocity_smoother-26] v[7]: 1.02216
[motion_velocity_smoother-26] v[8]: 1.11583
[motion_velocity_smoother-26] v[9]: 1.20223
[motion_velocity_smoother-26] v[10]: 1.28282
[motion_velocity_smoother-26] v[11]: 3.13065
[motion_velocity_smoother-26] v[12]: 4.23153
[motion_velocity_smoother-26] v[13]: 5.09729
[motion_velocity_smoother-26] v[14]: 5.83432
[motion_velocity_smoother-26] v[15]: 6.487
[motion_velocity_smoother-26] v[16]: 7.07891
[motion_velocity_smoother-26] v[17]: 7.62433
[motion_velocity_smoother-26] v[18]: 8.13246
[motion_velocity_smoother-26] v[19]: 8.43285
[motion_velocity_smoother-26] v[20]: 8.50078
[motion_velocity_smoother-26] v[21]: 8.35221
[motion_velocity_smoother-26] v[22]: 7.97319
[motion_velocity_smoother-26] v[23]: 7.45419
[motion_velocity_smoother-26] v[24]: 6.89617
[motion_velocity_smoother-26] v[25]: 6.28872
[motion_velocity_smoother-26] v[26]: 5.61575
[motion_velocity_smoother-26] v[27]: 4.84995
[motion_velocity_smoother-26] v[28]: 3.93714
[motion_velocity_smoother-26] v[29]: 2.73211
[motion_velocity_smoother-26] v[30]: 0.100003
  • After the PR
[motion_velocity_smoother-26] v[0]: 0.25
[motion_velocity_smoother-26] v[1]: 0.287228
[motion_velocity_smoother-26] v[2]: 0.40908
[motion_velocity_smoother-26] v[3]: 0.544224
[motion_velocity_smoother-26] v[4]: 0.676197
[motion_velocity_smoother-26] v[5]: 0.802664
[motion_velocity_smoother-26] v[6]: 0.918984
[motion_velocity_smoother-26] v[7]: 1.02216
[motion_velocity_smoother-26] v[8]: 1.11583
[motion_velocity_smoother-26] v[9]: 1.20222
[motion_velocity_smoother-26] v[10]: 1.28282
[motion_velocity_smoother-26] v[11]: 3.13056
[motion_velocity_smoother-26] v[12]: 4.2314
[motion_velocity_smoother-26] v[13]: 5.09713
[motion_velocity_smoother-26] v[14]: 5.83413
[motion_velocity_smoother-26] v[15]: 6.48679
[motion_velocity_smoother-26] v[16]: 7.07868
[motion_velocity_smoother-26] v[17]: 7.62409
[motion_velocity_smoother-26] v[18]: 8.13246
[motion_velocity_smoother-26] v[19]: 8.61061
[motion_velocity_smoother-26] v[20]: 9.06354
[motion_velocity_smoother-26] v[21]: 9.49486
[motion_velocity_smoother-26] v[22]: 9.9074
[motion_velocity_smoother-26] v[23]: 10.2131
[motion_velocity_smoother-26] v[24]: 10.3581
[motion_velocity_smoother-26] v[25]: 10.3547
[motion_velocity_smoother-26] v[26]: 10.2056
[motion_velocity_smoother-26] v[27]: 9.90129
[motion_velocity_smoother-26] v[28]: 9.48848
[motion_velocity_smoother-26] v[29]: 9.05686
[motion_velocity_smoother-26] v[30]: 8.60358
[motion_velocity_smoother-26] v[31]: 8.12501
[motion_velocity_smoother-26] v[32]: 7.61639
[motion_velocity_smoother-26] v[33]: 7.0712
[motion_velocity_smoother-26] v[34]: 6.48021
[motion_velocity_smoother-26] v[35]: 5.82946
[motion_velocity_smoother-26] v[36]: 5.09599
[motion_velocity_smoother-26] v[37]: 4.23681
[motion_velocity_smoother-26] v[38]: 3.14974
[motion_velocity_smoother-26] v[39]: 1.37441
[motion_velocity_smoother-26] v[40]: 0.00158448

Pre-review checklist for the PR author

The PR author must check the checkboxes below when creating the PR.

In-review checklist for the PR reviewers

The PR reviewers must check the checkboxes below before approval.

Post-review checklist for the PR author

The PR author must check the checkboxes below before merging.

  • There are no open discussions or they are tracked via tickets.

After all checkboxes are checked, anyone who has write access can merge the PR.

Signed-off-by: yutaka <purewater0901@gmail.com>
@purewater0901 purewater0901 requested review from rej55, mkuri, TakaHoribe and a team as code owners March 2, 2023 10:16
@github-actions github-actions bot added the component:planning Route planning, decision-making, and navigation. (auto-assigned) label Mar 2, 2023
Signed-off-by: yutaka <purewater0901@gmail.com>
Signed-off-by: yutaka <purewater0901@gmail.com>
@purewater0901 purewater0901 enabled auto-merge (squash) March 2, 2023 10:43
@codecov
Copy link

codecov bot commented Mar 2, 2023

Codecov Report

Patch and project coverage have no change.

Comparison is base (f9075cb) 12.81% compared to head (9b74762) 12.81%.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2989   +/-   ##
=======================================
  Coverage   12.81%   12.81%           
=======================================
  Files        1212     1212           
  Lines       85613    85613           
  Branches    24260    24259    -1     
=======================================
  Hits        10968    10968           
  Misses      63282    63282           
  Partials    11363    11363           
Flag Coverage Δ *Carryforward flag
differential 3.34% <0.00%> (?)
total 12.81% <ø> (+<0.01%) ⬆️ Carriedforward from f9075cb

*This pull request uses carry forward flags. Click here to find out more.

Impacted Files Coverage Δ
...havior_path_planner/behavior_path_planner_node.hpp 0.00% <ø> (ø)
...th_planner/scene_module/scene_module_interface.hpp 0.00% <ø> (ø)
...or_path_planner/src/behavior_path_planner_node.cpp 0.15% <ø> (ø)
...y_smoother/src/smoother/jerk_filtered_smoother.cpp 0.00% <0.00%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@purewater0901 purewater0901 merged commit 91d8013 into main Mar 2, 2023
@purewater0901 purewater0901 deleted the fix/terminal-velocity-optimization branch March 2, 2023 11:24
1222-takeshi pushed a commit to 1222-takeshi/autoware.universe that referenced this pull request Mar 6, 2023
…towarefoundation#2989)

* fix(motion_velocity_smoother): fix terminal velocity optimization

Signed-off-by: yutaka <purewater0901@gmail.com>

* update

Signed-off-by: yutaka <purewater0901@gmail.com>

* update

Signed-off-by: yutaka <purewater0901@gmail.com>

---------

Signed-off-by: yutaka <purewater0901@gmail.com>
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)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants