The assignment of workers to cores
21 次查看(过去 30 天)
显示 更早的评论
Hello, we are planning to buy an MDSC of 128 workers. In running a parallel job of 128 workers, what is the minimum number of cores should there be in the hardware platform that I am going to use? How many workers can I assign to each core of the machine at the maximum ? Would appreciate your answer. Thanks
0 个评论
回答(2 个)
Kojiro Saito
2018-2-21
编辑:Kojiro Saito
2018-2-21
It is possible to run more workers than the number of CPU cores, for example, 128 workers on 1 CPU core, but it would not make the performance better.
Please see this MDCS System Requirments. It says "Maximum of 1 MATLAB worker per CPU core is recommended." So, assume you want to obtain 128 MDCS workers, recommended CPU cores are more than 128.
0 个评论
Halil Eyyuboglu
2018-2-26
3 个评论
Kojiro Saito
2019-9-24
You can change NumThreads by editing parcluster object. Here is an example.
c = parcluster('myMjsProfile'); % myMjsProfile is a cluster profile name
% Change NumThreads from 1 to 2
c.NumThreads = 2;
% Optional. You can save the cluster profile
saveProfile(c)
% Open parpool using this cluster profile
p = parpool(c);
% Do parfor job
parfor n=1:c.NumWorkers
% ...
% ...
end
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Parallel Computing Fundamentals 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!