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

You can install mpi4py from its source distribution using pip:

$ python -m pip install mpi4py

You can also install the in-development version with:

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

or:

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

Installing from source requires compilers and a working MPI implementation. The mpicc compiler wrapper is looked for on the executable search path (PATH environment variable). Alternatively, you can set the MPICC environment variable to the full path or command corresponding to the MPI-aware C compiler.

The conda-forge community provides ready-to-use binary packages from an ever growing collection of software libraries built around the multi-platform conda package manager. Three MPI implementations are available on conda-forge: Open MPI (Linux and macOS), MPICH (Linux and macOS), and Microsoft MPI (Windows). You can install mpi4py and your preferred MPI implementation using conda:

* to use MPICH do::

$ conda install -c conda-forge mpi4py mpich

  • to use Open MPI do:

    $ conda install -c conda-forge mpi4py openmpi
  • to use Microsoft MPI do:

    $ conda install -c conda-forge mpi4py msmpi

MPICH and many of its derivatives are ABI-compatible. You can provide the package specification mpich=X.Y.*=external_* (where X and Y are the major and minor version numbers) to request the conda package manager to use system-provided MPICH (or derivative) libraries.

The openmpi package on conda-forge has built-in CUDA support, but it is disabled by default. To enable it, follow the instruction outlined during conda install. Additionally, UCX support is also available once the ucx package is installed.

On Fedora Linux systems (as well as RHEL and their derivatives using the EPEL software repository), you can install binary packages with the system package manager:

* using ``dnf`` and the ``mpich`` package::

$ sudo dnf install python3-mpi4py-mpich

  • using dnf and the openmpi package:

    $ sudo dnf install python3-mpi4py-openmpi

Please remember to load the correct MPI module for your chosen MPI implementation

  • for the mpich package do:

    $ module load mpi/mpich-$(arch)
    $ python -c "from mpi4py import MPI"
  • for the openmpi package do:

    $ module load mpi/openmpi-$(arch)
    $ python -c "from mpi4py import MPI"

On Ubuntu Linux and Debian Linux systems, binary packages are available for installation using the system package manager:

$ sudo apt install python3-mpi4py

Note that on Ubuntu/Debian systems, the mpi4py package uses Open MPI. To use MPICH, install the libmpich-dev and python3-dev packages (and any other required development tools). Afterwards, install mpi4py from sources using pip.

macOS users can install mpi4py using the Homebrew package manager:

$ brew install mpi4py

Note that the Homebrew mpi4py package uses Open MPI. Alternatively, install the mpich package and next install mpi4py from sources using pip.

Windows users can install mpi4py from binary wheels hosted on the Python Package Index (PyPI) using pip:

$ python -m pip install mpi4py

Windows wheels require a separate, system-wide installation of the Microsoft MPI runtime.

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.2.tar.gz (2.5 MB view details)

Uploaded Source

Built Distributions

mpi4py-3.1.2-cp310-cp310-win_amd64.whl (539.7 kB view details)

Uploaded CPython 3.10 Windows x86-64

mpi4py-3.1.2-cp310-cp310-win32.whl (442.0 kB view details)

Uploaded CPython 3.10 Windows x86

mpi4py-3.1.2-cp39-cp39-win_amd64.whl (539.7 kB view details)

Uploaded CPython 3.9 Windows x86-64

mpi4py-3.1.2-cp39-cp39-win32.whl (442.0 kB view details)

Uploaded CPython 3.9 Windows x86

mpi4py-3.1.2-cp38-cp38-win_amd64.whl (546.6 kB view details)

Uploaded CPython 3.8 Windows x86-64

mpi4py-3.1.2-cp38-cp38-win32.whl (448.8 kB view details)

Uploaded CPython 3.8 Windows x86

mpi4py-3.1.2-cp37-cp37m-win_amd64.whl (520.1 kB view details)

Uploaded CPython 3.7m Windows x86-64

mpi4py-3.1.2-cp37-cp37m-win32.whl (434.9 kB view details)

Uploaded CPython 3.7m Windows x86

mpi4py-3.1.2-cp36-cp36m-win_amd64.whl (517.4 kB view details)

Uploaded CPython 3.6m Windows x86-64

mpi4py-3.1.2-cp36-cp36m-win32.whl (434.4 kB view details)

Uploaded CPython 3.6m Windows x86

