To use the Parallel Computing Toolbox (from here on: 'PCT') with orion, you must configure your Matlab client. The page aims to provide a template of the (somewhat involved) configuration necessary to make this work.
Please be aware that you must already have a license for the PCT, and already have it installed appropriately before proceeding on this page.
The following configuration is tested on the Windows client, but fails on a Linux client at this time.
First, download the following example integration: matlab-pct-settings.zip, and unzip it to your Matlab "root directory" (example: C:\Program Files\MATLAB\R2014a). You should end up with the following:
- .../orion.settings — importable "Cluster Profile" template. Needs modification!
- .../toolbox/local/(various scripts) — integration scripts, may need minor modification for advanced uses.
NOTE: if your client 'path' does not already contain (matlabroot)/toolbox/local – you will need to add it.
Cluster Profile Configuration
Once unzipped, open Matlab and click the 'Parallel' drop-down menu item, then click on 'Manage Cluster Profiles...':
This should have opened a new window ('Cluster Profile Manager'). If you do not currently have a profile named 'orion', click on the 'Add' drop-down, and click 'Import':
Locate the 'orion.settings' file unzipped earlier into your Matlab root directory, and import it, then set the resulting profile as the default:
Now you'll need to edit the new profile and set a few paths. Select the profile and click 'Edit':
Locate the 'Submit Functions' section, and in each text box, change the last item. It should be '/home/jtowne/matlab-jobs' when you open the edit window. Make sure it points to a directory that exists AND that you have write access to. It may be most useful to create "matlab-jobs" in your own home directory on orion, and use that. Save this when finished.
Note that if you're not running the same version of Matlab as the computer labs, you'll need to modify the "Root folder of MATLAB installation" as found in the screenshot above. Simply replace the version number with the one you're using, keeping capitalization the same.
Now select the 'orion' profile and click the 'Validate' button:
The validation process (and every attempt to run a job on orion from here on) will ask you for your credentials to the cluster. You may use username/password authentication, or generate an SSH key pair and use that if you prefer. The validation tests may take some moments to run, but in the end, the results should look like this:
At this time, the "Parallel pool test (parpool)" is known to fail in a number of configurations, and should not prevent you from running batch jobs under normal circumstances.
Custom queue submission (qsub) parameters
To submit jobs with customized qsub parameters, you must edit one of the scripts included in the template configuration. For a communicating job, edit "communicatingSubmitFcn.m"; for a non-communicating job "independentSubmitFcn.m". In either file, search for "additionalSubmitArgs =", and add your customizations there.
If validation fails because "This job was submitted with version (A.B) of the Parallel Computing Toolbox. However the current MATLAB Distributed Computing Server is version (C.D)", then please see the section above about editing the "Root folder" path in the profile to match your version.