[SciPy-user] Parallel OO programming in Python.

Flavio Coelho fccoelho at gmail.com
Mon Oct 30 11:53:54 CST 2006


Hi Brian,

Can Ipython1 take advantage of multiple core cpus or SMP machines in the
same way it does for a networked cluster? It would be nice to have that
since quad-core cpu are arriving on the market and SMP machines are pretty
common already.

Thanks!

Flávio

On 10/30/06, Brian Granger <ellisonbg.net at gmail.com> wrote:
>
> > I also looked at the entry on Ipython1 and it looks really promising.
> > Did I understand correctly that Ipython1 is able to run parallel python
> > code, regardless of which "MPI for python" package one eventually uses?
>
> In principle yes.  The IPython engines have a configuration option
> that you use to import the mpi bindings of your choice.  But, to work
> properly, the import statement must cause MPI_Init() to be called.  If
> the bindings you are using don't do that, it should b easy to write a
> wrapper module that imports and also calls MPI_Init().  Also, some of
> this depends on what MPI implementation you are using.  The more
> moderns ones (like openmpi) are really nice and pretty forgiving.  The
> older ones, though, sometimes require that Python itself (not your
> script) call MPI_Init().  This is also very easy to work around.  The
> bottom line is that we can help you get it to work with whatever mpi
> binding and implementation you want.
>
> Withh that said, I highly do highly recommend mpi4py and openmpi - we
> use these regularly with ipython and it all works well.
>
> Brian
>
>
> > Giovanni
> >
> > Flavio Coelho wrote:
> > > Thank you for this post and many thanks to Fernando Perez, for the
> > > awesome tool that Ipython1 is becomming!!! I am beginning to use it
> > > today!!
> > >
> > > Flávio
> > >
> > > On 10/29/06, * Brian Granger* <ellisonbg.net at gmail.com
> > > <mailto:ellisonbg.net at gmail.com>> wrote:
> > >
> > >     > For object oriented parallel programming in Python on a single
> > >     machine I can use techniques such as Bulk Synchronous Parallelism
> > >     (BSP) or Message Passing Interface (MPI). There are mentioned some
> > >     modules and packages for Python on
> > >     > http://www.scipy.org/Topical_Software
> > >     > Article: Parallel and distributed programming.
> > >     > After reading prerequisites and limitations I thing that the
> > >     following ones could be good for me:
> > >     > PyMPI
> > >     > Pypar
> > >     > MPI for Python
> > >
> > >     I think mpi4py is the best option.  It is a very nice
> implementation
> > >     and the developer is working really hard to make it a great
> package.
> > >     Also, I don't think pympi and pypar are being developed actively
> > >     anymore.
> > >
> > >     Another thing you might check out is IPython's parallel computing
> > >     facilities that let you use mpi4py (and other mpi bindings)
> > >     interactively:
> > >
> > >     http://ipython.scipy.org/moin/Parallel_Computing
> > >
> > >     I have never used BPS, but am familiar with the model.  Can
> probably
> > >     get it working interactively with IPython as well.
> > >
> > >     Cheers,
> > >
> > >     Brian
> > >
> > >     > But I can't distinguish which one brings fewer limitations, is
> > >     efficient in application and will develop in future.
> > >     > My favorite is BSP, but I can't find a package for present SciPy
> > >     and NumPy.
> > >     >
> > >     > Could anybody give me a recommendation, which way I should go.
> > >     >
> > >     > Thanks.
> > >     > Fie Pye
> > >     >
> > >     >
> > >     >
> > >     >
> > >     > ---------------------------------------
> > >     > Máme další spot P.Čtvrtníčka. Podívejte se www.neuservis.cz
> > >     <http://www.neuservis.cz>
> > >     >
> > >     >
> > >     > _______________________________________________
> > >     > SciPy-user mailing list
> > >     > SciPy-user at scipy.org <mailto:SciPy-user at scipy.org>
> > >     > http://projects.scipy.org/mailman/listinfo/scipy-user
> > >     <http://projects.scipy.org/mailman/listinfo/scipy-user>
> > >     >
> > >     _______________________________________________
> > >     SciPy-user mailing list
> > >     SciPy-user at scipy.org <mailto:SciPy-user at scipy.org>
> > >     http://projects.scipy.org/mailman/listinfo/scipy-user
> > >
> > >
> > >
> > >
> > > --
> > > Flávio Codeço Coelho
> > > registered Linux user # 386432
> > > ---------------------------
> > > "Laws are like sausages. It's better not to see them being made."
> > > Otto von Bismark
> > >
> ------------------------------------------------------------------------
> > >
> > > _______________________________________________
> > > SciPy-user mailing list
> > > SciPy-user at scipy.org
> > > http://projects.scipy.org/mailman/listinfo/scipy-user
> > >
> > _______________________________________________
> > SciPy-user mailing list
> > SciPy-user at scipy.org
> > http://projects.scipy.org/mailman/listinfo/scipy-user
> >
> _______________________________________________
> SciPy-user mailing list
> SciPy-user at scipy.org
> http://projects.scipy.org/mailman/listinfo/scipy-user
>



-- 
Flávio Codeço Coelho
registered Linux user # 386432
---------------------------
"Laws are like sausages. It's better not to see them being made."
Otto von Bismark
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://projects.scipy.org/pipermail/scipy-user/attachments/20061030/f0706001/attachment-0001.html 


More information about the SciPy-user mailing list