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(predicted_path_checker): check predicted trajectory to avoid collisions planning can not handle #2528

Merged
merged 2 commits into from
Sep 29, 2023

Conversation

brkay54
Copy link
Member

@brkay54 brkay54 commented Dec 19, 2022

Description

Discussion: autowarefoundation/autoware#2859
Issue: #2252

In current implementation of Autoware, control module is not responsible for collision checking, except
obstacle_collision_checker package (It can stop the vehicle just for emergency situations.). Planning module is making
stop planning and collision checking using the reference trajectory.

However, vehicles actual path would be apart from reference trajectory in some cases such as starting driving with high
lateral error and at sharp turns.

In this scenarios, planning may not handle the collision in some part of the path because it does collision checking just
on reference trajectory. I think this is a critical safety issue, because vehicle will be open to collision in some cases.

Because vehicle’s actual path is strictly depend on the controller, we decided to add new package (predicted_path_checker) to check obstacle collision on predicted path and stop the vehicle if the collision was not handled by the planning module.

image

This node will make the vehicle stop if the current situation is emergency (if there is an obstacle in brake distance.) or collision can not be handled by planning module.

Flow Chart:

FlowChart

Before this PR merged, following PRs should be merged before:
#3437
#3435
tier4/tier4_autoware_msgs#82

Proposed Solutions:

Please feel free to share your ideas on discussion.

Related links

Tests performed

Checked the vehicle state if there is an obstacle in front of the vehicle by using planning_simulator. It worked as I wanted.

Notes for reviewers

While testing the package, you should also checkout these PRs:

#3790
autowarefoundation/autoware_launch#367
tier4/tier4_autoware_msgs#88

To test the package, it is enough to run the launch file inside of the package.

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.

  • The PR follows the pull request guidelines.
  • The PR has been properly tested.
  • The PR has been reviewed by the code owners.

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.
  • The PR is ready for merge.

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

@brkay54 brkay54 added the component:control Vehicle control algorithms and mechanisms. (auto-assigned) label Dec 19, 2022
@brkay54 brkay54 requested a review from TakaHoribe December 19, 2022 22:18
@brkay54 brkay54 self-assigned this Dec 19, 2022
@github-actions github-actions bot added the type:documentation Creating or refining documentation. (auto-assigned) label Dec 19, 2022
@brkay54 brkay54 marked this pull request as draft December 19, 2022 22:18
@brkay54 brkay54 force-pushed the predicted-path-checker branch from 8e18249 to 172a14d Compare December 22, 2022 15:20
@codecov
Copy link

codecov bot commented Dec 22, 2022

Codecov Report

Attention: 672 lines in your changes are missing coverage. Please review.

Comparison is base (fe9ad68) 14.87% compared to head (1f2f0aa) 14.79%.
Report is 9 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2528      +/-   ##
==========================================
- Coverage   14.87%   14.79%   -0.09%     
==========================================
  Files        1629     1635       +6     
  Lines      112780   113452     +672     
  Branches    34900    34900              
==========================================
  Hits        16780    16780              
- Misses      77158    77830     +672     
  Partials    18842    18842              
Flag Coverage Δ *Carryforward flag
differential 0.00% <0.00%> (?)
total 14.87% <ø> (ø) Carriedforward from fe9ad68

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

Files Coverage Δ
...er/include/predicted_path_checker/debug_marker.hpp 0.00% <0.00%> (ø)
...clude/predicted_path_checker/collision_checker.hpp 0.00% <0.00%> (ø)
.../predicted_path_checker_node/collision_checker.cpp 0.00% <0.00%> (ø)
...r/src/predicted_path_checker_node/debug_marker.cpp 0.00% <0.00%> (ø)
..._checker/src/predicted_path_checker_node/utils.cpp 0.00% <0.00%> (ø)
..._path_checker_node/predicted_path_checker_node.cpp 0.00% <0.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@brkay54 brkay54 force-pushed the predicted-path-checker branch from 493dfe7 to ee5e59a Compare December 24, 2022 19:03
@github-actions github-actions bot added component:common Common packages from the autoware-common repository. (auto-assigned) component:system System design and integration. (auto-assigned) labels Dec 24, 2022
@brkay54 brkay54 added this to the Bus ODD Jan-Feb Milestone milestone Jan 23, 2023
@brkay54 brkay54 added the priority:high High urgency and importance. label Jan 23, 2023
@brkay54 brkay54 force-pushed the predicted-path-checker branch from 689a478 to 6c5cb9b Compare February 1, 2023 07:52
@mitsudome-r
Copy link
Member

We had another call to discuss this. In conclusion:

  • Instead of adding new Pause state, we will add request_source field in SetPause.srv
  • Pause Interface node (vehicle_command_gate) will keep the record of requested source and only release pause whenever all the source requests pause: false

@brkay54
Copy link
Member Author

brkay54 commented Apr 13, 2023

Hello, sorry for the delay. I designed node with using point cloud for collision checking. However I needed to make some changes in design. Currently, I changed design for using predicted objects, this week I will update the PR for this.

