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

Standardize moveit2 yaml parameter file format with ROS2 ros__parameter convention #630

Closed
shonigmann opened this issue Aug 19, 2021 · 4 comments
Labels
enhancement New feature or request

Comments

@shonigmann
Copy link

shonigmann commented Aug 19, 2021

Is your feature request related to a problem? Please describe.
I noticed that in moveit2 and the ROS2 branches of moveit_resources, etc some of the yaml config files (e.g. here or here) are still using the ROS1 format (parameter name: value), while others (e.g. here) are using the ROS2 format (namespace -> node name -> ros__parameters --> parameter name / value).

As a result, loading parameters in a node using a python launch file requires the use of this load_yaml() function, as opposed to the more "ROS2-esque" approach of simply including the path to the yaml file in question as a Node parameter.

The latter would omit the need to define custom file loading functions in each launch file and would be more amenable to modularizing and generalizing launch files using LaunchArguments to specify config files rather than having them as hard-coded paths. It would also potentially make things easier for users to use only the ROS2 format (at the cost of making it slightly harder to migrate ROS1 configurations).

Describe the solution you'd like
It would be great to standardize all yaml config files using the ROS2 format. That said, I'm fairly new to Moveit2 and am not sure if there would be more involved than just changing the config files themselves to include ros__parameters.

@shonigmann shonigmann added the enhancement New feature or request label Aug 19, 2021
@tylerjw
Copy link
Member

tylerjw commented Aug 23, 2021

One of the big problems is some of the moveit2 nodes can also be launched as component nodes. In that case ros doesn't handle the ros__parameters prefix correctly. If you look here: https://github.com/PickNikRobotics/parameter_tools/ @JafarAbdi has built something to standardize loading ros parameters for moveit. Soon we plan on migrating the moveit launch files to use this tool. Another thing we are doing to standardize parameters is I'm working on something to handle validating parameters in a more ros2 way.

@shonigmann
Copy link
Author

Good to know - I was unaware of the issue with component nodes and parameter files. Thanks for the feedback!

@shonigmann
Copy link
Author

for the reference of anyone that come's across this issue, it looks like Component Nodes will soon support the same yaml file format as regular nodes (ros2/launch_ros#259 ) but the parameter_tools package looks like a great solution as well.

@sotanakamura
Copy link

I had a trouble due to ros__parameter when I loaded the yaml parameter files in a xml launch file or from command line arguments. As mentioned above, the problem of component nodes was solved, then we should make the yaml parameter files standard.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants