<< fetchNext | Parallel | parfeval >> |
[y1, ... , ym] = fetchOutputs(f) |
FevalFuture object
outputs
[y1, ... , ym] = fetchOutputs(f) retrieves m results from a Future array f.
fetchOutputs waits for the function associated to f to finish before retrieving results.
If fetchOutputs is called, Read property of each element in f is set to true.
Sequential version
tic()
R1 = magic(5000);
R2 = magic(5000);
toc()
size(R1)
Parallel version
b = backgroundPool()
tic()
fptr = str2func('magic');
f1 = parfeval(b, fptr, 1, 5000);
f2 = parfeval(b, fptr, 1, 5000);
b
r1 = fetchOutputs(f1);
r2 = fetchOutputs(f2);
toc()
size(r1)
f1
f2
parfeval, backgroundPool, fetchNext.
Version | Description |
---|---|
1.0.0 | initial version |
Allan CORNET