Skip to main content

Numba @njittable MPI wrappers tested on Linux, macOS and Windows

Project description

numba-mpi logo numba-mpi

Python 3 LLVM Linux OK macOS OK Windows OK Github Actions Status Maintenance License: GPL v3 PyPI version Anaconda-Server Badge DOI

Numba @njittable MPI wrappers

  • covering: size/rank, send/recv, allreduce, bcast, scatter/gather & allgather, barrier and wtime
  • basic asynchronous communication with isend/irecv (only for contiguous arrays); for request handling including wait/waitall/waitany and test/testall/testany
  • not yet implemented: support for non-default communicators, ...
  • API based on NumPy and supporting numeric and character datatypes
  • auto-generated docstring-based API docs on the web: https://numba-mpi.github.io/numba-mpi
  • pure-Python implementation with packages available on PyPI and Conda Forge
  • CI-tested on: Linux (MPICH, OpenMPI & Intel MPI), macOS (MPICH & OpenMPI) and Windows (MS MPI)

Hello world example:

import numba, numba_mpi, numpy

@numba.njit()
def hello():
  print(numba_mpi.rank())
  print(numba_mpi.size())

  src = numpy.array([1., 2., 3., 4., 5.])
  dst_tst = numpy.empty_like(src)

  if numba_mpi.rank() == 0:
    numba_mpi.send(src, dest=1, tag=11)
  elif numba_mpi.rank() == 1:
    numba_mpi.recv(dst_tst, source=0, tag=11)

hello()

For information on MPI, see:

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

numba-mpi-0.38.tar.gz (34.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

numba_mpi-0.38-py3-none-any.whl (26.5 kB view details)

Uploaded Python 3

File details

Details for the file numba-mpi-0.38.tar.gz.

File metadata

  • Download URL: numba-mpi-0.38.tar.gz
  • Upload date:
  • Size: 34.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for numba-mpi-0.38.tar.gz
Algorithm Hash digest
SHA256 380176ffcbdb5bc9ea443a46e862ac90d6044ef84de78cfc5b570d5fe7facc8c
MD5 3a575f005f2af6fd5be53c6b1282ce94
BLAKE2b-256 95fc5ad3e1800012efa6b5dae7179c57d49795142e93fa3f07ec87e7fbd56a60

See more details on using hashes here.

File details

Details for the file numba_mpi-0.38-py3-none-any.whl.

File metadata

  • Download URL: numba_mpi-0.38-py3-none-any.whl
  • Upload date:
  • Size: 26.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.6

File hashes

Hashes for numba_mpi-0.38-py3-none-any.whl
Algorithm Hash digest
SHA256 6ecd625ed58e2db219c9223d20095e44f7a4f19337b56b51cce29af7ede2b817
MD5 897ba4f482a80711720f1301fa965891
BLAKE2b-256 5f3e711e8c8dfd0e7607fdeb5faf4679cc7f92fa474945ac0f9b0e8e28f09740

See more details on using hashes here.

Supported by

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