并行运行顺序matlab代码

时间:2015-01-13 23:40:46

标签: matlab parallel-processing nested-loops

我曾尝试使用parpoolparfor在Matlab中运行此嵌套循环,但由于嵌套循环变量的定义方式,它一直给出错误。有人可以帮帮我吗?

for(a=1:size(bench,1))
    for(d=1:size(bench,2))
        allGuesses = sampleModel(BNmodel_loo(a), bench(a,d).micaNorm, samples);

        predTable((index):(index+samples-1),:) = allGuesses(:,(BNmodel_loo(a).pca.length+1):end);

        dataSetId(index:(index+samples-1)) = d;
        appNames(index:(index+samples-1)) = bench(a,d).application;

        index = index+samples;
    end
end

0 个答案:

没有答案