-
Notifications
You must be signed in to change notification settings - Fork 152
58 lines (57 loc) · 1.78 KB
/
aistore_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
58
name: Run AIStore Datapipe Test
on:
push:
branches:
- main
- release/*
tags:
pull_request:
types: [opened, synchronize, reopened, labeled]
branches:
- main
# For PR created by ghstack
- gh/*/*/base
- release/*
jobs:
test:
if: ${{ github.repository_owner == 'pytorch' }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os:
- macos-latest
- ubuntu-latest
python-version:
- 3.8
- 3.9
steps:
- name: Get PyTorch Channel
shell: bash
run: |
if [[ "${{ github.base_ref }}" == release/* ]] || [[ "${{ github.ref }}" == refs/heads/release/* ]] || [[ "${{ github.ref }}" == refs/tags/v* ]]; then
PT_CHANNEL="https://download.pytorch.org/whl/test/cpu/torch_test.html"
else
PT_CHANNEL="https://download.pytorch.org/whl/nightly/cpu/torch_nightly.html"
fi
echo "value=$PT_CHANNEL" >> $GITHUB_OUTPUT
id: pytorch_channel
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Check out source repository
uses: actions/checkout@v3
- name: Install dependencies
run: |
pip3 install -r requirements.txt
pip3 install --pre torch -f "${{ steps.pytorch_channel.outputs.value }}"
- name: Run AIStore local deployment
uses: NVIDIA/aistore@master
- name: Build TorchData
run: |
pip3 install .
- name: Install test requirements
run: pip3 install -r test/requirements_aistore.txt
- name: Run AIStore DataPipe tests with pytest
run: pytest --no-header -v test/test_aistore.py