µGrid
µGrid is a C++ library for discrete representation of fields on structured grids, with Python bindings. It provides efficient data structures and algorithms for solving partial differential equations on regular grids, with support for MPI parallelization and GPU acceleration.
Features
- Field collections: Manage scalar, vector, and tensor fields on structured grids with flexible memory layouts
- Domain decomposition: Cartesian decomposition with ghost cell communication for stencil operations
- Linear operators: Stencil convolutions, a hard-coded Laplacian, and FEM gradient/divergence operators for linear simplex (P1) and multilinear (Q1) elements
- Fused matrix-free operators: Problem-specific kernels that apply an operator, assemble its diagonal, or contract a sensitivity without ever forming a matrix or storing an intermediate field — for example isotropic linear elasticity on a regular grid
- Iterative solvers: Preconditioned conjugate gradients, in a standard and a pipelined variant that overlaps its reductions
- Preconditioners: Jacobi, Fourier (reference-stiffness/Green), its per-mode block form, and the combined Green-Jacobi preconditioner
- Vector algebra: BLAS-like kernels on host and device (dot products, norms, axpy, scaling), including fused variants that return a reduction and update a vector in one pass
- FFT engine: Built-in Fast Fourier Transform with MPI-parallel support (auto-selected slab or pencil decomposition) and native cuFFT/rocFFT N-D transforms on the GPU
- GPU support: Optional CUDA and HIP backends. Fields, operators, solvers and preconditioners all run on device, so a solve need not return to the host; on unified-memory accelerators the allocator can be routed through managed memory
- NetCDF I/O: Serial and parallel file I/O for checkpointing and analysis
µGrid is written in C++20 and has language bindings for Python via pybind11.
This README contains only a small quick start guide. Please refer to the full documentation for more help.
Quick start
To install µGrid, run
pip install muGrid
Note that on most platforms this will install a binary wheel, that was compiled with a minimal configuration. To compile for your specific platform use
pip install -v --no-binary muGrid muGrid
which will compile the code. µGrid will autodetect MPI. GPU support (CUDA/ROCm) is off by default and must be enabled explicitly at build time (see the documentation); it is not autodetected. For I/O, it will try to use Unidata NetCDF for serial builds and PnetCDF for MPI-parallel builds. Monitor output to see which of these options were automatically detected.
Funding
This development has received funding from the Swiss National Science Foundation, the European Research Council, and the Deutsche Forschungsgemeinschaft.
Release files for muGrid 1.4.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| mugrid-1.4.0.tar.gz | 1.7 MB | Details |
Built distributions (wheels)
Total release size: 135.0 MB
Release files / mugrid-1.4.0.tar.gz
| Download URL | mugrid-1.4.0.tar.gz |
|---|---|
| Size | 1.7 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
19563c24e72dbc3d7a6b2965d1f9eea2ee063257cf603d15ef04c308da39bcec
|
|
BLAKE2b-256 checksum How to use checksums |
0597c0c5f092339ebde970fa91b4caa44a6d2c8e9825d4cdecc31e2980e3a7c8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Release files / mugrid-1.4.0-cp314-cp314-win_arm64.whl
| Download URL | mugrid-1.4.0-cp314-cp314-win_arm64.whl |
|---|---|
| Size | 5.5 MB |
| Tags | CPython 3.14 Windows ARM64 |
|
SHA-256 checksum How to use checksums |
4e0273b99c7bd7176185bd3e0bdb48d3cdc175926619d37a08179b8e29bb42c6
|
|
BLAKE2b-256 checksum How to use checksums |
91df27c1b1293a01e881af6deec0dec8ae470dda8f2177d2a2ebfea6a658c542
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp314-cp314-win_amd64.whl
| Download URL | mugrid-1.4.0-cp314-cp314-win_amd64.whl |
|---|---|
| Size | 5.7 MB |
| Tags | CPython 3.14 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
3b5a7b3de8b6f8475e4ec3591bf79710e129fae3e899f84009d7bd19c28d7188
|
|
BLAKE2b-256 checksum How to use checksums |
2171ad1a962b237127ef502b7b6e84e3a75d52939c0670f08d28beeab906b14c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
| Download URL | mugrid-1.4.0-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl |
|---|---|
| Size | 5.4 MB |
| Tags | CPython 3.14 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64 |
|
SHA-256 checksum How to use checksums |
0af408c5c2fb03ce73094a02367300f79a2c2741af92671a97519730f894b1b7
|
|
BLAKE2b-256 checksum How to use checksums |
87b87497e6c567eac01d51b70e8445d2d860fdee8d38cfe9197830e17026e01d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
| Download URL | mugrid-1.4.0-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl |
|---|---|
| Size | 5.2 MB |
| Tags | CPython 3.14 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64 |
|
SHA-256 checksum How to use checksums |
a89e4ef9391fb092c1a9e22237dfab64c495fdc0b2f4ef87167fc565f1b3fdbe
|
|
BLAKE2b-256 checksum How to use checksums |
a50adf3c8343e9cf9801abd1c90e7df2ad2cd300108185ec0188a52255b9b4b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp314-cp314-macosx_14_0_arm64.whl
| Download URL | mugrid-1.4.0-cp314-cp314-macosx_14_0_arm64.whl |
|---|---|
| Size | 4.9 MB |
| Tags | CPython 3.14 macOS 14.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
95dfb9b78838731d861715f69c15f82e90aa46ceb492f0d14d5172069cc41ad9
|
|
BLAKE2b-256 checksum How to use checksums |
6cf7f8514242675b6c8360b78ea9fba7dc3a61f9dfef1c0ae887ce9ec5771cff
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp313-cp313-win_arm64.whl
| Download URL | mugrid-1.4.0-cp313-cp313-win_arm64.whl |
|---|---|
| Size | 5.5 MB |
| Tags | CPython 3.13 Windows ARM64 |
|
SHA-256 checksum How to use checksums |
7757afcf4ceb9b73c81388e51ea175e9321e632e03ac2d5164622c69f4f123be
|
|
BLAKE2b-256 checksum How to use checksums |
29ac76a8fdc4aa4f1e12d5d15367f1c587e1e07101839434c18fcea481bc06b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp313-cp313-win_amd64.whl
| Download URL | mugrid-1.4.0-cp313-cp313-win_amd64.whl |
|---|---|
| Size | 5.6 MB |
| Tags | CPython 3.13 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
7929c3b6d68e198bfda14a777526bac15d7449b75e94bcd474a4701492ef3299
|
|
BLAKE2b-256 checksum How to use checksums |
75d98ceb36592fe13b205df0cd0ee258a86dca871c37072a5f9f5495b32b3908
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
| Download URL | mugrid-1.4.0-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl |
|---|---|
| Size | 5.4 MB |
| Tags | CPython 3.13 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64 |
|
SHA-256 checksum How to use checksums |
f762bc64f45de1390075d3f4ffc3c515e0b7df258e0eb89f48dbc3a8572f818f
|
|
BLAKE2b-256 checksum How to use checksums |
08283c901fab16687688bb6ea8e84e47c0948860c0bb98a3540d07bde642a7de
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
| Download URL | mugrid-1.4.0-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl |
|---|---|
| Size | 5.2 MB |
| Tags | CPython 3.13 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64 |
|
SHA-256 checksum How to use checksums |
72d3b7adf9fe463ebdd6c38108e5c6aa08d2cdee8e49f3a37f3b66f7a3c27b7c
|
|
BLAKE2b-256 checksum How to use checksums |
855eac2917de25d8dab0e30f251c635581b07ede62c069a0a4731a82fba10a53
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp313-cp313-macosx_14_0_arm64.whl
| Download URL | mugrid-1.4.0-cp313-cp313-macosx_14_0_arm64.whl |
|---|---|
| Size | 4.9 MB |
| Tags | CPython 3.13 macOS 14.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
be75c3475140700749d7360059c6d24f0ed351258c7edfe117b0b26507eea85c
|
|
BLAKE2b-256 checksum How to use checksums |
2f3e9927b2ed69c58ed03570ac5e52c81d2a96d62ce29cf4a112e39079f582ba
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp312-cp312-win_arm64.whl
| Download URL | mugrid-1.4.0-cp312-cp312-win_arm64.whl |
|---|---|
| Size | 5.5 MB |
| Tags | CPython 3.12 Windows ARM64 |
|
SHA-256 checksum How to use checksums |
7acc1a62cf670eae374765f04504284ecc31498be74c3a7631c45c0132f07c18
|
|
BLAKE2b-256 checksum How to use checksums |
c44a1b4124f8d4be642514eed1da274ec1cd9d24f4b4bbc1df3096db5044c156
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp312-cp312-win_amd64.whl
| Download URL | mugrid-1.4.0-cp312-cp312-win_amd64.whl |
|---|---|
| Size | 5.6 MB |
| Tags | CPython 3.12 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
ab9399b53a04695690f84eb03c20042fe956ed93a3e2a934840ef866f104f473
|
|
BLAKE2b-256 checksum How to use checksums |
343e92aa052b38ca6e78db5e488cd06720dfce85dc56ee218a3356d2cebbb6c8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
| Download URL | mugrid-1.4.0-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl |
|---|---|
| Size | 5.4 MB |
| Tags | CPython 3.12 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64 |
|
SHA-256 checksum How to use checksums |
19f167ad99d1bc65127e6e309d48d11b97b6de142bef6ded3b859eadbac921a8
|
|
BLAKE2b-256 checksum How to use checksums |
2b82dc6f760b22ac1a44d3899b6b0696997fab005a4a554aa34c2aff1ba0f596
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
| Download URL | mugrid-1.4.0-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl |
|---|---|
| Size | 5.2 MB |
| Tags | CPython 3.12 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64 |
|
SHA-256 checksum How to use checksums |
9f35ad327e28adebe83c8d29001e68da8bf7fe44315a2449cdd9caf9aab50a22
|
|
BLAKE2b-256 checksum How to use checksums |
138f5cdf966037125146ef18343af3bcab1013e46fd33700e41557cf4ae9e9cc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp312-cp312-macosx_14_0_arm64.whl
| Download URL | mugrid-1.4.0-cp312-cp312-macosx_14_0_arm64.whl |
|---|---|
| Size | 4.9 MB |
| Tags | CPython 3.12 macOS 14.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
4bece21240c46a722e5d8cfc9f901b295dfc3efebb72673c575ec7879408a1ae
|
|
BLAKE2b-256 checksum How to use checksums |
31e2c7a65a91b7499a4a0d9ac42c63d130b0fab5900b35ea24f365df1ffb79a1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp311-cp311-win_arm64.whl
| Download URL | mugrid-1.4.0-cp311-cp311-win_arm64.whl |
|---|---|
| Size | 5.5 MB |
| Tags | CPython 3.11 Windows ARM64 |
|
SHA-256 checksum How to use checksums |
22064f2340016cd8db51e92cba204ac9542f6b14c63d1a4bce4ecfb2bd5167d8
|
|
BLAKE2b-256 checksum How to use checksums |
26a80dfdd9ca07ca2502ed786251788d5fb5991d0a43d99a52102041a151db10
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp311-cp311-win_amd64.whl
| Download URL | mugrid-1.4.0-cp311-cp311-win_amd64.whl |
|---|---|
| Size | 5.6 MB |
| Tags | CPython 3.11 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
6da8757d54d3a8f0ca863babb69ba94635a77a17a04513e8587636cf88d94d81
|
|
BLAKE2b-256 checksum How to use checksums |
9ddb4e53aac562296b389314f6fb1a9f55abc643311496b8ffb83088485ada46
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
| Download URL | mugrid-1.4.0-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl |
|---|---|
| Size | 5.4 MB |
| Tags | CPython 3.11 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64 |
|
SHA-256 checksum How to use checksums |
ff5d37dff65446f3d46a5a0c05fba77364061867957655d98e4215b7eab98247
|
|
BLAKE2b-256 checksum How to use checksums |
9d967d37742dc8ab32f99e5ddf501d7b72073bdd74653feee45be98112938002
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
| Download URL | mugrid-1.4.0-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl |
|---|---|
| Size | 5.2 MB |
| Tags | CPython 3.11 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64 |
|
SHA-256 checksum How to use checksums |
4402d181b4819f8126b1784a1e8f0840bbcc1f41fd6477ecf71ad3f8bd2eb3af
|
|
BLAKE2b-256 checksum How to use checksums |
38575c9fa800da3db8281d59116d11ed55f9b523fe59b9c313595d5c24f70a87
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp311-cp311-macosx_14_0_arm64.whl
| Download URL | mugrid-1.4.0-cp311-cp311-macosx_14_0_arm64.whl |
|---|---|
| Size | 4.9 MB |
| Tags | CPython 3.11 macOS 14.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
67030e3123a0cf98ca99af3fdc6016fd067ff36fccd7d9d537d8ad79c3859d7f
|
|
BLAKE2b-256 checksum How to use checksums |
832430092a966914ba1c63c998ea8b51e81abd4c2518710b64c7906f7fe33407
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp310-cp310-win_arm64.whl
| Download URL | mugrid-1.4.0-cp310-cp310-win_arm64.whl |
|---|---|
| Size | 5.5 MB |
| Tags | CPython 3.10 Windows ARM64 |
|
SHA-256 checksum How to use checksums |
1114797fc981bb75961a5c9a0c2d357b1a5861fa349f21f73e402e57b5494601
|
|
BLAKE2b-256 checksum How to use checksums |
72176a089cea41a2c46a8de1c622f149a6e4f962a1683455a1c9412df7520a29
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp310-cp310-win_amd64.whl
| Download URL | mugrid-1.4.0-cp310-cp310-win_amd64.whl |
|---|---|
| Size | 5.6 MB |
| Tags | CPython 3.10 Windows x86-64 |
|
SHA-256 checksum How to use checksums |
f025a9169b1749263f572f5d3efdef3e1adc2bccbf58cf95a7358796ab206426
|
|
BLAKE2b-256 checksum How to use checksums |
d491ed585b5d9f3bba0f6bc5d6fdafe1ea8e7f5d77f63aee97d9009f750e69ba
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
| Download URL | mugrid-1.4.0-cp310-cp310-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl |
|---|---|
| Size | 5.4 MB |
| Tags | CPython 3.10 Linux glibc 2.27+ x86-64 Linux glibc 2.28+ x86-64 |
|
SHA-256 checksum How to use checksums |
22ace218cf7f7cfc2736f0b16807787fb725ecab7cd28ffddc7f9034e78e7bd5
|
|
BLAKE2b-256 checksum How to use checksums |
45fcfe2e18a86dbe4dd4e9007086c988fbb2916c740a79124de73c5ec482aebe
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp310-cp310-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
| Download URL | mugrid-1.4.0-cp310-cp310-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl |
|---|---|
| Size | 5.2 MB |
| Tags | CPython 3.10 Linux glibc 2.26+ ARM64 Linux glibc 2.28+ ARM64 |
|
SHA-256 checksum How to use checksums |
405ca80fa291e4d4d6020f2c3f164fc92a15ce103277a5f8c0b49ed0618fb6ca
|
|
BLAKE2b-256 checksum How to use checksums |
c90b42c8e3ca69f4f09a13a2026fb8edfcd3f4931c71042014be11f48bb0ea67
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|
Release files / mugrid-1.4.0-cp310-cp310-macosx_14_0_arm64.whl
| Download URL | mugrid-1.4.0-cp310-cp310-macosx_14_0_arm64.whl |
|---|---|
| Size | 4.9 MB |
| Tags | CPython 3.10 macOS 14.0+ ARM64 |
|
SHA-256 checksum How to use checksums |
e0bb06091a1010c435c501240f2db719df2cfc895034d7d9f86ed97ffefc3b88
|
|
BLAKE2b-256 checksum How to use checksums |
6c1b57b831ed78e2f421e948d521fedc254287324cb8e4e7cd636fd1c42bc832
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.7
|