mpi4py-3.1.2-cp35-cp35m-win_amd64.whl (472.2 kB view details)

Uploaded CPython 3.5m Windows x86-64

mpi4py-3.1.2-cp35-cp35m-win32.whl (387.4 kB view details)

Uploaded CPython 3.5m Windows x86

mpi4py-3.1.2-cp27-cp27m-win_amd64.whl (482.9 kB view details)

Uploaded CPython 2.7m Windows x86-64

mpi4py-3.1.2-cp27-cp27m-win32.whl (404.3 kB view details)

Uploaded CPython 2.7m Windows x86

File details

Details for the file mpi4py-3.1.2.tar.gz.

File metadata

  • Download URL: mpi4py-3.1.2.tar.gz
  • Upload date:
  • Size: 2.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2.tar.gz
Algorithm Hash digest
SHA256 40dd546bece8f63e1131c3ceaa7c18f8e8e93191a762cd446a8cfcf7f9cce770
MD5 f4b13f8850507b30c8d0d28c987db8b1
BLAKE2b-256 a65dd58de70175c333255120a25abde95dd119af769bfa4c7ab4dd688b2af15f

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 539.7 kB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 e253ec95134b9a6e8ee5b68301e27abce76d3bfa694a2ca5f2b37924328d3892
MD5 e4d563cf7d03313b136243939568837d
BLAKE2b-256 b4e45bee8f696d33e346c74f5b39daf9179ee585b900202a64d60d1b5d95d533

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp310-cp310-win32.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp310-cp310-win32.whl
  • Upload date:
  • Size: 442.0 kB
  • Tags: CPython 3.10, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp310-cp310-win32.whl
Algorithm Hash digest
SHA256 7bf1c6e4291a19213bfee76cc7bd8a2e3badd79e29c5beece6045567eeac0fef
MD5 f2a23c30993f62bf71eb7a78f12c2133
BLAKE2b-256 47964c08b371a9ef8241c7642681fb931d16a4381ac413114a8c53fc9b2ae8e3

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 539.7 kB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 0b2a275bd809a322493f9bfcd54c2310b4417d89899e4634ecab40aea0766287
MD5 8215b8cdae95602524d90463854a44ea
BLAKE2b-256 684a38fef7dd9e76d48f3eff90360058819a249696ff9d53fbe0ef730e3da931

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp39-cp39-win32.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp39-cp39-win32.whl
  • Upload date:
  • Size: 442.0 kB
  • Tags: CPython 3.9, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp39-cp39-win32.whl
Algorithm Hash digest
SHA256 51b8c51c19d3281b0a13e6deb702b66449722acef65cac3b66b8f60e30b68efe
MD5 87d32d8168bc1edc4421d6fb13541ed2
BLAKE2b-256 d3137d19eb6dca055880a01e30b47ff0901398ff43306009ec311d68bd6c23c6

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp38-cp38-win_amd64.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp38-cp38-win_amd64.whl
  • Upload date:
  • Size: 546.6 kB
  • Tags: CPython 3.8, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp38-cp38-win_amd64.whl
Algorithm Hash digest
SHA256 85f553b8ab2f34217b1631a3c6d5370366f5839e08a1e31a17c48d6ee69e1763
MD5 f9cdde768bfdf5d7eba2fb2583849697
BLAKE2b-256 23115871e126206a88e78253b6e4483bd7a144d09bb880611471d65b932db74d

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp38-cp38-win32.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp38-cp38-win32.whl
  • Upload date:
  • Size: 448.8 kB
  • Tags: CPython 3.8, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp38-cp38-win32.whl
Algorithm Hash digest
SHA256 a846c5da990c39a6dc819f1d8e812ecc1ad3e16b143de4ac05cb59daedf73bbb
MD5 ef8aa0ec621a5b70ae81d327d6ab32c1
BLAKE2b-256 f297156308ac92844b3bb7904d8058b414a59c28b4fd1a9f5850e8d90d541288

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp37-cp37m-win_amd64.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp37-cp37m-win_amd64.whl
  • Upload date:
  • Size: 520.1 kB
  • Tags: CPython 3.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp37-cp37m-win_amd64.whl
