Skip to contents

This function is most useful to simulate the posterior distribution for a single model in parallel in one machine. This function is not used when calibrating the model and not useful for parallelization across multiple nodes.

Usage

R6Experiment_run(
  self,
  n_cores,
  parallel,
  cluster_eval_script = NULL,
  model_from_cluster_eval,
  cluster_type = "PSOCK",
  packages = NULL,
  ...
)

Arguments

self

experiment object

n_cores

number of cores to use

parallel

whether to evaluate run in parallel

cluster_eval_script

path to script that instantiates necessary functions. this will often mean sourcing functions external to the package and loading dependencies for the model. needed if parallel = T

model_from_cluster_eval

T if model is instantiated in the cluter eval scripts, F otherwise. Use T if using models that need compilation (like odin) and F otherwise.

cluster_type

either "FORK" or "PSOCK".

packages

character vector of packages to be loaded before running the model in paralle.

...

additional parameters to be passed to the model simulation function.

Value

results data.frame from all simulations in parallel