I suggested this a while ago, not sure whether it’s implemented already. Basically, we want the sequence of random samples to be repeatable using a seed. This is important for reproducibility/repeatability of experiments.
This should be possible at least for the built-in NewtonianSimulator. I expect this to be possible in CARLA as well as long as the user-defined agents are deterministic, since CARLA’s traffic manager can be configured using the carla.TrafficManager.set_random_device_seed().
Hi Abel, I can’t recall our previous discussion offhand, but is the --seed option not working for you? It is supposed to make Scenic’s own sampling deterministic. Of course, as you point out, if the simulator is nondeterministic there’s not much we can do in general, but calling that CARLA API sounds like a good idea (feel free to make a feature request).
For the specific use case of replying experiments, Scenic also provides APIs to save and replay simulations; these have the same caveat about simulators as --seed.