Skip to main content

Python bindings for MPI

Project description

This package provides Python bindings for the Message Passing Interface (MPI) standard. It is implemented on top of the MPI specification and exposes an API which grounds on the standard MPI-2 C++ bindings.

Features

This package supports:

  • Convenient communication of any picklable Python object

    • point-to-point (send & receive)

    • collective (broadcast, scatter & gather, reductions)

  • Fast communication of Python object exposing the Python buffer interface (NumPy arrays, builtin bytes/string/array objects)

    • point-to-point (blocking/nonbloking/persistent send & receive)

    • collective (broadcast, block/vector scatter & gather, reductions)

  • Process groups and communication domains

    • Creation of new intra/inter communicators

    • Cartesian & graph topologies

  • Parallel input/output:

    • read & write

    • blocking/nonbloking & collective/noncollective

    • individual/shared file pointers & explicit offset

  • Dynamic process management

    • spawn & spawn multiple

    • accept/connect

    • name publishing & lookup

  • One-sided operations

    • remote memory access (put, get, accumulate)

    • passive target syncronization (start/complete & post/wait)

    • active target syncronization (lock & unlock)

Install

Once you have a working MPI implementation and the mpicc compiler wrapper is on your search path, you can install this package using pip:

$ python -m pip install mpi4py

You can also install the in-development version of mpi4py using pip:

$ python -m pip install git+https://github.com/mpi4py/mpi4py

or:

$ python -m pip install https://github.com/mpi4py/mpi4py/tarball/master

You can also install it directly on Fedora (as well as RHEL and their derivatives using the EPEL software repository)

  • using dnf and the mpich package on x86_64:

    $ dnf install mpi4py-mpich
  • using dnf and the openmpi package on x86_64:

    $ dnf install mpi4py-openmpi

Please remember to load the correct module for your choosen MPI environment

  • for mpich package on x86_64 do:

    $ module load mpi/mpich-x86_64
    $ python -c "import mpi4py"
  • for openmpi package on x86_64 do:

    $ module load mpi/openmpi-x86_64
    $ python -c "import mpi4py"

Citations

If MPI for Python been significant to a project that leads to an academic publication, please acknowledge that fact by citing the project.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mpi4py-3.1.0.tar.gz (2.4 MB view hashes)

Uploaded Source

Built Distributions

mpi4py-3.1.0-cp39-cp39-win_amd64.whl (537.9 kB view hashes)

Uploaded CPython 3.9 Windows x86-64

mpi4py-3.1.0-cp39-cp39-win32.whl (440.1 kB view hashes)

Uploaded CPython 3.9 Windows x86

mpi4py-3.1.0-cp38-cp38-win_amd64.whl (544.8 kB view hashes)

Uploaded CPython 3.8 Windows x86-64

mpi4py-3.1.0-cp38-cp38-win32.whl (446.8 kB view hashes)

Uploaded CPython 3.8 Windows x86

mpi4py-3.1.0-cp37-cp37m-win_amd64.whl (518.3 kB view hashes)

Uploaded CPython 3.7m Windows x86-64

mpi4py-3.1.0-cp37-cp37m-win32.whl (433.2 kB view hashes)

Uploaded CPython 3.7m Windows x86

mpi4py-3.1.0-cp36-cp36m-win_amd64.whl (515.7 kB view hashes)

Uploaded CPython 3.6m Windows x86-64

mpi4py-3.1.0-cp36-cp36m-win32.whl (432.8 kB view hashes)

Uploaded CPython 3.6m Windows x86

mpi4py-3.1.0-cp35-cp35m-win_amd64.whl (470.4 kB view hashes)

Uploaded CPython 3.5m Windows x86-64

mpi4py-3.1.0-cp35-cp35m-win32.whl (385.7 kB view hashes)

Uploaded CPython 3.5m Windows x86

mpi4py-3.1.0-cp27-cp27m-win_amd64.whl (481.0 kB view hashes)

Uploaded CPython 2.7m Windows x86-64

mpi4py-3.1.0-cp27-cp27m-win32.whl (402.6 kB view hashes)

Uploaded CPython 2.7m Windows x86

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page