-
Notifications
You must be signed in to change notification settings - Fork 99
Ensure model reproducibility
Arthur Brugière edited this page Apr 25, 2023
·
3 revisions
There is a huge effort in GAMA development in order to ensure the reproducibility of the simulations, i.e. when several simulations of the same models are launched with the same random generator seed and same parameter values, they are supposed to provide the same results.
Nevertheless, GAMA provides several ways to speed up simulations runs, e.g. by making parallel the execution of some agents' behaviors. The use of parallelism may destroy the reproducibility of the simulations. More generally, there are many sources of uncertainty which can break this reproducibility.
If you aim at reproducibility, you need to reduce as many as possible all the sources of uncertainty.
- Set the random number generator seed (give a given value to the model
seed
global attribute). - Reduce the parallel execution of agents' behaviors.
- remove all the explicitly parallel execution, in particular remove / set to false all the
parallel
facets (e.g. in the loop, ask...). - Set the values of some dedicated preferences to remove automatic parallel executions. This can be done in the experiment block.
- remove all the explicitly parallel execution, in particular remove / set to false all the
experiment 'any exp' {
init {
//Make grids schedule their agents in parallel
gama.pref_parallel_grids <- false;
//Make experiments run simulations in parallel
gama.pref_parallel_simulations <- true;
//Make species schedule their agents in parallel
gama.pref_parallel_species <- false;
}
}
- Displays are computed independently of the simulation, and in parallel. Limit computation and model modifications in the aspects.
- Remove any modification of the model in the aspects.
- Do not use any random operators in the aspects (e.g.
rnd
,one_of
,any
...).
- The use of asynchronous communications (using network) with external applications, the use of files (in particular if they are changed externally) can also modify the behavior of simulations
- Installation and Launching
- Workspace, Projects and Models
- Editing Models
- Running Experiments
- Running Headless
- Preferences
- Troubleshooting
- Introduction
- Manipulate basic Species
- Global Species
- Defining Advanced Species
- Defining GUI Experiment
- Exploring Models
- Optimizing Model Section
- Multi-Paradigm Modeling
- Manipulate OSM Data
- Diffusion
- Using Database
- Using FIPA ACL
- Using BDI with BEN
- Using Driving Skill
- Manipulate dates
- Manipulate lights
- Using comodel
- Save and restore Simulations
- Using network
- Headless mode
- Using Headless
- Writing Unit Tests
- Ensure model's reproducibility
- Going further with extensions
- Built-in Species
- Built-in Skills
- Built-in Architecture
- Statements
- Data Type
- File Type
- Expressions
- Exhaustive list of GAMA Keywords
- Installing the GIT version
- Developing Extensions
- Introduction to GAMA Java API
- Using GAMA flags
- Creating a release of GAMA
- Documentation generation