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

Feature/frame transformer node #95

Merged
merged 4 commits into from Jan 3, 2022

Conversation

msmcconnell
Copy link
Contributor

@msmcconnell msmcconnell commented Dec 22, 2021

PR Details

Description

Integration testing of ROS2 object perception stack identified that the Autoware.Auto nodes expect input data to already be transformed prior to arriving at the target node. For example, transforming lidar data from velodyne to base_link. Seperate transformer nodes were implemented in Autoware.Auto to achieve this goal. Unfortunately, these nodes do not use the TF2 library meaning that the transform tree is duplicated in multiple parameter files. I believe this approach will be extremely hard for our team to maintain and error prone as transforms get updated in some locations but not others.

To get around this issue, I have implemented a generalized transform node that will work on any message type where the tf2::doTransform operation has been specialized for that type. This comes with ROS by default for some messages in the tf2_geometry_msgs and tf2_sensor_msgs packages. Using the pre-defined transformations, a node is implemented which uses a templated transformer to setup the corresponding subscription and publications based on a parameter describing the message type. Input data will then be automatically transformed into the appropriate frame based on its current timestamp.

This should allow us to easily replace the Autoware.auto nodes that also filled this role without needing to change any of our existing configurations.

Related Issue

Supports ROS2 milestone
https://github.com/usdot-fhwa-stol/carma-platform/milestone/4

Motivation and Context

Better configuration management

How Has This Been Tested?

Verified correct topic subscriptions are setup on launch.
Unit testing is still a TODO as is testing the actual transform behavior at runtime

Types of changes

  • Defect fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that cause existing functionality to change)

Checklist:

  • I have added any new packages to the sonar-scanner.properties file
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
    CARMA Contributing Guide
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@msmcconnell msmcconnell self-assigned this Dec 22, 2021
@sonarcloud
Copy link

sonarcloud bot commented Dec 22, 2021

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

@msmcconnell msmcconnell merged commit 8467620 into foxy/develop Jan 3, 2022
@msmcconnell msmcconnell deleted the feature/frame_transformer_node branch January 3, 2022 21:47
@msmcconnell
Copy link
Contributor Author

For anyone arriving at this PR from ROS Answers the package was moved to carma-platform in this PR usdot-fhwa-stol/carma-platform#1583

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.

None yet

2 participants