Add discrete event simulation - #438
Open
reuben-thomas wants to merge 97 commits into
Open
reuben-thomas wants to merge 97 commits into
reuben-thomas wants to merge 97 commits into
Conversation
Signed-off-by: Xiyu Oh <xiyu@openrobotics.org> Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
* Add diagnostic for duplicated location names Location names are used to dispatch robots to specific places via RMF tasks. When two locations share a name the dispatch becomes ambiguous, which can cause incorrect routing. Mirror the existing duplicated door / lift name checks: a new `check_for_duplicated_location_names` system runs on `ValidateWorkspace` and emits an `Issue` for every name that appears on more than one location entity, with the affected entities attached so the diagnostics panel can highlight them. Fixes open-rmf#346 Signed-off-by: Lots-ninety-nine <261080291+Lots-ninety-nine@users.noreply.github.com> * Retrigger CI Signed-off-by: Lots-ninety-nine <261080291+Lots-ninety-nine@users.noreply.github.com> * Test CI Signed-off-by: Xiyu Oh <xiyu@openrobotics.org> * Remove branch Signed-off-by: Xiyu Oh <xiyu@openrobotics.org> --------- Signed-off-by: Lots-ninety-nine <261080291+Lots-ninety-nine@users.noreply.github.com> Signed-off-by: Xiyu Oh <xiyu@openrobotics.org> Co-authored-by: Lots-ninety-nine <261080291+Lots-ninety-nine@users.noreply.github.com> Co-authored-by: Xiyu <xiyu@openrobotics.org> Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
reuben-thomas
force-pushed
the
reuben/rmf_site_sim
branch
from
August 11, 2026 04:15
ef0f256 to
750aa19
Compare
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
Signed-off-by: Reuben Thomas <reubenthomas123@gmail.com>
reuben-thomas
force-pushed
the
reuben/rmf_site_sim
branch
from
August 11, 2026 05:30
6bbea74 to
7db0cbf
Compare
mxgrey
marked this pull request as ready for review
September 20, 2026 15:41
Signed-off-by: Michael X. Grey <mxgrey@intrinsic.ai>
Signed-off-by: Michael X. Grey <mxgrey@intrinsic.ai>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Addition of Discrete Event Simulation (DES) Library
This PR introduces
rmf_site_simas a new crate for performing DES in Bevy, with a core API that should be intuitive to Bevy users.Core Concepts and API
DiscreteEventis very similar to a BevyCommand, and represents an instantaneous change in the state of the world.SimulationStateis a wrapper around a BevyWorld, representing the state vector at any given moment.Prediction Systems are ordinary Bevy systems that are used to model behaviour. Rather than mutate the world directly, these systems propose
CandidateDiscreteEvents.CandidateDiscreteEventsare events that have been predicted by prediction systems that might occur. ADiscreteEventwithin is only applied on theWorldif it is guaranteed to occur.Computing a Simulation
The relationship between Prediction Systems
CandidateDiscreteEvents, andDiscreteEventsin the computation of a simulation may be summarized in the following:A simulation is computed asynchronously in a Bevy [
AsyncComputeTaskPool], first by extracting all relevant entities, components, and resources from the main world, and sendingSimulationStepupdates per timestep to theSimulationin the main thread as they are computed.Supporting Functionality
Synchronization
A simulation only ever handles a subset of components, entities, and resources, which is registered and managed by a
Synchronizer, which is used to extract only required data for compute, as well as switching between simulations during playback.Playback
The
SimulationPlaybackPluginplays a computed simulationback on the main world with speed control, seeking, and replay behaviour.
Interaction
keyboardA plugin for controlling playback with keyboard commands.egui(egui) Playback controls, an event table, and an overview panel implemented in egui.rmf_site_egui(rmf_site_egui) The above, as tiles in the RMF Site Editor's panels.GenAI Use
Some portions of this pull request were generated using: