forked from pytorch/xla
-
Notifications
You must be signed in to change notification settings - Fork 0
44 lines (44 loc) · 1.34 KB
/
tpu_ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
name: TPU Integration Test
run-name: TPU Testing
on:
workflow_dispatch:
push:
branches:
- master
jobs:
tpu-test:
runs-on: v4-runner-set
steps:
- name: Checkout and Setup PyTorch Repo
env:
_GLIBCXX_USE_CXX11_ABI: 0
run: |
git clone --recursive https://github.com/pytorch/pytorch
cd pytorch/
python3 setup.py install --user
- name: Install torchvision
run: |
cd pytorch/
pip install --user --no-use-pep517 "git+https://github.com/pytorch/vision.git@$(cat .github/ci_commit_pins/vision.txt)"
- name: Checkout PyTorch/XLA Repo
uses: actions/checkout@v4
with:
path: pytorch/xla
- name: Run PyTorch/XLA Setup
env:
BAZEL_VERBOSE: 1
TPUVM_MODE: 1
run: |
cd pytorch/xla
python3 setup.py install --user
- name: Run Tests
env:
PJRT_DEVICE: TPU
# Jax is needed for pallas tests.
run: |
pip install fsspec
pip install rich
pip install torch_xla[pallas] -f https://storage.googleapis.com/jax-releases/jax_nightly_releases.html -f https://storage.googleapis.com/jax-releases/jaxlib_nightly_releases.html
pip install torch_xla[tpuvm]
cd pytorch/xla
test/tpu/run_tests.sh