dot-setupCl: Start and/or setup a parallel cluster

Description Usage Arguments

Description

This is mostly a wrapper around several functions in the parallel package: makeCluster, clusterSetRNGStream, detectCores.

Usage

1
.setupCl(cl, numClus = NULL, outfile, sim = NULL, packages = NULL)

Arguments

cl

Either NULL, cluster, logical, or numeric. NULL returns NULL, a TRUE logical or numeric will spawn a new SOCK cluster with an "optimal" cluster number or cl cluster nodes respectively. In the three latter cases, all necessary packages and objects will be sent to each of the nodes.

numClus

The desired number of child clusters, passed to .optimalClusterNum via maxNumClusters. If not provided, cl must be provided.

outfile

The location of the log file

sim

An optional simList object; this will be used to find the packages required via setting packages = SpaDES.core::packages(sim, clean = TRUE)

packages

a character vector indicating which packages to load in the cluster. Will ignore this if the sim is provided.


PredictiveEcology/SpaDES.experiment documentation built on Dec. 3, 2019, 4:59 p.m.