Metadata-Version: 2.1
Name: pympistandard
Version: 0.2.0
Summary: Python API to the MPI Standard.
Author-Email: Martin Ruefenacht <m.a.ruefenacht@gmail.com>
License: MIT
Requires-Python: >=3.8
Description-Content-Type: text/markdown

# pympistandard

This library provides programmatic access to the extracted data from the MPI
Standard build process. The library comes packaged with the dataset for the
latest MPI Standard version. It is possible to override the database loaded
with either an environment variable or passing of a path:

```bash
export "MPISTANDARD"="/my/path/to/my/apis.json"
```

```python
import pympistandard as std
std.use_api_version(1, given_path="this_is_definitely_a_path")
```

```python
import pympistandard as std
std.use_api_version(1, force_bundled=True)
```

---

Usage example:
```python
import pympistandard as std
std.use_api_version(1)

if "mpi_send" in std.PROCEDURES:
    mpi_send = std.PROCEDURES.mpi_send 
    mpi_send = std.PROCEDURES["mpi_send"]

print(mpi_send.express.iso_c)
# int MPI_Send(const void* buf, int count, MPI_Datatype datatype, int dest, int tag, MPI_Comm comm)

embiggened = [proc.name for proc in std.PROCEDURES.values() if proc.has_embiggenment()]
print(f"Embiggened procedures in 4.1: {len(embiggened)}")
# 154
```

---

This module will run with core Python 3.7.  If you are using an older
version of Python, you can install additional PyPi packages to support
the requirements of this module.  This has been tested with Python
3.6:

```
virtualenv -m venv
source venv/bin/activate
pip install dataclasses importlib_resources
```
