-
Notifications
You must be signed in to change notification settings - Fork 690
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(object_lanelet_filter): add configurable margin for object lanel… #9240
feat(object_lanelet_filter): add configurable margin for object lanel… #9240
Conversation
Thank you for contributing to the Autoware project! 🚧 If your pull request is in progress, switch it to draft mode. Please ensure:
|
b34c04b
to
8ab23a3
Compare
8ab23a3
to
f5196e4
Compare
@badai-nguyen @technolojin Could you check this PR? (especially calculation cost) |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #9240 +/- ##
==========================================
- Coverage 29.51% 29.50% -0.01%
==========================================
Files 1442 1443 +1
Lines 108594 108629 +35
Branches 41502 41525 +23
==========================================
Hits 32055 32055
- Misses 73418 73453 +35
Partials 3121 3121
*This pull request uses carry forward flags. Click here to find out more. ☔ View full report in Codecov by Sentry. |
@sebekx Hi, thank you for your PR! I timed the processing time by the TimeKeeper. vs. implementation
case of
|
impl. | debug | lanelet_extra_margin | avg. processing time |
---|---|---|---|
this PR | true | 0.0 | ~4.4 ms |
- "larger map" in the table indicates that the same rosbag with a larger map, so the size of the map is the only difference. The rows having '✓' is using the larger map.
debug
,lanelet_extra_margin
is the parameter in the config file.
The implementation of this PR is faster than the current one when the lanelet_extra_margin
is set to 0.0 (disabled).
(It should be coming from the reduction of the method calls)
@sebekx since I am not familiar with the bg::strategy::buffer
, do you know what kind of behavior is expected for distance_strategy(<negative value>)
? Checking the lanelets with debug=true
option in this PR, it seems it does not create the margin for the lanelets.
Also, it would be nice if you create the update PR for the config file in the autoware_launch too! |
viz_pub_ = | ||
this->create_publisher<visualization_msgs::msg::MarkerArray>("~/debug/marker", rclcpp::QoS{1}); | ||
} |
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.
It might be better to create the publisher when the filter_settings_.debug == true
since it only be used in publishDebugMarkers
that is also only get called when filter_settings_.debug == true
.
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.
Added code that creates publisher only whether there is filter_settings_.debug == true
.
filter_settings_.debug = declare_parameter<bool>("filter_settings.debug"); | ||
filter_settings_.lanelet_extra_margin = | ||
declare_parameter<double>("filter_settings.lanelet_extra_margin"); | ||
// |
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.
remove //
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.
removed
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.
I think it still exist.
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.
sorry, now should be removed
@sebekx also, could you fix the error in the cppcheck result ? |
@a-maumau Hi, thanks for review. Normally it will make polygon smaller but in this implementation there is a condition to only expand polygons whether there is positive value of extra margin. |
there is pr |
fixed |
Ah, I simply forgot that part, thank you. I first thought shrinking might have some needs in some cases, but it would make some gaps between the lanelet connections, so this is reasonable. |
perception/autoware_detected_object_validation/src/lanelet_filter/lanelet_filter.cpp
Outdated
Show resolved
Hide resolved
Can you kindly add this link and description to this PR description? |
I am going to test its performance. |
I measured processing time in 3 different situation A. Before A: 5ms in low, 10ms of high load In conclusion, the performance of the same usage is improved. If the extra margin is added, it causes computational cost (as expected). |
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
@YoshiRi can you confirm this PR? |
perception/autoware_detected_object_validation/config/object_lanelet_filter.param.yaml
Show resolved
Hide resolved
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
1e78267
to
97b0fad
Compare
perception/autoware_detected_object_validation/src/lanelet_filter/debug.cpp
Outdated
Show resolved
Hide resolved
a823ef8
to
8de8bed
Compare
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.
Thanks! LGTM
NOTE: I did NOT check this PR by running this code.
8de8bed
to
b96939e
Compare
…et filter Signed-off-by: Sebastian Zęderowski <[email protected]> modified: perception/autoware_detected_object_validation/src/lanelet_filter/lanelet_filter.cpp Signed-off-by: Sebastian Zęderowski <[email protected]>
… empty in debug mode Signed-off-by: Sebastian Zęderowski <[email protected]>
Signed-off-by: Sebastian Zęderowski <[email protected]>
Signed-off-by: Taekjin LEE <[email protected]> Signed-off-by: Sebastian Zęderowski <[email protected]>
Signed-off-by: Taekjin LEE <[email protected]> Signed-off-by: Sebastian Zęderowski <[email protected]>
Signed-off-by: Sebastian Zęderowski <[email protected]>
Signed-off-by: Sebastian Zęderowski <[email protected]>
Signed-off-by: Sebastian Zęderowski <[email protected]>
…ter/debug.cpp Co-authored-by: Shintaro Tomie <[email protected]> Signed-off-by: Sebastian Zęderowski <[email protected]>
Signed-off-by: Sebastian Zęderowski <[email protected]>
b96939e
to
5bf3d37
Compare
@sebekx Thank you for your contribution! |
object_lanelet_filter
Description
Added configurable margin to object lanelet filter which extends area of non filtered objects.
With margin 3m:


Related links
Related autoware launch pr with configs
Parent Issue:
None.
How was this PR tested?
Notes for reviewers
None.
Interface changes
None.
Effects on system behavior
None.