|
1 | 1 | {
|
2 | 2 | "metadata": {
|
3 |
| - "name": "P51 Example - Remote Iteration" |
| 3 | + "name": "Parallel Example - Remote Iteration" |
4 | 4 | },
|
5 | 5 | "nbformat": 3,
|
6 | 6 | "nbformat_minor": 0,
|
|
36 | 36 | ],
|
37 | 37 | "language": "python",
|
38 | 38 | "metadata": {},
|
39 |
| - "outputs": [], |
40 |
| - "prompt_number": 1 |
| 39 | + "outputs": [] |
41 | 40 | },
|
42 | 41 | {
|
43 | 42 | "cell_type": "markdown",
|
|
63 | 62 | ],
|
64 | 63 | "language": "python",
|
65 | 64 | "metadata": {},
|
66 |
| - "outputs": [], |
67 |
| - "prompt_number": 2 |
| 65 | + "outputs": [] |
68 | 66 | },
|
69 | 67 | {
|
70 | 68 | "cell_type": "heading",
|
|
97 | 95 | ],
|
98 | 96 | "language": "python",
|
99 | 97 | "metadata": {},
|
100 |
| - "outputs": [], |
101 |
| - "prompt_number": 3 |
| 98 | + "outputs": [] |
102 | 99 | },
|
103 | 100 | {
|
104 | 101 | "cell_type": "markdown",
|
|
125 | 122 | ],
|
126 | 123 | "language": "python",
|
127 | 124 | "metadata": {},
|
128 |
| - "outputs": [ |
129 |
| - { |
130 |
| - "ename": "RemoteError", |
131 |
| - "evalue": "NameError(name 'barbarbar' is not defined)", |
132 |
| - "output_type": "pyerr", |
133 |
| - "traceback": [ |
134 |
| - "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m", |
135 |
| - "\u001b[1;31mNameError\u001b[0m Traceback (most recent call last)\u001b[1;32m<ipython-input-7-0b69f8403738>\u001b[0m in \u001b[0;36m<module>\u001b[1;34m()\u001b[0m", |
136 |
| - "\u001b[1;32m----> 1\u001b[1;33m \u001b[0mfoo\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mbarbarbar\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m", |
137 |
| - "\u001b[0m\u001b[1;31mNameError\u001b[0m: name 'barbarbar' is not defined" |
138 |
| - ] |
139 |
| - }, |
140 |
| - { |
141 |
| - "output_type": "stream", |
142 |
| - "stream": "stdout", |
143 |
| - "text": [ |
144 |
| - "Oops! Didn't catch <Remote[3]:NameError(name 'barbarbar' is not defined)>\n" |
145 |
| - ] |
146 |
| - } |
147 |
| - ], |
148 |
| - "prompt_number": 4 |
| 125 | + "outputs": [] |
149 | 126 | },
|
150 | 127 | {
|
151 | 128 | "cell_type": "markdown",
|
|
181 | 158 | ],
|
182 | 159 | "language": "python",
|
183 | 160 | "metadata": {},
|
184 |
| - "outputs": [], |
185 |
| - "prompt_number": 5 |
| 161 | + "outputs": [] |
186 | 162 | },
|
187 | 163 | {
|
188 | 164 | "cell_type": "markdown",
|
|
206 | 182 | ],
|
207 | 183 | "language": "python",
|
208 | 184 | "metadata": {},
|
209 |
| - "outputs": [ |
210 |
| - { |
211 |
| - "output_type": "stream", |
212 |
| - "stream": "stdout", |
213 |
| - "text": [ |
214 |
| - "caught NameError\n", |
215 |
| - "safe and sound\n" |
216 |
| - ] |
217 |
| - } |
218 |
| - ], |
219 |
| - "prompt_number": 48 |
| 185 | + "outputs": [] |
220 | 186 | },
|
221 | 187 | {
|
222 | 188 | "cell_type": "markdown",
|
|
262 | 228 | ],
|
263 | 229 | "language": "python",
|
264 | 230 | "metadata": {},
|
265 |
| - "outputs": [], |
266 |
| - "prompt_number": 49 |
| 231 | + "outputs": [] |
267 | 232 | },
|
268 | 233 | {
|
269 | 234 | "cell_type": "markdown",
|
|
280 | 245 | ],
|
281 | 246 | "language": "python",
|
282 | 247 | "metadata": {},
|
283 |
| - "outputs": [], |
284 |
| - "prompt_number": 50 |
| 248 | + "outputs": [] |
285 | 249 | },
|
286 | 250 | {
|
287 | 251 | "cell_type": "markdown",
|
|
298 | 262 | ],
|
299 | 263 | "language": "python",
|
300 | 264 | "metadata": {},
|
301 |
| - "outputs": [], |
302 |
| - "prompt_number": 6 |
| 265 | + "outputs": [] |
303 | 266 | },
|
304 | 267 | {
|
305 | 268 | "cell_type": "markdown",
|
|
317 | 280 | ],
|
318 | 281 | "language": "python",
|
319 | 282 | "metadata": {},
|
320 |
| - "outputs": [ |
321 |
| - { |
322 |
| - "output_type": "stream", |
323 |
| - "stream": "stdout", |
324 |
| - "text": [ |
325 |
| - "Engine IDs: [0, 1, 2, 3]\n" |
326 |
| - ] |
327 |
| - } |
328 |
| - ], |
329 |
| - "prompt_number": 8 |
| 283 | + "outputs": [] |
330 | 284 | },
|
331 | 285 | {
|
332 | 286 | "cell_type": "code",
|
|
337 | 291 | ],
|
338 | 292 | "language": "python",
|
339 | 293 | "metadata": {},
|
340 |
| - "outputs": [], |
341 |
| - "prompt_number": 9 |
| 294 | + "outputs": [] |
342 | 295 | },
|
343 | 296 | {
|
344 | 297 | "cell_type": "code",
|
|
348 | 301 | ],
|
349 | 302 | "language": "python",
|
350 | 303 | "metadata": {},
|
351 |
| - "outputs": [ |
352 |
| - { |
353 |
| - "output_type": "pyout", |
354 |
| - "prompt_number": 10, |
355 |
| - "text": [ |
356 |
| - "<AsyncMapResult: load_data>" |
357 |
| - ] |
358 |
| - } |
359 |
| - ], |
360 |
| - "prompt_number": 10 |
| 304 | + "outputs": [] |
361 | 305 | },
|
362 | 306 | {
|
363 | 307 | "cell_type": "code",
|
|
367 | 311 | ],
|
368 | 312 | "language": "python",
|
369 | 313 | "metadata": {},
|
370 |
| - "outputs": [ |
371 |
| - { |
372 |
| - "output_type": "pyout", |
373 |
| - "prompt_number": 11, |
374 |
| - "text": [ |
375 |
| - "['data', 'data', 'data', 'data']" |
376 |
| - ] |
377 |
| - } |
378 |
| - ], |
379 |
| - "prompt_number": 11 |
| 314 | + "outputs": [] |
380 | 315 | },
|
381 | 316 | {
|
382 | 317 | "cell_type": "code",
|
|
389 | 324 | ],
|
390 | 325 | "language": "python",
|
391 | 326 | "metadata": {},
|
392 |
| - "outputs": [ |
393 |
| - { |
394 |
| - "output_type": "stream", |
395 |
| - "stream": "stdout", |
396 |
| - "text": [ |
397 |
| - "[4, 5, 6, 7]\n", |
398 |
| - "[3, 5, 7, 9, 11, 13, 15, 17]" |
399 |
| - ] |
400 |
| - }, |
401 |
| - { |
402 |
| - "output_type": "stream", |
403 |
| - "stream": "stdout", |
404 |
| - "text": [ |
405 |
| - "\n", |
406 |
| - "[2, 5, 8, 11, 14, 17, 20, 23, 26, 29, 32, 35]" |
407 |
| - ] |
408 |
| - }, |
409 |
| - { |
410 |
| - "output_type": "stream", |
411 |
| - "stream": "stdout", |
412 |
| - "text": [ |
413 |
| - "\n", |
414 |
| - "[1, 5, 9, 13, 17, 21, 25, 29, 33, 37, 41, 45, 49, 53, 57, 61]" |
415 |
| - ] |
416 |
| - }, |
417 |
| - { |
418 |
| - "output_type": "stream", |
419 |
| - "stream": "stdout", |
420 |
| - "text": [ |
421 |
| - "\n" |
422 |
| - ] |
423 |
| - } |
424 |
| - ], |
425 |
| - "prompt_number": 12 |
| 327 | + "outputs": [] |
426 | 328 | },
|
427 | 329 | {
|
428 | 330 | "cell_type": "markdown",
|
|
442 | 344 | ],
|
443 | 345 | "language": "python",
|
444 | 346 | "metadata": {},
|
445 |
| - "outputs": [ |
446 |
| - { |
447 |
| - "output_type": "stream", |
448 |
| - "stream": "stdout", |
449 |
| - "text": [ |
450 |
| - "Locally merge the remote sets:\n", |
451 |
| - "[1, 2, 3, 4, 5, 5, 5, 5, 6, 7, 7, 8, 9, 9, 11, 11, 13, 13, 14, 15, 17, 17, 17, 20, 21, 23, 25, 26, 29, 29, 32, 33, 35, 37, 41, 45, 49, 53, 57, 61]" |
452 |
| - ] |
453 |
| - }, |
454 |
| - { |
455 |
| - "output_type": "stream", |
456 |
| - "stream": "stdout", |
457 |
| - "text": [ |
458 |
| - "\n" |
459 |
| - ] |
460 |
| - } |
461 |
| - ], |
462 |
| - "prompt_number": 13 |
| 347 | + "outputs": [] |
463 | 348 | },
|
464 | 349 | {
|
465 | 350 | "cell_type": "heading",
|
|
492 | 377 | ],
|
493 | 378 | "language": "python",
|
494 | 379 | "metadata": {},
|
495 |
| - "outputs": [ |
496 |
| - { |
497 |
| - "output_type": "stream", |
498 |
| - "stream": "stdout", |
499 |
| - "text": [ |
500 |
| - "Local data:\n", |
501 |
| - "[4, 5, 6, 7]\n", |
502 |
| - "[3, 5, 7, 9, 11, 13, 15, 17]\n", |
503 |
| - "[2, 5, 8, 11, 14, 17, 20, 23, 26, 29, 32, 35]\n", |
504 |
| - "[1, 5, 9, 13, 17, 21, 25, 29, 33, 37, 41, 45, 49, 53, 57, 61]\n", |
505 |
| - "Sorted:\n", |
506 |
| - "[1, 2, 3, 4, 5, 5, 5, 5, 6, 7, 7, 8, 9, 9, 11, 11, 13, 13, 14, 15, 17, 17, 17, 20, 21, 23, 25, 26, 29, 29, 32, 33, 35, 37, 41, 45, 49, 53, 57, 61]\n", |
507 |
| - "local == remote: True\n" |
508 |
| - ] |
509 |
| - } |
510 |
| - ], |
511 |
| - "prompt_number": 14 |
| 380 | + "outputs": [] |
| 381 | + }, |
| 382 | + { |
| 383 | + "cell_type": "code", |
| 384 | + "collapsed": false, |
| 385 | + "input": [], |
| 386 | + "language": "python", |
| 387 | + "metadata": {}, |
| 388 | + "outputs": [] |
512 | 389 | }
|
513 | 390 | ],
|
514 | 391 | "metadata": {}
|
|
0 commit comments