Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 31 additions & 2 deletions .github/workflows/skala-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
environment: test-py313-pyscf214-torch213
- runner: ubuntu-24.04-arm
environment: test-py312-pyscf214-torch213
- runner: macos-14
- runner: macos-15
environment: test-py312-pyscf214-torch213

name: "${{ matrix.environment }} @ ${{ matrix.runner }}"
Expand All @@ -63,8 +63,37 @@ jobs:
if: ${{ failure() }}
uses: ./.github/actions/cpu-diagnostics

# GPU runners are self-hosted, so on pull requests only run them for same-repository
# changes that can affect the GPU environments or GPU code.
gpu-changes:
if: >-
github.event_name == 'pull_request' &&
github.event.pull_request.head.repo.full_name == github.repository
runs-on: ubuntu-latest
outputs:
gpu: ${{ steps.filter.outputs.gpu }}
steps:
- uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4
with:
fetch-depth: 2

- name: Detect GPU-relevant changes
id: filter
run: |
# The checkout is the PR merge commit; its first parent is the base branch.
if git diff --name-only HEAD^1 HEAD | grep -qE '^(pixi\.(toml|lock)|\.github/workflows/skala-test\.yml|\.github/actions/setup-pixi/|skala/src/skala/gpu4pyscf/|skala/tests/test_gpu4pyscf_|tools/verify_gpu\.py$)'; then
echo "gpu=true" >> "$GITHUB_OUTPUT"
else
echo "gpu=false" >> "$GITHUB_OUTPUT"
fi

gpu-test:
if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
needs: gpu-changes
if: >-
!cancelled() && (
(github.event_name != 'pull_request' && github.ref == 'refs/heads/main') ||
(github.event_name == 'pull_request' && needs.gpu-changes.outputs.gpu == 'true')
Comment thread
esoteric-ephemera marked this conversation as resolved.
Resolved
)
runs-on: ${{ matrix.runner }}
env:
OMP_NUM_THREADS: 4
Expand Down
40 changes: 40 additions & 0 deletions pixi.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions pixi.toml
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@ cuda-cudart-dev = ">=12,<13"
cuda-nvrtc = ">=12,<13"
cuda-version = ">=12,<13"
cutensor = ">=2"
libcusolver-dev = "*"

[feature.cuda-12.pypi-dependencies]
gpu4pyscf-cuda12x = "==1.9.0"
Expand All @@ -106,6 +107,7 @@ cuda-cudart-dev = ">=13,<14"
cuda-nvrtc = ">=13,<14"
cuda-version = ">=13,<14"
cutensor = ">=2"
libcusolver-dev = "*"

[feature.cuda-13.pypi-dependencies]
gpu4pyscf-cuda13x = "==1.9.0"
Expand Down
Loading