from IPython import parallel rc = parallel.Client() ref = parallel.Reference %precision 2 rc.ids dview = rc[:] dview dview.scatter('rank', rc.ids, flatten=True) %%px import numpy as np A = np.random.random((rank+1,100)) B = np.random.random((100,rank+1)) lview = rc.load_balanced_view() ref = parallel.Reference C_async = lview.apply(ref('A.dot'), ref('B')) C_async C_async.get() from IPython.display import display async_dots = [ lview.apply(ref('A.dot'), ref('B')) for id in rc.ids ] for ar in async_dots: C = ar.get() print "A.dot(B) on engine %s:" % ar.engine_id print C.shape print C async_dots = [ lview.apply_async(lambda : A.dot(B)) for id in rc.ids ] for ar in async_dots: C = ar.get() print "A.dot(B) on engine %s:" % ar.engine_id print C.shape print C