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

Added messages for 2D Bounding Boxes to ros_gz_bridge #458

Merged
merged 3 commits into from
Nov 9, 2023
Merged

Added messages for 2D Bounding Boxes to ros_gz_bridge #458

merged 3 commits into from
Nov 9, 2023

Conversation

wittenator
Copy link
Contributor

@wittenator wittenator commented Oct 27, 2023

🎉 New feature

Closes #457

Summary

I added the bridging of Detection2D and Detection2DArray to AnnotatedAxisAligned2DBox and AnnotatedAxisAligned2DBox_V and vice versa.

Test it

WIP

Checklist

  • Signed all commits for DCO
  • Added tests
  • Added example and/or tutorial
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • Consider updating Python bindings (if the library has them)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining Signed-off-by messages.

🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸🔸

ros_gz_bridge/src/convert/vision_msgs.cpp Outdated Show resolved Hide resolved
ros_gz_bridge/src/convert/vision_msgs.cpp Outdated Show resolved Hide resolved
ignition::msgs::Vector2d min_corner = box.min_corner();
ignition::msgs::Vector2d max_corner = box.max_corner();

auto id = ros_msg.results.at(0).hypothesis.class_id;
Copy link
Collaborator

Choose a reason for hiding this comment

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

we should check here if there is any values availables in the results array.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks for the quick review! Should we maybe print a warning when there is nothing in the results array as it is a malformed message? If I am not mistaken, the id in the GZ message will be 0 if it is not explicitly set. Or is there any other way of conveying "None-ness" here?

ros_gz_bridge/src/convert/vision_msgs.cpp Outdated Show resolved Hide resolved
ros_gz_bridge/src/convert/vision_msgs.cpp Outdated Show resolved Hide resolved
ros_gz_bridge/src/convert/vision_msgs.cpp Outdated Show resolved Hide resolved
wittenator and others added 3 commits October 30, 2023 17:42
Integrated first batch of suggestions

Co-authored-by: Alejandro Hernández Cordero <[email protected]>
Signed-off-by: wittenator <[email protected]>
@ahcorde ahcorde merged commit 55eebea into gazebosim:humble Nov 9, 2023
7 checks passed
ahcorde pushed a commit that referenced this pull request Nov 13, 2023
ahcorde pushed a commit that referenced this pull request Nov 21, 2023
ahcorde added a commit that referenced this pull request Nov 21, 2023
Signed-off-by: wittenator <[email protected]>
Co-authored-by: Alejandro Hernandez Cordero <[email protected]>
@azeey azeey mentioned this pull request Dec 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants