Skip to content

Commit 6e0622c

Browse files
CI: expand XPU matrix
1 parent d3d6840 commit 6e0622c

File tree

1 file changed

+24
-3
lines changed

1 file changed

+24
-3
lines changed

.github/workflows/tests.yml

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,18 @@ jobs:
225225
test-xpu:
226226
if: github.repository == 'bitsandbytes-foundation/bitsandbytes'
227227
needs: build-cpu
228+
strategy:
229+
fail-fast: false
230+
matrix:
231+
torch_version: ["2.6.0", "2.7.1"]
232+
ipex: [true, false]
233+
include:
234+
- torch_version: "2.6.0"
235+
ipex: true
236+
ipex_version: "2.6.10+xpu"
237+
- torch_version: "2.7.1"
238+
ipex: true
239+
ipex_version: "2.7.10+xpu"
228240
runs-on:
229241
group: bandb-itac-bmsprpvc1550-8-1gpu
230242
env:
@@ -237,24 +249,31 @@ jobs:
237249
echo "Memory: $(free -h)"
238250
239251
- name: Show XPU Information
240-
run: xpu-smi
252+
run: xpu-smi discovery
241253

242254
- uses: actions/checkout@v4
243255

244256
- name: Download build artifact
245257
uses: actions/download-artifact@v4
246258
with:
247259
name: lib_cpu_ubuntu-22.04_x86_64
260+
path: bitsandbytes/
261+
merge-multiple: true
248262

249263
- name: Setup Python
250264
uses: actions/setup-python@v5
251265
with:
252266
python-version: 3.9
253267

268+
- name: Install PyTorch
269+
run: pip install torch==${{ matrix.torch_version }} --index-url https://download.pytorch.org/whl/xpu
270+
271+
- name: Install IPEX
272+
if: matrix.ipex == true
273+
run: pip install intel_extension_for_pytorch==${{ matrix.ipex_version }} --extra-index-url https://pytorch-extension.intel.com/release-whl/stable/xpu/us/
274+
254275
- name: Install dependencies
255276
run: |
256-
pip install torch==2.7.1 --index-url https://download.pytorch.org/whl/xpu
257-
258277
pip install -e ".[test]"
259278
pip install pytest-cov
260279
@@ -265,6 +284,8 @@ jobs:
265284
run: |
266285
python -m torch.utils.collect_env
267286
python -m bitsandbytes
287+
- name: Run tests
288+
run: pytest --durations=100
268289

269290
test-cuda:
270291
if: github.repository == 'bitsandbytes-foundation/bitsandbytes'

0 commit comments

Comments
 (0)