The development of BatchJobs and BatchExperiments is discontinued because of the following reasons:
BatchJobs and BatchExperiments will remain on CRAN, but new features are unlikely to be ported back.
ClusterFunctionsMulticore
now uses the parallel package for multicore execution. ClusterFunctionsSSH
can still be used to emulate a scheduler-like system which respects the work load on the local machine.job.id
. This way, return values can be joined together easily and efficient (see this help page for some examples).static
and dynamic
to the more intuitive data
and fun
. Thus, algorithm function should have the formal arguments job
, data
and instance
.makeDesign
has been removed. Parameters can be defined by just passing a data.frame
or data.table
to addExperiments. For exhaustive designs, use expand.grid()
or data.table::CJ()
.Rscript -e 'batchtools::doJobCollection(<filename>)'
. There is no intermediate R source file like in BatchJobs.JobCollection
can be accessed while brewing the template.job.name
is now job.hash
.resoures
of submitJobs.ClusterFunctionsDocker
.ClusterFunctions
are now more flexible in general as they can define hook functions which will be called at certain events. ClusterFunctionsDocker is an example use case which implements a housekeeping routine. This routine is called every time before a job is about to get submitted to the scheduler (in the case: the Docker Swarm) via the hook pre.submit
and every time directly after the registry synchronized jobs stored on the file system via the hook post.sync
.The following table assists in porting to batchtools by mapping BatchJobs/BatchExperiments functions to their counterparts in batchtools. The table does not cover functions which are (a) used only internally in BatchJobs and (b) functions which have not been renamed.
BatchJobs | batchtools |
---|---|
addRegistryPackages |
Set reg$packages or reg$namespaces , call saveRegistry |
addRegistrySourceDirs |
- |
addRegistrySourceFiles |
Set reg$source , call saveRegistry |
batchExpandGrid |
batchMap: batchMap(..., args = CJ(x = 1:3, y = 1:10)) |
batchMapQuick |
btmapply |
batchReduceResults |
- |
batchUnexport |
batchExport |
filterResults |
- |
getJobIds |
findJobs |
getJobInfo |
getJobStatus |
getJob |
makeJob |
getJobParamDf |
getJobPars |
loadResults |
reduceResultsList |
reduceResultsDataFrame |
reduceResultsDataTable |
reduceResultsMatrix |
reduceResultsList + do.call(rbind, res) |
reduceResultsVector |
reduceResultsDataTable |
setJobFunction |
- |
setJobNames |
- |
showStatus |
getStatus |