Skip to content

Nightly Benchmarks #891

Nightly Benchmarks

Nightly Benchmarks #891

name: Nightly Benchmarks
on:
workflow_dispatch:
schedule:
# Run every day at midnight
- cron: "0 0 * * *"
defaults:
run:
# The slightly odd shell call is to force bash to read .bashrc, which is
# necessary for having conda behave sensibly. We use bash as the shell even
# on Windows, since we don't run anything complicated, and it makes
# things much simpler.
shell: bash -l {0}
jobs:
benchmarks:
# Prevent running in all the forks
if: github.repository == 'qutip/qutip-benchmark'
name: ${{ matrix.os }}, python${{ matrix.python-version }}, ${{ matrix.case-name }}
runs-on: ${{ matrix.os }}
timeout-minutes: 20
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest]
python-version: ["3.10"]
case-name: [defaults]
steps:
- uses: actions/checkout@v4
- uses: conda-incubator/setup-miniconda@v3
with:
activate-environment: actions-bench
auto-update-conda: true
python-version: ${{ matrix.python-version }}
channels: conda-forge
miniforge-version: latest
- name: Install dependencies
run: |
mamba install numpy scipy cython
mamba install pytest pytest-benchmark
mamba install pandas matplotlib
- name: Install Qutip
run: |
python -m pip install git+https://github.com/qutip/qutip@master
- name: Package information
run: |
mamba list
python -c "import qutip; qutip.about()"
- name: Environment information
run: |
uname -a
if [[ "ubuntu-latest" == "${{ matrix.os }}" ]]; then
hostnamectl
lscpu
free -h
fi
- name: Run benchmarks
run: |
python -m qutip_benchmark.cli.run_benchmarks -m nightly -v
- name: Create artefact containing benchmarks
uses: actions/upload-artifact@v4
with:
name: nightly_benchmarks
path: .benchmarks
- name: upload to s3
run: |
aws s3 sync .benchmarks s3://qutip-benchmark-data/nightly
env:
AWS_ACCESS_KEY_ID: ${{ secrets.QUTIP_BENCHMARK_S3_KEYID }}
AWS_SECRET_ACCESS_KEY: ${{ secrets.QUTIP_BENCHMARK_S3_SECRET }}
AWS_EC2_METADATA_DISABLED: true
finalise:
needs: publish

Check failure on line 84 in .github/workflows/nightly_benchmarks.yml

View workflow run for this annotation

GitHub Actions / Nightly Benchmarks

Invalid workflow file

The workflow is not valid. .github/workflows/nightly_benchmarks.yml (Line: 84, Col: 12): Job 'finalise' depends on unknown job 'publish'.
if: failure()
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Open Issue on Failure
env:
GITHUB_TOKEN: ${{ github.token }}
run: |
if [[ -z "${{ inputs.open_issue }}" ]] || [[ "${{ inputs.open_issue }}" != "False" ]];
then
pip install requests
python tools/report_failing_tests.py $GITHUB_TOKEN
fi