Parallel computing in a multicore processor.

2 views (last 30 days)
Hi to all,
I have a block of code reading a huge dataset and analyze it with an appropriate code. I use a supercomputer (32core), and tend to do my huge job with MATLAB parallel computing toolbox (parfor maybe). in this work, I read the data with textscan() function and using a for loop I do needed analyzes. It means that I can use parfor because each step in for loop is independent from other ones. But the problem is here that I use structure and parfore does not allow me to use structure. Also, in another part I use a cell array which its size is undetermined so I cannot predefine it, and because of that I used clear cell before using it for the next step. this cleaning assures me of creating a totally new cell in each step and with that data wont interact with each other. The second problem is here that parfor also does not allow me to use clean. I have two questiones: 1-what is possible solution to this problem, and 2-is there another way to use all cores in my supercomputer? such as a laucher, which softwares such as FLUENT use that.
I appreciate your guide in advance.

Accepted Answer

Shashank Prasanna
Shashank Prasanna on 8 Jul 2013
You may benefit more from using SPMD (single program multiple data) instead of parfor. There are several advantages to using SPMD, here is an example in the documentation that outlines SPMD:

More Answers (0)

Categories

Find more on MATLAB Parallel Server in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!