MATLAB PARALLEL COMPUTING TOOLBOX - S Podręcznik Użytkownika Strona 214

  • Pobierz
  • Dodaj do moich podręczników
  • Drukuj
Przeglądanie stron 213
7 Program Independent Jobs
7-6
Fetch the Job’s Results
The results of each task’s evaluation are stored in the task object’s OutputArguments
property as a cell array. After waiting for the job to complete, use the function
fetchOutputs to retrieve the results from all the tasks in the job.
wait(job1)
results = fetchOutputs(job1);
Display the results from each task.
results{1:5}
0.9501 0.4860 0.4565
0.2311 0.8913 0.0185
0.6068 0.7621 0.8214
0.4447 0.9218 0.4057
0.6154 0.7382 0.9355
0.7919 0.1763 0.9169
0.4103 0.3529 0.1389
0.8936 0.8132 0.2028
0.0579 0.0099 0.1987
0.6038 0.0153 0.9318
0.2722 0.7468 0.4660
0.1988 0.4451 0.4186
0.8462 0.6721 0.6813
0.5252 0.8381 0.3795
0.2026 0.0196 0.8318
After the job is complete, you can repeat the commands to examine the updated status of
the cluster, job, and task objects:
c
job1
job1.Tasks
Local Cluster Behavior
The local scheduler runs in the MATLAB client session, so you do not have to start any
separate scheduler or MJS process for the local scheduler. When you submit a job for
Przeglądanie stron 213
1 2 ... 209 210 211 212 213 214 215 216 217 218 219 ... 655 656

Komentarze do niniejszej Instrukcji

Brak uwag