Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/measure_coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
runs-on: ubuntu-22.04
strategy:
matrix:
python-version: ["3.13"]
python-version: ["3.14"]

steps:
##-- Setup Testing Environment
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test_CLTs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,10 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-13, macos-14, macos-15,
os: [macos-14, macos-15, macos-15-intel,
ubuntu-22.04, ubuntu-24.04]
mpi_impl: ["openmpi", "mpich"]
python-version: ["3.13"]
python-version: ["3.14"]

steps:
##-- Setup Testing Environment
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/test_anaconda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,14 +23,14 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-13, macos-14, macos-15,
os: [macos-14, macos-15, macos-15-intel,
ubuntu-22.04, ubuntu-24.04]
mpi_impl: ["openmpi"]
python-version: ["3.12"]
miniconda-version: [py312_24.11.1-0]
exclude:
# Prebuilt Intel MPI package not available for macOS
- os: [macos-13, macos-14, macos-15]
- os: [macos-14, macos-15, macos-15-intel]
mpi_impl: "impi_rt"

steps:
Expand All @@ -48,7 +48,6 @@ jobs:
which python
which pip
python --version
python -m pip install build
conda info
conda list
python -m pip list
Expand All @@ -68,7 +67,6 @@ jobs:
run: |
which python
pushd $PKG_ROOT
python -m build --sdist
python -m pip install -v dist/openbtmixing-*.tar.gz
python -m pip install .
popd
$CLONE_PATH/tools/test_python_installation.py
10 changes: 5 additions & 5 deletions .github/workflows/test_py_devmode.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,20 +18,20 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-14, ubuntu-22.04]
python-version: ["3.13"]
os: [macos-15, ubuntu-24.04]
python-version: ["3.14"]

