-
Notifications
You must be signed in to change notification settings - Fork 137
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
Standardization of simulation interfaces #410
Comments
This issue has been mentioned on ROS Discourse. There might be relevant details there: https://discourse.ros.org/t/tools-to-use-other-simulators-as-an-alternative-to-gazebo/40556/2 |
considering OSI in https://github.com/OpenSimulationInterface and ISO 23150 in https://www.iso.org/standard/83293.html ? |
@ZhenshengLee in my opinion, OSI it is not a good match for the task for several reasons:
This does not mean that OSI is not useful, but rather that it solves another problem. |
Is it common practice to use the services? Should I re-implement it so that it can be started up as a service? |
So the running node represents the spawned robot and when you kill the node, the robot is removed? Or how is it done? It makes sense to me to have this functionality as a service because then you can easier integrate spawning multiple robots e.g. in a program loop. |
I am referring to the create node in the ros_gz_sim package. |
Thanks @adamdbrw for kicking this off. I do agree that having a standardized simulation interface would be good for the community. Generally, I think we want to start small and try to make the interfaces as generic as possible. Here a few comments/questions toward that goal:
|
@hijimasa Service carries a response, which is useful in handling of various cases (sim not running, service can be not ready, there can be an error which is then communicated to the user, etc.). As for running a node, I think this is a part of implementation choices. O3DE runs a ROS 2 simulation node(s) natively but other sims might have a different approach, and instead run a kind of wrapper / bridge / communication node. @azeey I agree to start lean for the core interface, and would also love to make good use of optional fields and the concept of standard extensions. The standard does not have to be implemented entirely from the get-go.
I would love to go ahead and prepare a PR to accompany the discussion, where we can have a review process. Could you help with creating a repository? |
I commend this effort, and would agree that an empty repository would help in furthering the discussion. |
Regarding the repository, we'd have to first decide on the org it'll go in. Maybe @gbiggs or @clalancette can comment whether this belongs in |
@azeey Good thinking! Let me comment on each point.
Looking forward to submit a PR to the new repo! |
It definitely doesn't belong in the I also don't think it necessarily belongs in the What do you think about the https://github.com/ros-simulation organization? It is lightly used, but it at least has a bit of history of supporting multiple simulators (it has repositories for both Gazebo and Stage). |
ros-simulation sounds good. I've gone ahead created https://github.com/ros-simulation/simulation_interfaces/. |
I will draft a PR to the repository early next week |
Problem
The number of simulator choices for ROS increased over time, and these simulators offer different advantages and trade-offs. For certain applications Gazebo is a match, for others, Open 3D Engine (O3DE) does the job the best, and for others yet, Isaac Sim might be a fit. There are many more yet.
Open 3D Engine robotic simulation (the ROS 2 Gem) depends on gazebo_msgs package, which was deprecated with the Jazzy release, but also, as an exception, released to make life easier for O3DE users. The gazebo_msgs package interfaces are quite generic and thus were reused in O3DE. However, one simulator interface user experience should not depend on a release cycle of another simulator, but rather be tied to a certain standard.
There is currently no standard for simulation interfaces. Simulation interfaces include spawning and de-spawning of robots and other entities, moving them around, pausing and resetting the scene, and so on. They are also highly important for automation of simulation-based testing. These interfaces are mostly services as they offer valuable response interaction which is needed for almost all the interface features.
Proposed solution
A new simulation_interfaces package which reuses much of gazebo_msgs but also introduces new interfaces and changes some fields to fully support current Gazebo and O3DE community needs. The priority for the first release should be minimizing impact (including semantic differences) for the users, and capturing new requirements in new services rather than re-imagining the entire package.
Current state of O3DE interfaces in use
I come with the O3DE perspective and invite others to supply other perspectives. Note that current use for some of services and their fields is not adhering to their intended semantics, and includes extension Gems beyond the core ROS 2 Gem.
Services for simulation entities spawning and control (all are gazebo_msgs/srv/ services):
Services for simulation scenes and control, especially important for automation with scenario testing (multiple runs of simulation on different scenes). Note that some services are not used semantically as intended, and some services are custom here indicating there is no great fit in current gazebo_msgs interface set:
The benefits
Standardization would improve user experience when using their validation, testing and ML pipelines with several simulators, or when switching between one simulator and the other as they needs come to better match another platform. It would also make it easier to benchmark simulators.
Discussion
Please take a look, @azeey.
The text was updated successfully, but these errors were encountered: