Skip to main content

Module simulation

Module simulation 

Source
Expand description

Checked setups for one build of a model, and the simulations they build.

A RunSetup holds a model’s parameter values by id, a seed and scheduled actions, each checked against the model’s descriptors when set. RunSetup::build returns a Simulation, one built model that its caller steps, and a StatSample is one sample of the model’s stats, read by label.

Actions fire under henad_core::action::Fire::AfterStep. Tick 0’s actions fire inside the build, and each later tick’s actions fire after the step that reaches it. Every call returns a model’s panic, a device error or a lost device as a Fault, and a simulation that returned one rejects every later call that runs model code. Simulation lists the calls that enter the rayon pool.

Structs§

RunSetup
Values, seed and schedule for one build of an entry, each checked against its descriptors when set.
Simulation
One built model and its schedule, stepped by its caller.
SimulationViews
Views of one model, prepared together and borrowed from its state.
StatSample
One sample of a model’s stats.

Enums§

ExportError
Reason Simulation::write_state wrote nothing, or stopped part way.
SetupError
Reason a setup, a live edit or a live action was rejected.