A Collection of MATLAB Batch Scripts And Utility M-files

File Name Description
batch.zip zip file of current folder
README.html this file
getbev.m m-file to return batch environment vars
isBatch.m whether code is running in batch
mbatch Simple MATLAB batch script
myApp.m Sample Application m-file
pnbatch Partial Node Embarrassingly parallel Batch job
run_matlab_aj MATLAB Serial Batch script for Array Job
run_matlab_job MATLAB Serial Batch job script
run_matlab_job2 enhanced MATLAB Serial Batch job script
run_matlab_pct_aj MATLAB PCT Batch script for Array Job
run_matlab_pct_job MATLAB PCT Batch job script
runBatchJob.m MATLAB m-file for more robust batch jobs
run_standalone_job MATLAB Standalone Batch job script
runjobs Script to submit a series of jobs via qsub
wnbatch Whole Node Embarrassingly parallel Batch job

Where to Store Them

Either use addpath or unzip from ~/matlab (folder where startup.m resides) for access from any user folder.

Types of MATLAB Batch Jobs

  1. Running Serial (single-core) MATLAB Batch Jobs
    scc1$ qsub ./mbatch
  2. Running Parallel (multicore) MATLAB Batch Jobs
    scc1$ qsub -pe omp 4 ./run_matlab_pct_job
  3. Running Pre-compiled MATLAB code (needs no licenses)
    scc1$ qsub ./run_standalone_job
    More details are available in How To Create & Run MATLAB Standalone Executable.

  4. Running Implicitly Parallel (multithreaded) MATLAB Batch Jobs
    scc1$ qsub -pe omp 12 ./wnbatch
    scc1$ qsub -pe omp 7 ./pnbatch
For more details, see: Running MATLAB Batch Jobs on the SCC
Kadin Tseng, Research Computing Services, IS&T, Boston University
Created  : January, 2015
Modified : March, 2015