[IPython-User] IPython.parallel: Sync namespace between engines

Johann Rohwer jr@sun.ac...
Tue Jan 29 06:45:30 CST 2013


On Tuesday 29 January 2013 13:37:34 Florian M. Wagner wrote:
> I am currently trying to parallelize a piece of code using IPython's
> parallel version of map. It works fine for simple examples, but the
> function I would like to distribute falls back upon some globally
> declared variables, which the engines are not aware of. Is there a
> way to sync the namespace of all engines analogously to
> sync_imports or what would you suggest?

I'm not aware of whether it is possible to sync the namespaces 
completely and whether this useful or feasible at all (do we want the 
controller and client objects to be available on all the engines?). 
However, you can easily push those global variables the function 
requires to all the engines with the dview.push() method.

Johann
E-pos vrywaringsklousule

Hierdie e-pos mag vertroulike inligting bevat en mag regtens geprivilegeerd wees en is slegs bedoel vir die persoon aan wie dit geadresseer is. Indien u nie die bedoelde ontvanger is nie, word u hiermee in kennis gestel dat u hierdie dokument geensins mag gebruik, versprei of kopieer nie. Stel ook asseblief die sender onmiddellik per telefoon in kennis en vee die e-pos uit. Die Universiteit aanvaar nie aanspreeklikheid vir enige skade, verlies of uitgawe wat voortspruit uit hierdie e-pos en/of die oopmaak van enige lês aangeheg by hierdie e-pos nie.

E-mail disclaimer

This e-mail may contain confidential information and may be legally privileged and is intended only for the person to whom it is addressed. If you are not the intended recipient, you are notified that you may not use, distribute or copy this document in any manner whatsoever. Kindly also notify the sender immediately by telephone, and delete the e-mail. The University does not accept liability for any damage, loss or expense arising from this e-mail and/or accessing any files attached to this e-mail.


More information about the IPython-User mailing list