Skip to content

Commit f2aec5f

Browse files
authored
Merge branch 'develop' into testing/mypy-initial-setup
2 parents 7438aa0 + 0f2ee07 commit f2aec5f

36 files changed

Lines changed: 217 additions & 158 deletions

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
pixi.lock filter=lfs diff=lfs merge=lfs -text

.github/workflows/basic.yml

Lines changed: 21 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,15 @@ jobs:
1717
matrix:
1818
os: [ubuntu-latest]
1919
mpi-version: [mpich]
20-
python-version: ["3.10", "3.11", "3.12", "3.13"]
20+
python-version: ["py310", "py311", "py312", "py313", "py314"]
2121
comms-type: [m, l]
2222
include:
2323
- os: macos-latest
24-
python-version: "3.11"
24+
python-version: "py311"
2525
mpi-version: mpich
2626
comms-type: m
2727
- os: macos-latest
28-
python-version: "3.11"
28+
python-version: "py311"
2929
mpi-version: mpich
3030
comms-type: l
3131

@@ -39,44 +39,24 @@ jobs:
3939
shell: bash -l {0}
4040

4141
steps:
42-
- uses: actions/checkout@v6
43-
- name: Setup conda - Python ${{ matrix.python-version }}
44-
uses: conda-incubator/setup-miniconda@v3
42+
- uses: actions/checkout@v4
4543
with:
46-
activate-environment: condaenv
47-
miniconda-version: "latest"
48-
python-version: ${{ matrix.python-version }}
49-
channels: conda-forge
50-
channel-priority: strict
51-
auto-update-conda: true
52-
53-
- name: Force-update certifi and pip
54-
run: |
55-
python --version
56-
python -m pip install --upgrade pip
57-
python -m pip install -I --upgrade certifi
44+
lfs: true
5845

59-
- name: Install Ubuntu compilers
60-
if: matrix.os == 'ubuntu-latest'
61-
run: |
62-
conda install -c conda-forge gcc_linux-64
46+
- name: Checkout lockfile
47+
run: git lfs checkout
6348

64-
# Roundabout solution on macos for proper linking with mpicc
65-
- name: Install macOS compilers
66-
if: matrix.os == 'macos-latest'
67-
run: |
68-
conda install clang_osx-64
69-
70-
- name: Install basic testing/feature dependencies
71-
run: |
72-
pip install -r install/testing_requirements.txt
73-
pip install -r install/misc_feature_requirements.txt
74-
source install/install_ibcdfo.sh
75-
conda install numpy scipy
49+
- uses: prefix-dev/setup-pixi@v0.9.2
50+
with:
51+
pixi-version: v0.55.0
52+
cache: true
53+
frozen: true
54+
environments: ${{ matrix.python-version }}
55+
activate-environment: ${{ matrix.python-version }}
7656

77-
- name: Install mpi4py and MPI from conda
57+
- name: Install IBCDFO
7858
run: |
79-
conda install mpi4py ${{ matrix.mpi-version }}
59+
pixi run -e ${{ matrix.python-version }} ./install/install_ibcdfo.sh
8060
8161
- name: Install libEnsemble, test flake8
8262
run: |
@@ -90,19 +70,19 @@ jobs:
9070
run: mypy
9171

9272
- name: Remove various tests on newer pythons
93-
if: matrix.python-version >= '3.11'
73+
if: matrix.python-version == 'py311' || matrix.python-version == 'py312' || matrix.python-version == 'py313' || matrix.python-version == 'py314'
9474
run: |
95-
rm ./libensemble/tests/functionality_tests/test_local_sine_tutorial*.py # matplotlib errors on 3.12
75+
rm ./libensemble/tests/functionality_tests/test_local_sine_tutorial*.py # matplotlib errors on py312
9676
9777
- name: Run simple tests, Ubuntu
9878
if: matrix.os == 'ubuntu-latest'
9979
run: |
100-
./libensemble/tests/run_tests.py -A "-W error" -${{ matrix.comms-type }}
80+
./libensemble/tests/run_tests.py -A "-W error" -${{ matrix.comms-type }}
10181
10282
- name: Run simple tests, macOS
10383
if: matrix.os == 'macos-latest'
10484
run: |
105-
./libensemble/tests/run_tests.py -A "-W error" -${{ matrix.comms-type }}
85+
pixi run -e ${{ matrix.python-version }} ./libensemble/tests/run_tests.py -A "-W error" -${{ matrix.comms-type }}
10686
10787
- name: Merge coverage
10888
run: |
@@ -119,4 +99,4 @@ jobs:
11999
runs-on: ubuntu-latest
120100
steps:
121101
- uses: actions/checkout@v6
122-
- uses: crate-ci/typos@v1.41.0
102+
- uses: crate-ci/typos@v1.42.0