brkay54 added a commit to brkay54/autoware.universe that referenced this pull request Apr 17, 2023
…llisions planning can not handle (autowarefoundation#2528)

Signed-off-by: Berkay Karaman <brkay54@gmail.com>
@brkay54 brkay54 force-pushed the predicted-path-checker branch from 6c5cb9b to a8b42b1 Compare April 17, 2023 03:21
@github-actions github-actions bot removed component:common Common packages from the autoware-common repository. (auto-assigned) component:system System design and integration. (auto-assigned) labels Apr 17, 2023
@brkay54 brkay54 force-pushed the predicted-path-checker branch 2 times, most recently from e2afff0 to 66e6f80 Compare April 18, 2023 07:05
brkay54 added a commit to brkay54/autoware.universe that referenced this pull request Apr 18, 2023
…llisions planning can not handle (autowarefoundation#2528)

Signed-off-by: Berkay Karaman <brkay54@gmail.com>
@brkay54 brkay54 force-pushed the predicted-path-checker branch from 7b4f84d to 641ee8f Compare April 18, 2023 07:12
brkay54 added a commit to brkay54/autoware.universe that referenced this pull request Apr 18, 2023
…llisions planning can not handle (autowarefoundation#2528)

Signed-off-by: Berkay Karaman <brkay54@gmail.com>
@brkay54 brkay54 force-pushed the predicted-path-checker branch from 551d968 to e5f24f6 Compare June 6, 2023 13:19
brkay54 added a commit to brkay54/autoware.universe that referenced this pull request Jun 6, 2023
…llisions planning can not handle (autowarefoundation#2528)

Signed-off-by: Berkay Karaman <brkay54@gmail.com>
@brkay54 brkay54 force-pushed the predicted-path-checker branch from 102b97f to 88c5f81 Compare June 6, 2023 13:51
@brkay54 brkay54 requested a review from takayuki5168 as a code owner June 6, 2023 13:51
@github-actions github-actions bot added the component:launch Launch files, scripts and initialization tools. (auto-assigned) label Jun 6, 2023
Copy link
Contributor

@TakaHoribe TakaHoribe left a comment

Choose a reason for hiding this comment

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

LGTM!

@stale
Copy link

stale bot commented Aug 6, 2023

This pull request has been automatically marked as stale because it has not had recent activity.

@stale stale bot added the status:stale Inactive or outdated issues. (auto-assigned) label Aug 6, 2023
@takayuki5168 takayuki5168 added the run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci) label Aug 30, 2023
@takayuki5168
Copy link
Contributor

@brkay54 I added a label of run-build-and-test-differential to run CI.

@TakaHoribe
Copy link
Contributor

@brkay54 Can we merge this PR?

@stale stale bot removed the status:stale Inactive or outdated issues. (auto-assigned) label Sep 20, 2023
satoshi-ota pushed a commit to brkay54/autoware.universe that referenced this pull request Sep 20, 2023
…llisions planning can not handle (autowarefoundation#2528)

Signed-off-by: Berkay Karaman <brkay54@gmail.com>
@satoshi-ota satoshi-ota force-pushed the predicted-path-checker branch from 88c5f81 to 618323b Compare September 20, 2023 09:59
@brkay54
Copy link
Member Author

brkay54 commented Sep 20, 2023

@TakaHoribe Sorry for the late response, I am planning to work on this, Just i need to fix a small bug. After that, I am gonna merge it in this week.

brkay54 pushed a commit to brkay54/autoware.universe that referenced this pull request Sep 22, 2023
…llisions planning can not handle (autowarefoundation#2528)

Signed-off-by: Berkay Karaman <brkay54@gmail.com>
@brkay54 brkay54 force-pushed the predicted-path-checker branch 2 times, most recently from 1ee87a3 to 37c6cd5 Compare September 22, 2023 13:26
@brkay54
Copy link
Member Author

brkay54 commented Sep 22, 2023

So sorry for the delay.

@mehmetdogru If it is okay for you, can we merge it?

…llisions planning can not handle (autowarefoundation#2528)

Signed-off-by: Berkay Karaman <brkay54@gmail.com>
Signed-off-by: Berkay Karaman <brkay54@gmail.com>
@brkay54 brkay54 force-pushed the predicted-path-checker branch from 37c6cd5 to 1f2f0aa Compare September 28, 2023 14:52
@brkay54
Copy link
Member Author

brkay54 commented Sep 29, 2023

Sorry for the long time for this PR. Thank you for your review @TakaHoribe I am merging this package. Also, if you have time, would you help me merge the launch file in autowarefoundation/autoware_launch#385 ? FYI @mehmetdogru

@brkay54 brkay54 merged commit e337576 into autowarefoundation:main Sep 29, 2023
@@ -372,6 +403,7 @@ def add_launch_arg(name: str, default_value=None, description=None):
add_launch_arg("obstacle_collision_checker_param_path")
add_launch_arg("external_cmd_selector_param_path")
add_launch_arg("aeb_param_path")
add_launch_arg("predicted_path_checker_param_path")
Copy link
Contributor

Choose a reason for hiding this comment

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

Probably should also add enable_predicted_path_checker as a launch arg here.

@brkay54 brkay54 deleted the predicted-path-checker branch October 2, 2023 11:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:control Vehicle control algorithms and mechanisms. (auto-assigned) component:launch Launch files, scripts and initialization tools. (auto-assigned) priority:high High urgency and importance. run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci) type:documentation Creating or refining documentation. (auto-assigned)
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

6 participants