v24.11.1 #21
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Generate work precision sets | |
on: | |
release: | |
types: [published] | |
workflow_dispatch: | |
env: | |
PYBAMM_DISABLE_TELEMETRY: "true" | |
jobs: | |
benchmarks_on_release: | |
if: github.repository_owner == 'pybamm-team' | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Setup python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: 3.9 | |
- name: Get current date | |
run: echo "VERSION=$(date +'%y.%-m')" >> $GITHUB_ENV | |
- name: Install PyBaMM | |
run: python -m pip install pybamm==${{ env.VERSION }} | |
- name: Run time_vs_* benchmarks for PyBaMM v${{ env.VERSION }} | |
run: | | |
python benchmarks/work_precision_sets/time_vs_dt_max.py | |
python benchmarks/work_precision_sets/time_vs_mesh_size.py | |
python benchmarks/work_precision_sets/time_vs_no_of_states.py | |
python benchmarks/work_precision_sets/time_vs_reltols.py | |
python benchmarks/work_precision_sets/time_vs_abstols.py | |
- name: Create Pull Request | |
uses: peter-evans/create-pull-request@v7 | |
with: | |
delete-branch: true | |
branch-suffix: short-commit-hash | |
commit-message: Work precision sets for PyBaMM version ${{ env.VERSION }} | |
title: Work precision sets for PyBaMM version ${{ env.VERSION }} | |
body: | | |
Update work precision sets for PyBaMM version ${{ env.VERSION }} in `release_work_precision_sets.md` |