.github/workflows/extra.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,4 +144,4 @@ jobs:
144144
runs-on: ubuntu-latest
145145
steps:
146146
- uses: actions/checkout@v6
147-
- uses: crate-ci/typos@v1.41.0
147+
- uses: crate-ci/typos@v1.42.0

docs/conf.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ def __getattr__(cls, name):
3131
return MagicMock()
3232

3333

34-
autodoc_mock_imports = ["ax", "balsam", "gpcam", "IPython", "matplotlib", "pandas", "scipy", "surmise"]
34+
autodoc_mock_imports = ["ax", "gpcam", "IPython", "matplotlib", "pandas", "scipy", "surmise"]
3535

3636
MOCK_MODULES = [
3737
"argparse",

libensemble/gen_funcs/aposmm_localopt_support.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,9 @@ class APOSMMException(Exception):
4444
if "dfols" in optimizers:
4545
import dfols # noqa: F401
4646
if "ibcdfo_pounders" in optimizers:
47-
from ibcdfo.pounders import pounders # noqa: F401
47+
from ibcdfo import run_pounders
4848
if "ibcdfo_manifold_sampling" in optimizers:
49-
from ibcdfo.manifold_sampling import manifold_sampling_primal # noqa: F401
49+
from ibcdfo import run_MSP # noqa: F401
5050
if "scipy" in optimizers:
5151
from scipy import optimize as sp_opt # noqa: F401
5252
if "external_localopt" in optimizers:
@@ -449,7 +449,7 @@ def run_local_ibcdfo_manifold_sampling(user_specs, comm_queue, x0, f0, child_can
449449
# m = len(f0)
450450
subprob_switch = "linprog"
451451

452-
[X, F, hF, xkin, flag] = manifold_sampling_primal(
452+
[X, F, hF, xkin, flag] = run_MSP(
453453
user_specs["hfun"],
454454
lambda x: scipy_dfols_callback_fun(x, comm_queue, child_can_read, parent_can_read, user_specs),
455455
x0,
@@ -507,7 +507,7 @@ def run_local_ibcdfo_pounders(user_specs, comm_queue, x0, f0, child_can_read, pa
507507
else:
508508
Options = None
509509

510-
[X, F, hF, flag, xkin] = pounders(
510+
[X, F, hF, flag, xkin] = run_pounders(
511511
lambda x: scipy_dfols_callback_fun(x, comm_queue, child_can_read, parent_can_read, user_specs),
512512
x0,
513513
n,

libensemble/tests/regression_tests/support.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import copy
22

33
import numpy as np
4-
54
from libensemble.specs import input_fields, output_data
65

76
branin_vals_and_minima = np.array(

libensemble/tests/regression_tests/test_1d_sampling.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
# TESTSUITE_NPROCS: 2 4
1515

1616
import numpy as np
17-
1817
from libensemble import Ensemble
1918
from libensemble.gen_funcs.sampling import latin_hypercube_sample as gen_f
2019

libensemble/tests/regression_tests/test_2d_sampling.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
# TESTSUITE_NPROCS: 2 4
1515

1616
import numpy as np
17-
1817
from libensemble import Ensemble
1918
from libensemble.gen_funcs.sampling import latin_hypercube_sample as gen_f
2019

libensemble/tests/regression_tests/test_GPU_variable_resources.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,6 @@
2626
# TESTSUITE_NPROCS: 6
2727

2828
import numpy as np
29-
3029
from libensemble import Ensemble
3130
from libensemble.alloc_funcs.start_only_persistent import only_persistent_gens as alloc_f
3231
from libensemble.executors.mpi_executor import MPIExecutor

libensemble/tests/regression_tests/test_GPU_variable_resources_multi_task.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@
3535
# TESTSUITE_NPROCS: 10
3636

3737
import numpy as np
38-
3938
from libensemble import Ensemble
4039
from libensemble.alloc_funcs.start_only_persistent import only_persistent_gens as alloc_f
4140
from libensemble.executors.mpi_executor import MPIExecutor

0 commit comments

Comments
 (0)