pysindy-commit #2
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
# Rerun experiments on new pysindy commits | |
# Only keep this file if you want to maintain your examples with future | |
# breaking changes in pysindy. If at some point you want to stop updating | |
# the example to keep up with breaking changes, pin the versions of all | |
# dependencies and delete this file. You may still make changes to the | |
# experiment afterwards. | |
name: pysindy-commit | |
on: | |
# Requires adding a Personal Access Token as a secret to pysindy in order | |
# in order to trigger CI | |
repository_dispatch: | |
types: [pysindy-commit] | |
# If you don't want to do all that, use cron trigger instead | |
# schedule: | |
# # run twice a month during times when hopefully few other jobs are scheduled | |
# - cron: '0 12 6,21 * *' | |
jobs: | |
find-notebooks: | |
runs-on: ubuntu-latest | |
outputs: | |
paths: ${{ steps.find-notebooks.outputs.paths }} | |
steps: | |
- name: List Files | |
id: find-notebooks | |
uses: mirko-felice/[email protected] | |
with: | |
repo: ${{ github.repository }} | |
ref: ${{ github.ref }} | |
path: "examples" | |
ext: ".ipynb" | |
run-notebooks: | |
runs-on: ubuntu-latest | |
needs: find-notebooks | |
strategy: | |
matrix: | |
files: ${{ fromJson(needs.find-notebooks.outputs.paths) }} | |
steps: | |
- uses: actions/checkout@v3 | |
- name: "Set up Python" | |
uses: actions/setup-python@v3 | |
with: | |
python-version: "3.10" | |
- name: Install dependencies | |
run: pip install -r examples/requirements.txt | |
- name: "Install most current pysindy" | |
run: pip install "pysindy[sbr,cvxpy,miosr] @ git+https://github.com/dynamicslab/pysindy@master" | |
- name: "Run notebooks" | |
run: | | |
jupyter nbconvert --execute --to notebook --inplace ${{ matrix.files }} |