How to run multiple different scripts in parallel ?
4 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
Hi,
I am trying to paralellize a large job and the best solution I can think of so far is to break it up in several different scripts and send each script to a different core. Since I can't find any information in the documentation about how to acomplish this I need to ask for help. The idea is something like this:
matlabpool open local 4
Send each of the following: script1.m, script2.m, script3.m and script4.m to a separate core for a simultaneous execution
matlabpool close
Now my question is how should the code look like in between the two matalbpool statements except the code for the four scripts ?
Thank You in advance.
Mark
0 comentarios
Respuestas (1)
Richard Brown
el 15 de Oct. de 2012
One way to do it
matlabpool open local 4
spmd
switch labindex
case 1
script1
case 2
script2
case 3
script3
case 4
script4
end
end
matlabpool close
0 comentarios
Ver también
Productos
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!