How matlabpool does work??
26 次查看(过去 30 天)
显示 更早的评论
Hi all
I am a new Matlab users and actually I would like to optimize a simple algorithm with parallel computing. By optimize I mean that getting the results faster than waiting for some hours for a merely launched algorithm... Could matlabpool helps me out??
Thx in advance
Ag Vdk
5 个评论
Cedric
2013-4-10
编辑:Cedric
2013-4-10
It is worth spending 30 minutes just for setting up a local parallel configuration, because your PDE solver may be able to exploit a few workers by itself. It is not something that I've often seen though, and usually I have to work a little on my code before I can see some improvement.
If you had a Monte-Carlo simulation to run though, I'd say that you could invest a day, because each experiment is disjoint from the others and writing code that is well suited for parallelization is almost direct. It means somehow adding the code for opening the pool, replacing FOR with PARFOR, and thinking a little about how you define/store sets of parameters/solutions.
采纳的回答
Jason Ross
2013-4-10
I'd suggest looking at the documentation for Parallel Computing Toolbox to see if the tools available might help with your problem. Matlabpool (parfor/spmd) is only one way you can do things, you can also run a batch job or control your own jobs and tasks.
1 个评论
Jason Ross
2013-4-10
I also negelected to mention the other part of Parallel Computing : GPU support. I don't know if your problem can be arranged in such a way that a GPU would increase your performance, but that's another solution available.
From Cedric's comments it looks like you might have some thinking to do about how to set up your algorithm to make it amenable to parallel computing. Once you figure that part out, the one of the various methods available (parfor, spmd, job/task, batch and GPU) might show promise.
更多回答(1 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Boundary Conditions 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!