MATLAB: How do you tell local workers to use the session of Simulink which is already open

job schedulerlinmodParallel Computing Toolboxparameter sweepsimulinkworker

I am doing an asynchronous parameter sweep of a Simulink model. Each time the user adds another parameter set, a job is created to perform the frequency response, then added to the queue. Unfortunately, the worker reopens Simulink and reloads the models at every instance of the job.
How do you share a single Simulink session between jobs?
The jobs are not performed in parallel.

Best Answer

MATLAB workers are completely separate processes, and as such, cannot share Simulink data.
One option you have is to use MATLABPOOL and PARFOR - that way, you could load the model once on each worker after opening the MATLABPOOL, and then run a PARFOR loop with the new parameters. Unfortunately, there is no option to run a PARFOR loop or an SPMD block asynchronously.