Algorithm Hash digest
SHA256 7a03b2b5ce000204d668ec0831a9629ddd7d76eac1af18d763288a799490785e
MD5 6cd6a826ac8006e999d5c158a7dbd59a
BLAKE2b-256 013b2899665c35b8b48237e19da48e41dc84d311532bf395682abc8faa1df1ad

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp37-cp37m-win32.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp37-cp37m-win32.whl
  • Upload date:
  • Size: 434.9 kB
  • Tags: CPython 3.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp37-cp37m-win32.whl
Algorithm Hash digest
SHA256 7408397c8b3899568a8c58259f7c324c3ea231af1f89dfe585b6c720e5fc7383
MD5 e695fdd3588b0302c4e1ac0676048b86
BLAKE2b-256 cb666e8a18c1657f4e21bbc4e5ff765bd8a70cca25d6b00e23325ba8ea78651d

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp36-cp36m-win_amd64.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp36-cp36m-win_amd64.whl
  • Upload date:
  • Size: 517.4 kB
  • Tags: CPython 3.6m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp36-cp36m-win_amd64.whl
Algorithm Hash digest
SHA256 ddbc4223f150e47ee269d86746ac23cf3ea2da91a3ec678e123e452f263fbc14
MD5 77a36e7a9c9b0a3a5c7d68ae9d19cb7b
BLAKE2b-256 eadfaf64256188b3273753bcc1b86681439404753c82c5245cccc87b6775d4d3

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp36-cp36m-win32.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp36-cp36m-win32.whl
  • Upload date:
  • Size: 434.4 kB
  • Tags: CPython 3.6m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp36-cp36m-win32.whl
Algorithm Hash digest
SHA256 977136294fbe6a62ff3190b8eb3d9fa815b6827dcc95d4a69e7112e0306d07eb
MD5 fcc5559e9181e9f4402711753c763a6e
BLAKE2b-256 d699a51d0ce31b029a29d43c585b998981b5c95c612956bb84004363b676ed8d

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp35-cp35m-win_amd64.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp35-cp35m-win_amd64.whl
  • Upload date:
  • Size: 472.2 kB
  • Tags: CPython 3.5m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp35-cp35m-win_amd64.whl
Algorithm Hash digest
SHA256 4f35f302799d837595beee3c1a6df9be60c1068041451e03f40dbd375a6658c2
MD5 864fe00ee5fcf4adc001ec1350910509
BLAKE2b-256 832bf5b99b255fd39ec32eaf0df40231137477c095833708c223db35aea0e549

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp35-cp35m-win32.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp35-cp35m-win32.whl
  • Upload date:
  • Size: 387.4 kB
  • Tags: CPython 3.5m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp35-cp35m-win32.whl
Algorithm Hash digest
SHA256 e3021a1de6ac451712a9f7218b75f621e400187c6957d3a7757f2c258f3524cc
MD5 86d4e3e9eb451b8002ba935dfc0cec5a
BLAKE2b-256 c73141ece2c30f4a1d9d34e8e0b061b9cc4b4119733a6fdeb4f1d29e5b5166a6

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp27-cp27m-win_amd64.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp27-cp27m-win_amd64.whl
  • Upload date:
  • Size: 482.9 kB
  • Tags: CPython 2.7m, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp27-cp27m-win_amd64.whl
Algorithm Hash digest
SHA256 9229b3721e65c23fc850aee76441fdec1dfba3eea11a00dec7c716e054ce4dfa
MD5 b4fa2288669dcefbf0cdd010672813b0
BLAKE2b-256 65fcde84cbaa2892e029dba11947b87798e8ede50d8db20346eb56528dd1c195

See more details on using hashes here.

Provenance

File details

Details for the file mpi4py-3.1.2-cp27-cp27m-win32.whl.

File metadata

  • Download URL: mpi4py-3.1.2-cp27-cp27m-win32.whl
  • Upload date:
  • Size: 404.3 kB
  • Tags: CPython 2.7m, Windows x86
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.6.3 pkginfo/1.7.1 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.62.0 CPython/3.9.7

File hashes

Hashes for mpi4py-3.1.2-cp27-cp27m-win32.whl
Algorithm Hash digest
SHA256 b838356d22e920e65d7523006e602944c02a2b4433642a275299ff163f08459f
MD5 a5696bc44cc8e35762f2c463f1b2f40b
BLAKE2b-256 99d94f48becb4121752465b77cf381c8d6f82664840910e57db5d9a80cecd458

See more details on using hashes here.

Provenance

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