Is it possible to run Parallel Computing inside a GUI with more than two cores?

Hi,
i've spent some time building a nice little GUI for measurement evaluation of INCA files.
Before building that GUI, I wrote a script for my computations using the Parallel Computing Toolbox. I started my workers using
N = 4;
myCluster=parcluster('local');
myCluster.NumWorkers=N;
parpool(myCluster,N);
to make sure that all 4 CPUs were being used. So far so good everything worked fine.
Now when I try to run that script by calling it via a pushbutton, it suddenly uses 2 workers only. It doesn't change anything if I start the parallel pool manually before using the GUI or if i embed the code above inside the script or the GUI callback function. The job manager tells me that 4 workers are online and working but the symbol on the bottom left only shows 2 of 4 green bars and CPU usage is only at about 50%. When starting everything without the GUI, there is roughly 95% CPU usage and all 4 bars are green.
Do you guys know any solution?
Another issue is that the workers slow down their computations after a couple of days. It looks like single cores even stop working (according to CPU usage). Iteration time of the parfor loop increases from 2 hours to 3 and more.
Thanks in advance :)

Answers (0)

Categories

Find more on Programming in Help Center and File Exchange

Asked:

on 23 Mar 2016

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!