-
Notifications
You must be signed in to change notification settings - Fork 170
57 lines (53 loc) · 1.53 KB
/
tb_plugin_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
45
46
47
48
49
50
51
52
53
54
55
56
57
name: TB_Plugin_CI
on:
push:
branches:
- main
- release/**
- plugin/**
pull_request:
branches:
- main
- release/**
- plugin/**
jobs:
generate-matrix:
runs-on: ubuntu-latest
outputs:
matrix: ${{ steps.set-matrix.outputs.matrix }}
steps:
- id: set-matrix
run: |
echo $GITHUB_BASE_REF
if [ $GITHUB_BASE_REF == "plugin/vnext" ]
then
echo "matrix={\"python-version\":[3.8], \"cuda-version\":[\"cpu\"], \"pytorch-version\":[\"nightly\"]}" >> "$GITHUB_OUTPUT"
else
echo "matrix={\"python-version\":[3.8], \"cuda-version\":[\"cpu\"], \"pytorch-version\":[\"nightly\", \"2.0\", \"stable\"]}" >> "$GITHUB_OUTPUT"
fi
build:
needs: generate-matrix
runs-on: ubuntu-latest
strategy:
matrix: ${{fromJSON(needs.generate-matrix.outputs.matrix)}}
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
architecture: "x64"
- name: Test
env:
CUDA_VERSION: ${{ matrix.cuda-version }}
PYTORCH_VERSION: ${{ matrix.pytorch-version }}
TORCH_PROFILER_LOG_LEVEL: DEBUG
GRPC_VERBOSITY: DEBUG
GRPC_ENABLE_FORK_SUPPORT: "False"
run: |
set -e
cd tb_plugin
sh ./ci_scripts/install_env.sh
pip install .[gs]
cd test
pytest