Skip to content

Commit 1e7d033

Browse files
committed
Merge branch 'main' of github.com:pybamm-team/pybammsolvers into feat/removeIREE
2 parents b749192 + 0427a79 commit 1e7d033

36 files changed

+393
-564
lines changed

.github/workflows/build_wheels.yml

Lines changed: 6 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -24,17 +24,7 @@ jobs:
2424
submodules: 'true'
2525
- uses: actions/setup-python@v5
2626
with:
27-
python-version: 3.11
28-
29-
- name: Get number of cores on Windows
30-
id: get_num_cores
31-
shell: python
32-
run: |
33-
from os import environ, cpu_count
34-
num_cpus = cpu_count()
35-
output_file = environ['GITHUB_OUTPUT']
36-
with open(output_file, "a", encoding="utf-8") as output_stream:
37-
output_stream.write(f"count={num_cpus}\n")
27+
python-version: 3.12
3828

3929
- name: Build wheels on Windows
4030
run: pipx run cibuildwheel --output-dir wheelhouse
@@ -46,7 +36,6 @@ jobs:
4636
VCPKG_FEATURE_FLAGS=manifests,registries
4737
CMAKE_GENERATOR="Visual Studio 17 2022"
4838
CMAKE_GENERATOR_PLATFORM=x64
49-
CMAKE_BUILD_PARALLEL_LEVEL=${{ steps.get_num_cores.outputs.count }}
5039
CIBW_ARCHS: AMD64
5140
CIBW_BEFORE_BUILD: python -m pip install setuptools delvewheel # skip CasADi and CMake
5241
CIBW_REPAIR_WHEEL_COMMAND: delvewheel repair --add-path C:/Windows/System32 -w {dest_dir} {wheel}
@@ -70,16 +59,16 @@ jobs:
7059

7160
- uses: actions/setup-python@v5
7261
with:
73-
python-version: 3.11
62+
python-version: 3.12
7463

7564
- name: Build wheels on Linux
7665
run: pipx run cibuildwheel --output-dir wheelhouse
7766
env:
7867
CIBW_ARCHS_LINUX: x86_64
7968
CIBW_BEFORE_ALL_LINUX: >
8069
yum -y install openblas-devel lapack-devel &&
81-
bash install_sundials.sh
82-
CIBW_BEFORE_BUILD_LINUX: python -m pip install cmake casadi setuptools wheel
70+
python install_KLU_Sundials.py
71+
CIBW_BEFORE_BUILD_LINUX: python -m pip install cmake casadi==3.6.7 setuptools wheel
8372
CIBW_REPAIR_WHEEL_COMMAND_LINUX: auditwheel repair -w {dest_dir} {wheel}
8473
CIBW_TEST_EXTRAS: "dev"
8574
CIBW_TEST_COMMAND: |
@@ -106,7 +95,7 @@ jobs:
10695
submodules: 'true'
10796
- uses: actions/setup-python@v5
10897
with:
109-
python-version: '3.11'
98+
python-version: 3.12
11099

111100
- name: Install cibuildwheel
112101
run: python -m pip install cibuildwheel
@@ -203,7 +192,7 @@ jobs:
203192
# 10.13 for Intel (macos-13), 11.0 for Apple Silicon (macos-14 and macos-latest)
204193
MACOSX_DEPLOYMENT_TARGET: ${{ matrix.os == 'macos-14' && '11.0' || '10.13' }}
205194
CIBW_ARCHS_MACOS: auto
206-
CIBW_BEFORE_BUILD: python -m pip install cmake casadi setuptools delocate
195+
CIBW_BEFORE_BUILD: python -m pip install cmake casadi==3.6.7 setuptools delocate
207196
CIBW_REPAIR_WHEEL_COMMAND: |
208197
if [[ $(uname -m) == "x86_64" ]]; then
209198
delocate-listdeps {wheel} && delocate-wheel -v -w {dest_dir} {wheel}

.github/workflows/integration_tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
fail-fast: false
1717
matrix:
1818
os: [macos-latest]
19-
python-version: [ "3.9", "3.10", "3.11", "3.12" ]
19+
python-version: ["3.10", "3.11", "3.12"]
2020

2121
steps:
2222
- uses: actions/checkout@v4

.github/workflows/unit_tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
fail-fast: false
1717
matrix:
1818
os: [ ubuntu-latest, macos-13, macos-latest]
19-
python-version: [ "3.9", "3.10", "3.11", "3.12" ]
19+
python-version: ["3.10", "3.11", "3.12"]
2020

2121
steps:
2222
- uses: actions/checkout@v4

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ __pycache__
99
.DS_Store
1010

1111
setup.log
12-
install_KLU_Sundials
12+
build_sundials
1313
.idaklu
1414
build
1515

.gitmodules

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
11
[submodule "pybind11"]
22
path = pybind11
33
url = https://github.com/pybind/pybind11.git
4+
[submodule "sundials"]
5+
path = sundials
6+
url = git@github.com:LLNL/sundials.git
7+
[submodule "SuiteSparse"]
8+
path = SuiteSparse
9+
url = git@github.com:DrTimothyAldenDavis/SuiteSparse.git

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ ci:
44

55
repos:
66
- repo: https://github.com/astral-sh/ruff-pre-commit
7-
rev: "v0.1.3"
7+
rev: "v0.11.9"
88
hooks:
99
- id: ruff
1010
args: [--fix, --show-fixes]

CMakeLists.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,10 @@ pybind11_add_module(idaklu
9292
src/pybammsolvers/idaklu_source/Expressions/Base/ExpressionTypes.hpp
9393
# IDAKLU expressions - concrete implementations
9494
${IDAKLU_EXPR_CASADI_SOURCE_FILES}
95+
<<<<<<< HEAD
96+
=======
97+
${IDAKLU_EXPR_IREE_SOURCE_FILES}
98+
>>>>>>> 0427a7998aac666b0aafd34f0b556b7df0a7e932
9599
)
96100

97101
if (NOT DEFINED USE_PYTHON_CASADI)

FindSUNDIALS.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
# :code:`PATHS` entry.
2222
#
2323
# This module will define the following variables:
24-
# :code:`SUNDIALS_INCLUDE_DIRS` - Location of the SUNDIALS includes
24+
# :code:`SUNDIALS_INCLUDE_DIR` - Location of the SUNDIALS includes
2525
# :code:`SUNDIALS_LIBRARIES` - Required libraries for all requested components
2626

2727
# List of the valid SUNDIALS components

README.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ Mac dependencies can be installed using brew
3232
```bash
3333
brew install libomp
3434
brew reinstall gcc
35+
git submodule update --init --recurisive
3536
python install_KLU_Sundials.py
3637
pip install .
3738
```
@@ -41,8 +42,9 @@ pip install .
4142
Linux installs may vary based on the distribution, however, the basic build can
4243
be performed with the following commands:
4344
```bash
44-
sudo apt-get libopenblas-dev gcc gfortran make g++ build-essential
45+
sudo apt-get install libopenblas-dev gcc gfortran make g++ build-essential
4546
pip install cmake casadi setuptools wheel
47+
git submodules update --init --recurisive
4648
python install_KLU_Sundials.py
4749
pip install .
4850
```

SuiteSparse

Submodule SuiteSparse added at d3c4926

0 commit comments

Comments
 (0)