-
Notifications
You must be signed in to change notification settings - Fork 682
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
perf(intersection): reduce bg::within call #2190
perf(intersection): reduce bg::within call #2190
Conversation
Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp>
planning/behavior_velocity_planner/src/scene_module/intersection/util.cpp
Outdated
Show resolved
Hide resolved
b38a403
to
e68bcc6
Compare
Codecov ReportBase: 10.84% // Head: 10.82% // Decreases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #2190 +/- ##
==========================================
- Coverage 10.84% 10.82% -0.02%
==========================================
Files 1178 1178
Lines 84833 84988 +155
Branches 19987 20135 +148
==========================================
Hits 9204 9204
- Misses 65894 66035 +141
- Partials 9735 9749 +14
*This pull request uses carry forward flags. Click here to find out more.
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. |
Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp>
@kyoichi-sugahara @taikitanaka3 @veqcc @shmpwk Can you review and approve this change ? |
planning/behavior_velocity_planner/src/scene_module/intersection/util.cpp
Outdated
Show resolved
Hide resolved
Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp>
planning/behavior_velocity_planner/src/scene_module/intersection/util.cpp
Outdated
Show resolved
Hide resolved
planning/behavior_velocity_planner/src/scene_module/intersection/util.cpp
Outdated
Show resolved
Hide resolved
planning/behavior_velocity_planner/src/scene_module/intersection/util.cpp
Outdated
Show resolved
Hide resolved
Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
* perf(intersection): reduce bg::within call Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * use lane interval for getStopLineFromMap too Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * changed index type to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * replace unsigned to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp>
* perf(intersection): reduce bg::within call Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * use lane interval for getStopLineFromMap too Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * changed index type to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * replace unsigned to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> Signed-off-by: Kotaro Yoshimoto <pythagora.yoshimoto@gmail.com>
* perf(intersection): reduce bg::within call Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * use lane interval for getStopLineFromMap too Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * changed index type to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * replace unsigned to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp>
* perf(intersection): reduce bg::within call Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * use lane interval for getStopLineFromMap too Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * changed index type to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> * replace unsigned to size_t Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> Signed-off-by: Mamoru Sobue <mamoru.sobue@tier4.jp> Signed-off-by: yoshiri <yoshiyoshidetteiu@gmail.com>
Signed-off-by: Mamoru Sobue mamoru.sobue@tier4.jp
Description
cc: @veqcc
In
getFirstPointInsidePolygons
function, I addedlane_id
argument in order to callboost::within
only to those points which are inside the lane of interest.Related links
#2097
Tests performed
Tested in kashiwanoha map used in tutorial. The number of calls to
![Screenshot from 2022-11-01 18-13-00](https://user-images.githubusercontent.com/28677420/199200832-24fd8f8a-4815-45d6-9ccb-6dff9f5153b1.png)
boost::within
reduced from 7103 to 1273.The time for
getStopLineFromMap
reduce from ~9ms to ~1ms.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.
After all checkboxes are checked, anyone who has write access can merge the PR.