datasim.Runner

class datasim.Runner(world_class_object, headless: bool = False, auto_output_path: str | None = None, auto_output_csv: bool = False)

Main simulation runner for DataSim.

This class creates the World objects for any batches of runs defined in the definition yaml of the target class.

__init__(world_class_object, headless: bool = False, auto_output_path: str | None = None, auto_output_csv: bool = False)

Create a simulation Runner.

Parameters:
  • world_class_object (type or object) – Type, class or object by which the world’s type is determined

  • headless (bool, optional) – Run without dashboard. Defaults to False.

Raises:

ValueError – If the definition file contains an invalid grid definition.

Methods

__init__(world_class_object[, headless, ...])

Create a simulation Runner.

simulate([tpu, end_tick, restart, realtime, ...])

Run the simulation for all worlds.

stop()

Stop the simulation and wait for it to end.

wait()

Wait for the simulation of all worlds to end.

Attributes

active

Check if the simulation is still actively running.

complete_log

date

end_tick

realtime

restart

stop_server

tpu

output

single_world

worlds

title

headless

started

update_time

control_thread

auto_output_path

auto_output_csv