steps:
##-- Setup Testing Environment
- name: Checkout OpenBTMixing
uses: actions/checkout@v4
- name: Install MPICH
- name: Install Open-MPI
run: |
if [ "${{ runner.os }}" = "Linux" ]; then
sudo apt-get update
sudo apt-get -y install mpich
sudo apt-get -y install openmpi-bin libopenmpi-dev
elif [ "${{ runner.os }}" = "macOS" ]; then
brew install mpich
brew install open-mpi
fi
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/test_py_sdist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [macos-13, macos-14, macos-15,
os: [macos-14, macos-15, macos-15-intel,
ubuntu-22.04, ubuntu-24.04]
mpi_impl: ["openmpi", "mpich"]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
exclude:
# MPICH+Ubuntu24.04 tests presently fail because they detect only one
# MPI process instead of two. I suspect that this is related to using
Expand Down
17 changes: 9 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,23 @@ implementation provided by the user.
## Requirements
Before building and installing the Python package, users
must provide
* a compiler suite that includes a C++ compiler that supports the C++11
* a compiler suite that includes a C++ compiler that supports the C++14
standard,
* an MPI installation that is compatible with the compiler suite, and
* optionally the [Eigen software package](https://gitlab.com/libeigen/eigen).

Note that if installing MPI using a package manager, related developer library
packages such as ``libopenmpi-dev`` or ``libmpich-dev`` might need to be
installed in addition to the base MPI packages such as ``openmpi-bin`` or
``mpich``.

To build and install just the bare C++ tools, users must provide in addition to
the above
* the [Meson build system](https://mesonbuild.com) and its prerequistes such as
Python 3 and [ninja](https://ninja-build.org).

While Meson is used internally to build the Python package, it is installed
automatically just for building the package.
While both Meson and ninja are used internally to build the Python package, they
are installed automatically just for building the package.

The Meson build system is setup to automatically detect the compiler suite and
MPI installation to use. If Eigen already exists in the system and Meson can
Expand Down Expand Up @@ -104,12 +109,8 @@ $ python
The package can also be built and installed from a clone of this repository with
```
$ cd /path/to/OpenBT/openbtmixing_pypkg
$ python -m build --sdist
$ python -m pip install -v dist/openbtmixing-<version>.tar.gz
$ python -m pip install .
```
where we assume that the [build](https://build.pypa.io/en/stable/index.html)
package has already been installed.

Developers can setup a virtual environment with a developer/editable mode
installation of the package with
```
Expand Down
6 changes: 3 additions & 3 deletions meson.build
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# ----- SPECIFY PROJECT
# eigen dependency requires at least C++11
# eigen dependency requires at least C++14
#
# The version provided here is the version of the C++ library and command line
# tools. The Python package maintains a separate version. If the C++ code is
Expand All @@ -14,7 +14,7 @@ project('openbtmixing', 'cpp',
license: 'MIT',
license_files: 'LICENSE',
default_options: [
'cpp_std=c++11',
'cpp_std=c++14',
'buildtype=debug',
'default_library=shared',
'b_ndebug=if-release',
Expand All @@ -29,7 +29,7 @@ project('openbtmixing', 'cpp',
# If users have a local install of eigen that can be discovered with pkg-config
# or other Meson tricks, then that installation will be used. Otherwise, meson
# will download the specific tarball as defined in eigen.wrap and use that.
eigen_dep = dependency('eigen3', fallback: ['eigen', 'eigen_dep'])
eigen_dep = dependency('eigen3', fallback: 'eigen')
deps_all = [eigen_dep]

# ----- USER ARGUMENTS
Expand Down
2 changes: 1 addition & 1 deletion openbtmixing_pypkg/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.1.2
1.1.3
1 change: 1 addition & 0 deletions openbtmixing_pypkg/pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
[build-system]
requires = [
"setuptools",
"ninja",
"meson>=1.6.0"
]
build-backend = "setuptools.build_meta"
3 changes: 1 addition & 2 deletions openbtmixing_pypkg/setup.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import os
import sys
import shutil
import codecs

import subprocess as sbp

Expand Down Expand Up @@ -104,7 +103,7 @@ def run(self, *args, **kwargs):
# ----- SPECIFY THE PACKAGE
def readme_md():
fname = PKG_ROOT.joinpath("README.md")
with codecs.open(fname, "r", encoding="utf8") as fptr:
with open(fname, "r", encoding="utf8") as fptr:
return fptr.read()


Expand Down
5 changes: 5 additions & 0 deletions subprojects/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,3 +5,8 @@ History
----------
* Pulled down `eigen.wrap` from meson's wrapDB as part of switching
from autotools to meson.

2025-12-15
----------
* Pulled down `eigen.wrap` from meson's wrapDB so that OpenBT can use the eigen
implementations for the newest major version (v5).
20 changes: 10 additions & 10 deletions subprojects/eigen.wrap
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
[wrap-file]
directory = eigen-3.4.0
source_url = https://gitlab.com/libeigen/eigen/-/archive/3.4.0/eigen-3.4.0.tar.bz2
source_filename = eigen-3.4.0.tar.bz2
source_hash = b4c198460eba6f28d34894e3a5710998818515104d6e74e5cc331ce31e46e626
patch_filename = eigen_3.4.0-2_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/eigen_3.4.0-2/get_patch
patch_hash = cb764fd9fec02d94aaa2ec673d473793c0d05da4f4154c142f76ef923ea68178
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/eigen_3.4.0-2/eigen-3.4.0.tar.bz2
wrapdb_version = 3.4.0-2
directory = eigen-5.0.1
source_url = https://gitlab.com/libeigen/eigen/-/archive/5.0.1/eigen-5.0.1.tar.bz2
source_filename = eigen-5.0.1.tar.bz2
source_hash = e4de6b08f33fd8b8985d2f204381408c660bffa6170ac65b68ae1bd3cd575c0a
patch_filename = eigen_5.0.1-1_patch.zip
patch_url = https://wrapdb.mesonbuild.com/v2/eigen_5.0.1-1/get_patch
patch_hash = 23407632af9388f4585547028c4ed363ff54875872cbf3e89c2085a14397f555
source_fallback_url = https://github.com/mesonbuild/wrapdb/releases/download/eigen_5.0.1-1/eigen-5.0.1.tar.bz2
wrapdb_version = 5.0.1-1

[provide]
eigen3 = eigen_dep
dependency_names = eigen3