User`s guide

Program Independent Jobs for a Generic Scheduler
7-21
Program Independent Jobs for a Generic Scheduler
In this section...
“Overview” on page 7-21
“MATLAB Client Submit Function” on page 7-22
“Example — Write the Submit Function” on page 7-25
“MATLAB Worker Decode Function” on page 7-27
“Example — Write the Decode Function” on page 7-29
“Example — Program and Run a Job in the Client” on page 7-29
“Supplied Submit and Decode Functions” on page 7-33
“Manage Jobs with Generic Scheduler” on page 7-34
“Summary” on page 7-37
Overview
Parallel Computing Toolbox software provides a generic interface that lets you interact
with third-party schedulers, or use your own scripts for distributing tasks to other nodes
on the cluster for evaluation.
Because each job in your application is comprised of several tasks, the purpose of your
scheduler is to allocate a cluster node for the evaluation of each task, or to distribute
each task to a cluster node. The scheduler starts remote MATLAB worker sessions on
the cluster nodes to evaluate individual tasks of the job. To evaluate its task, a MATLAB
worker session needs access to certain information, such as where to find the job and
task data. The generic scheduler interface provides a means of getting tasks from your
Parallel Computing Toolbox client session to your scheduler and thereby to your cluster
nodes.
To evaluate a task, a worker requires five parameters that you must pass from the client
to the worker. The parameters can be passed any way you want to transfer them, but
because a particular one must be an environment variable, the examples in this section
pass all parameters as environment variables.