base.procgrid {pbdBASE} | R Documentation |
"Optimal" process grid when nprow and npcol are empty
base.procgrid(nprocs)
nprocs |
Number of processors. |
For advanced users only. See pbdDMAT for high-level functions.
A list contains nprow and npcol.
spmd.code <- " suppressMessages(library(pbdMPI)) suppressMessages(library(pbdBASE)) init.grid() opt <- base.procgrid(4) comm.print(opt) opt <- base.procgrid(6) comm.print(opt) opt <- base.procgrid(8) comm.print(opt) finalize() " pbdMPI::execmpi(spmd.code = spmd.code, nranks = 1L)