[ENH]: Addition of initial ASV benchmarking suite with synthetic data #1
Workflow file for this run
This file contains hidden or 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: ASV Benchmarks | |
| on: | |
| push: | |
| branches: ["main"] | |
| pull_request: | |
| branches: ["main"] | |
| permissions: | |
| contents: read | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| benchmark: | |
| name: Run ASV Performance Tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| with: | |
| # ASV needs full commit history to compare performance | |
| fetch-depth: 0 | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@v7 | |
| with: | |
| enable-cache: true | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: "3.11" | |
| - name: Install ASV and pyGAM dependencies | |
| run: | | |
| uv pip install asv virtualenv | |
| uv pip install -e ".[dev]" | |
| env: | |
| UV_SYSTEM_PYTHON: 1 | |
| - name: Run ASV Benchmarks | |
| run: | | |
| asv machine --yes | |
| if[ "${{ github.event_name }}" == "pull_request" ]; then | |
| # Compare PR performance against the main branch | |
| asv continuous origin/main HEAD --show-stderr | |
| else | |
| # Fast sanity check for direct pushes to main | |
| asv run ALL --quick --show-stderr | |
| fi |