[IPython-User] Passing numpy masked arrays with apply

Jesper Larsen jesper.webmail@gmail....
Thu Jan 31 15:35:31 CST 2013

Hi IPython users,

I am trying out the IPython parallel facilities. I need to pass a numpy
masked array into a function using the apply_async view method. It seems
however like it is converted to an ordinary numpy.ndarray when I do that:

import numpy as np
from IPython.parallel import Client

def foo(a):
    return a

rc = Client()
dview = rc[:]

for i in range(3):
    result = dview.apply_async(foo, np.ma.zeros((1)))
    print type(result.get()[0])

The type of the last print statement is numpy.ndarray. It should be a
masked array.

Am I doing something wrong or is this a bug?

Best regards,
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.scipy.org/pipermail/ipython-user/attachments/20130131/18beb42e/attachment.html 

More information about the IPython-User mailing list