[Issue 168] Vectorized KKR internals (#169) #238
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: Benchmark | |
on: | |
push: | |
branches: | |
- master | |
permissions: | |
contents: write | |
deployments: write | |
jobs: | |
benchmark: | |
name: Run pytest-benchmark benchmark example | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
submodules: recursive | |
- uses: actions/setup-python@v4 | |
with: | |
python-version: "3.10" | |
- name: Install deps | |
run: | | |
pip install -r requirements/fitting-requirements.txt | |
pip install pytest pytest-benchmark pytest-coverage | |
- name: Install module | |
run: | | |
pip install . | |
- name: Run benchmark | |
run: | | |
pytest tests/benchmark*.py --benchmark-json output.json | |
- name: Store benchmark result | |
uses: benchmark-action/github-action-benchmark@v1 | |
with: | |
name: Python Benchmark with pytest-benchmark | |
tool: "pytest" | |
output-file-path: output.json | |
# Use personal access token instead of GITHUB_TOKEN due to https://github.community/t/github-action-not-triggering-gh-pages-upon-push/16096 | |
github-token: ${{ secrets.GITHUB_TOKEN }} | |
auto-push: true | |
# Show alert with commit comment on detecting possible performance regression | |
alert-threshold: "200%" | |
comment-on-alert: true | |
fail-on-alert: true |