comparison toolboxes/MIRtoolbox1.3.2/MIRToolbox/mirparallel.m @ 0:e9a9cd732c1e tip

first hg version after svn
author wolffd
date Tue, 10 Feb 2015 15:05:51 +0000
parents
children
comparison
equal deleted inserted replaced
-1:000000000000 0:e9a9cd732c1e
1 function p = mirparallel(s)
2 % mirparallel(1) toggles on parallel processing: (BETA)
3 % When ?Folder? or ?Folders? is used, several audio files can be analysed
4 % in parallel using several parallel Matlab sessions running on the
5 % different processors and/or processor cores of your computer.
6 % (Requires MathWorks? Parallel Computing Toolbox.)
7 % mirparallel(0) toggles back off parallel processing.
8
9 persistent mir_parallel
10
11 if nargin
12 warning('MIRtoolbox Parallel computing is currently in Beta Version.');
13 if s
14 try
15 matlabpool size;
16 catch
17 mirerror('mirparallel','Are you sure Parallel Processing Toolbox is installed?');
18 end
19 end
20 mir_parallel = s;
21 else
22 if isempty(mir_parallel)
23 mir_parallel = 0;
24 end
25 end
26
27 p = mir_parallel;