Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
f136e35
Merge pull request #842 from pybop-team/main
NicolaCourtier Nov 25, 2025
3041701
More updates from restructure (#844)
NicolaCourtier Nov 28, 2025
c01f27d
chore: update pre-commit hooks (#845)
pre-commit-ci[bot] Dec 1, 2025
8a3e3fc
Fix image not displaying in readme (#847)
SarahRo Dec 3, 2025
460b6e3
Finite difference calculations of the Hessian matrix are updated, new…
Dibyendu-IITKGP Dec 7, 2025
a4cd766
Restructure priors (#839)
SarahRo Dec 7, 2025
6b9b280
Update for new PyProBE release (#852)
NicolaCourtier Dec 8, 2025
b843f67
Add JOSS paper citation, code and figures (#851)
NicolaCourtier Dec 8, 2025
b0051f6
Base Bayesian framework with EP-BOLFI integration (#846)
YannickNoelStephanKuhn Dec 8, 2025
e8165e0
Update build_matrix.sh (#853)
NicolaCourtier Dec 8, 2025
ffd02b8
chore: update pre-commit hooks (#861)
pre-commit-ci[bot] Jan 5, 2026
9be07cb
Align PyBaMM simulation methods (#857)
NicolaCourtier Jan 9, 2026
01824a0
Create parent Result class (#860)
NicolaCourtier Jan 13, 2026
815d4dc
Updates for next PyBaMM release (#864)
NicolaCourtier Jan 17, 2026
cc5246b
Test lowest-direct dependencies (#858)
NicolaCourtier Jan 17, 2026
6014c92
Specify lowest requirements (#867)
NicolaCourtier Jan 24, 2026
2138dd1
Add lumped thermal model (#871)
NicolaCourtier Jan 25, 2026
9982b3c
chore: update pre-commit hooks (#874)
pre-commit-ci[bot] Feb 4, 2026
e0af009
Add support for python 3.13 (#868)
SarahRo Feb 4, 2026
4c142cb
Open issues if PyBaMM dev and lowest-dependency tests fail (#879)
agriyakhetarpal Feb 9, 2026
085b60a
Add currrent data processing methods (#870)
NicolaCourtier Feb 9, 2026
aeb6e2e
Update scientific-python/issue-from-pytest-log-action to v1.5.0 (#883)
agriyakhetarpal Feb 10, 2026
1ff7a03
Fix nightly workflow again (#884)
agriyakhetarpal Feb 10, 2026
dd5f317
Use dependency groups (#885)
agriyakhetarpal Feb 10, 2026
2b0eca0
Use "Current" not "Current function" in datasets (#878)
NicolaCourtier Feb 11, 2026
1130a59
fix failing nightly dependencies workflow (#887)
SarahRo Feb 13, 2026
9febaa2
Use "Current" not "Current function" in datasets (part 2) (#888)
NicolaCourtier Feb 13, 2026
0468623
Update set_initial_state (#889)
NicolaCourtier Feb 18, 2026
7bb362a
Check output variables exist in model variables (#893)
NicolaCourtier Feb 24, 2026
c1574b1
Allow multivariate parameters to be passed via pybamm.ParameterValues…
SarahRo Feb 24, 2026
412dfd7
Update parameter functionality (#894)
NicolaCourtier Feb 25, 2026
5b91180
save result (#873)
SarahRo Feb 27, 2026
b666a5e
Fix parameter assignment (#890)
NicolaCourtier Feb 27, 2026
201f0cd
Define LogPrior, LogPDF, LogPosterior and update set_target (#897)
NicolaCourtier Mar 2, 2026
a9d2b39
chore: update pre-commit hooks (#900)
pre-commit-ci[bot] Mar 2, 2026
a532f9c
Refresh notebooks (#901)
NicolaCourtier Mar 5, 2026
8f1ee3f
Update self-hosted runner (#902)
NicolaCourtier Mar 5, 2026
e7e1aba
Increment version number
NicolaCourtier Mar 5, 2026
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
33 changes: 33 additions & 0 deletions .github/workflows/draft-pdf.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: JossPaperCompilation

on:
push:
paths:
- papers/joss/**
pull_request:
paths:
- 'papers/joss/**'
workflow_dispatch:
jobs:
paper:
runs-on: ubuntu-latest
name: Paper Draft
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Build draft PDF
uses: openjournals/openjournals-draft-action@85a18372e48f551d8af9ddb7a747de685fbbb01c # v1.0
with:
journal: joss
# This should be the path to the paper within your repo.
paper-path: papers/joss/paper.md
- name: Upload
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
with:
name: paper
# This is the output path where Pandoc will write the compiled
# PDF. Note, this should be the same directory as the input
# paper.md
path: papers/joss/paper.pdf
8 changes: 5 additions & 3 deletions .github/workflows/lychee_links.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,19 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v5
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false

- name: Restore lychee cache
uses: actions/cache@v4
uses: actions/cache@cdf6c1fa76f9f475f3d7449005a359c84ca0f306 # v5.0.3
with:
path: .lycheecache
key: cache-lychee-${{ github.sha }}
restore-keys: cache-lychee-

- name: Run lychee
uses: lycheeverse/lychee-action@v2
uses: lycheeverse/lychee-action@a8c4c7cb88f0c7386610c35eb25108e448569cb0 # v2.7.0
with:
args: >-
--cache
Expand Down
75 changes: 59 additions & 16 deletions .github/workflows/nightly_dependency_tests.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Nightly dependencies at develop
name: Nightly dependencies

on:
workflow_dispatch:
Expand All @@ -14,39 +14,82 @@ concurrency:
# Cancel in-progress runs when a new workflow with the same group name is triggered
cancel-in-progress: true

permissions: {}

jobs:
nightly_tests:
check_dependencies:
name: Test-${{ matrix.dep-type }}-${{ matrix.os }}-py-${{ matrix.python-version }}-${{ matrix.suite }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-14]
python-version: ["3.12"]
os: [ubuntu-latest, macos-latest]
suite: ["unit", "integration", "examples", "notebooks"]

name: Test-${{ matrix.os }}-py-${{ matrix.python-version }}-${{ matrix.suite }})
dep-type: ["latest", "lowest"]
# The following must remain in sync with our Python version support as defined in pyproject.toml
include:
# Latest dependencies with Python 3.13 (our maximum supported Python version)
- dep-type: latest
python-version: "3.13"
# Lowest dependencies with Python 3.10 (our minimum supported Python version)
- dep-type: lowest
python-version: "3.10"
permissions:
contents: read
issues: write # for creating issues when tests fail

steps:
- uses: actions/checkout@v4
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: astral-sh/setup-uv@eac588ad8def6316056a12d4907a9d4d84ff7a3b # v7.3.0
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
activate-environment: "true"

- name: Install dependencies (latest)
if: matrix.dep-type == 'latest'
# uv pip install pip needed to allow %pip install within notebooks
run: |
python -m pip install -e .[all,dev]
python -m pip uninstall -y pybamm
python -m pip install "pybamm[all] @ git+https://github.com/pybamm-team/PyBaMM@develop"
uv pip install pip
uv pip install -e .[all]
uv pip install --group dev
uv pip uninstall pybamm
uv pip install "pybamm[all] @ git+https://github.com/pybamm-team/PyBaMM@main"
uv pip install pytest-reportlog

- name: Install dependencies (lowest)
if: matrix.dep-type == 'lowest'
run: |
uv pip install pip
uv pip install --group dev
uv pip install --resolution lowest-direct -e .[all]
uv pip install pytest-reportlog

- name: Run ${{ matrix.suite }} tests
id: pytest
env:
PYTEST: "pytest --report-log=pytest-log.jsonl"
run: |
if [[ "${{ matrix.suite }}" == "unit" ]]; then
python -m pytest --unit
python -m $PYTEST --unit
elif [[ "${{ matrix.suite }}" == "integration" ]]; then
python -m pytest --integration
python -m $PYTEST --integration
elif [[ "${{ matrix.suite }}" == "examples" ]]; then
python -m pytest --examples
python -m $PYTEST --examples
elif [[ "${{ matrix.suite }}" == "notebooks" ]]; then
python -m pytest --notebooks --nbmake --nbmake-timeout=1000 examples/
python -m $PYTEST --notebooks --nbmake --nbmake-timeout=1000 examples/
fi

- name: Create issues from pytest logs
uses: scientific-python/issue-from-pytest-log-action@8e905db353437cda1d6a773de245343fbfc940dd # v1.5.0
if: |
failure()
&& steps.pytest.outcome == 'failure'
&& github.repository == 'pybop-team/PyBOP'
&& github.event_name == 'schedule'
with:
log-path: pytest-log.jsonl
issue-title: "Nightly ${{ matrix.dep-type }} dependencies ${{ matrix.suite }} tests failed (${{ matrix.os }} Python ${{ matrix.python-version }})"
16 changes: 10 additions & 6 deletions .github/workflows/periodic_benchmarks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@ jobs:
rm -rf ./* || true
rm -rf ./.??* || true

- uses: actions/checkout@v4
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false

- name: Install python & create virtualenv
shell: bash
Expand All @@ -41,13 +43,15 @@ jobs:
run: |
eval "$(pyenv init -)"
pyenv activate pybop-312-bench
python -m pip install -e .[all,dev]
python -m pip install --upgrade pip
python -m pip install -e .[all]
python -m pip install --group dev
python -m pip install asv[virtualenv]
python -m asv machine --machine "SelfHostedRunner"
python -m asv run --machine "SelfHostedRunner" NEW --show-stderr -v

- name: Upload results as artifact
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
with:
name: asv_periodic_results
path: results
Expand All @@ -67,21 +71,21 @@ jobs:
if: github.repository == 'pybop-team/PyBOP'
steps:
- name: Set up Python 3.12
uses: actions/setup-python@v5
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: 3.12

- name: Install asv
run: pip install asv

- name: Checkout pybop-bench repo
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
repository: pybop-team/pybop-bench
token: ${{ secrets.PUSH_BENCH_TOKEN }}

- name: Download results artifact
uses: actions/download-artifact@v4
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
with:
name: asv_periodic_results
path: new_results
Expand Down
22 changes: 12 additions & 10 deletions .github/workflows/release_action.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,15 +11,17 @@ jobs:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Set up Python
uses: actions/setup-python@v4
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: "3.12"
- name: Build a source tarball and a wheel from it
run: pipx run build
- name: Store the distribution packages
uses: actions/upload-artifact@v4
uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0
with:
name: python-package-distributions
path: dist/
Expand All @@ -40,13 +42,13 @@ jobs:

steps:
- name: Download all the dists
uses: actions/download-artifact@v4
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
with:
name: python-package-distributions
path: dist/
merge-multiple: true
- name: Publish distribution 📦 to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0

github-release:
name: >-
Expand All @@ -62,19 +64,19 @@ jobs:

steps:
- name: Download all the dists
uses: actions/download-artifact@v4
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
with:
name: python-package-distributions
path: dist/
merge-multiple: true
- name: Sign the dists with Sigstore
uses: sigstore/gh-action-sigstore-python@v1.2.3
uses: sigstore/gh-action-sigstore-python@a5caf349bc536fbef3668a10ed7f5cd309a4b53d # v3.2.0
with:
inputs: >-
./dist/*.tar.gz
./dist/*.whl
- name: Publish artifacts and signatures to GitHub Releases
uses: softprops/action-gh-release@v2
uses: softprops/action-gh-release@a06a81a03ee405af7f2048a818ed3f03bbf83c7b # v2.5.0
with:
# `dist/` contains the built packages, and the
# sigstore-produced signatures and certificates.
Expand All @@ -97,12 +99,12 @@ jobs:

steps:
- name: Download all the dists
uses: actions/download-artifact@v4
uses: actions/download-artifact@37930b1c2abaa49bbe596cd826c3c89aef350131 # v7.0.0
with:
name: python-package-distributions
path: dist/
merge-multiple: true
- name: Publish distribution 📦 to TestPyPI
uses: pypa/gh-action-pypi-publish@release/v1
uses: pypa/gh-action-pypi-publish@ed0c53931b1dc9bd32cbe73a98c7f6766f8a527e # v1.13.0
with:
repository-url: https://test.pypi.org/legacy/
22 changes: 14 additions & 8 deletions .github/workflows/scheduled_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out PyBOP repository
uses: actions/checkout@v4
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
sparse-checkout-cone-mode: false
sparse-checkout: |
scripts/ci/build_matrix.sh
Expand All @@ -36,7 +37,7 @@ jobs:
pybop_matrix: ${{ steps.set-matrix.outputs.matrix }}

# Filter the matrix to only include Python and PyBaMM versions. This job
# is used for the self-hosted macOS-14 (arm64) runner at this time.
# is used for the self-hosted macOS (arm64) runner at this time.
filter_pybamm_matrix:
name: Filter the matrix for OS and Python version
needs: [create_pybamm_matrix]
Expand All @@ -56,8 +57,8 @@ jobs:
matrix = json.loads(matrix_json)

# Filter the matrix to include just the Python version and PyBaMM version
# First filter the matrix to only include macOS-14 entries
filtered_entries = [entry for entry in matrix['include'] if entry['os'] == 'macos-14']
# First filter the matrix to only include macOS (arm64) entries
filtered_entries = [entry for entry in matrix['include'] if entry['os'] == 'macos-latest']
# Then remove the os key from the entries
for entry in filtered_entries:
entry.pop('os')
Expand All @@ -82,9 +83,11 @@ jobs:
PYBAMM_VERSION: ${{ matrix.pybamm_version }}

steps:
- uses: actions/checkout@v4
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false
- name: Set up Python ${{ matrix.python_version }}
uses: actions/setup-python@v4
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: ${{ matrix.python_version }}

Expand All @@ -107,7 +110,7 @@ jobs:
# M-series Mac Mini
build-apple-mseries:
# This job filters the matrix JSON created in build_matrix.sh to provide
# a matrix of only macOS-14 (arm64) entries
# a matrix of only macOS (arm64) entries
needs: [filter_pybamm_matrix]
name: Build (MacOS M-series, Python ${{ matrix.python_version }}, PyBaMM ${{ matrix.pybamm_version }})
runs-on: [self-hosted, macOS, ARM64]
Expand All @@ -125,7 +128,10 @@ jobs:
rm -rf ./* || true
rm -rf ./.??* || true

- uses: actions/checkout@v4
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false

- name: Install python & create virtualenv
shell: bash
run: |
Expand Down
Loading
Loading