-
Notifications
You must be signed in to change notification settings - Fork 787
feat(shape_estimation): correcting cluster yaw and refactoring #11309
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
base: main
Are you sure you want to change the base?
feat(shape_estimation): correcting cluster yaw and refactoring #11309
Conversation
Thank you for contributing to the Autoware project! 🚧 If your pull request is in progress, switch it to draft mode. Please ensure:
|
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.
@Owen-Liuyuxuan Is there any rosbag to check that problem is happening or not. |
bool first_in_length_range = (param.min_length < first_point_distance && first_point_distance < param.max_length); | ||
bool second_in_width_range = (second_point_distance < param.max_width); | ||
bool second_in_length_range = (param.min_length < second_point_distance && second_point_distance < param.max_length); | ||
bool third_in_width_range = (third_point_distance < param.max_width); |
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 for the refactoring! That is very helpful.
Suggestion: Can we separate the refactoring and the logic change?
For the logic change, can you provide any visual comparison before and after this PR? |
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.
@emuemuJP Hi, thanks for the refactoring! I also wanted to do something for this package.
I have some points to mention.
double second_point_distance = (v_point.at(second_most_distant_index) * 2.0).norm(); | ||
double third_point_distance = (v_point.at(third_most_distant_index) * 2.0).norm(); | ||
// Check if points are within parameter ranges | ||
bool first_in_width_range = (first_point_distance < param.max_width); |
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 might misunderstanding something here, but why we don't need to check the param.min_width for *_in_width_range
part?
In the original implementation, it was checking like param.min_width < (...).norm() && (...).norm() < param.max_width
.
if (-FRONT_BACK_ANGLE_THRESHOLD <= cluster_angle_rad || | ||
cluster_angle_rad < FRONT_BACK_ANGLE_THRESHOLD) { // front |
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 this is a bug.
Since ||
is used here, all the condition will go in this branch.
&&
should be used.
Description
Related links
Parent Issue:
How was this PR tested?
test with the following rosbag
Notes for reviewers
None.
Interface changes
None.