This is the code underlying the study on ABC statistic learning and adaptive distance weight calculation, for the manuscript "Informative and adaptive distances and summary statistics in sequential approximate Bayesian computation" by Yannik Schälte, Jan Hasenauer, 2022 (https://www.biorxiv.org/content/10.1101/2022.03.18.484896). Both analysis and figure generation code are included, facilitating reproducibility with likely slight modifications (some parts are specific to the employed hardware).
The study is prepared for execution on Linux, particularly on the Juelich Supercomputing Center (JSC) infrastructure.
To run on other systems, slight modifications to the install_all.sh
and run_....sh
scripts may be necessary.
The install_all.sh
script handles the full installation process, including a miniconda instance, Redis, pyABC, tumor2d, and this very repository.
It installs everything to a local conda environment slad, which can be activated via start_env.sh
.
- The slad module contains the test problems and some utility functions. It must be installed as mentioned above.
- The study execution scripts are under
scripts_learn
. - Particularly, these are
run_all_useall.py
to run the first five model analyses, andscripts_robust/run_tumor_noisy.py
to run the tumor model analysis (in another folder for no good reason). - These generate SQLite databases under
data_learn
anddata_robust
(for tumor). For each run, a separate database is created. If one exists already, the corresponding run is skipped. - The scripts expect to be run with a set-up Redis server. The whole process
of server and worker setup and analysis script execution can be automatized
via the
run.sh
command. An example call would bebash run.sh --port=9204 --nodes=2 --file=scripts_robust/run_all.py --time=24:00:00 --name=name1
. run.sh
creates log files inout_...
folders.- Further, there are various scripts for detailed result inspection. These are not necessarily maintained.
- The figure generation scripts are in
figure_scripts_learn
and generate the files underfigures_learn
. - They require the data under
data_...
to exist.
- The data are in folders
data_...
and generated by the correspondingscripts_...
scripts. - The data underlying the figures used in the manuscript are not contained in the online repository due to their size, however are available via a snapshot on Zenodo.