-
Notifications
You must be signed in to change notification settings - Fork 38
/
Copy pathazure-pipelines.yml
70 lines (58 loc) · 2.02 KB
/
azure-pipelines.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
59
60
61
62
63
64
65
66
67
68
69
70
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
#Azure pipeline for continuous integration
trigger:
paths:
exclude:
- docs
jobs:
- job: Fastseq_unittests
timeoutInMinutes: 360
pool:
name: default
demands:
- agent.name -equals gpu3
container:
image: mcr.microsoft.com/mirror/nvcr/nvidia/pytorch:20.03-py3
options: --gpus device=3
steps:
- script: |
#install fastseq
pip install --upgrade pip
pip install sentencepiece==0.1.96
pip install torch==1.10.0
pip install torchvision==0.11.1
echo "******* Installing fairseq *******"
pip install fairseq==0.10.2
pip show fairseq
echo "******* Installing transformers *******"
pip install transformers==4.12.0
pip show transformers
echo "******* Installing fastseq *******"
pip install --editable .
pip show fastseq
echo "******* Adding local bin to path *******"
export PATH="$HOME/bin:$HOME/.local/bin:$PATH"
#cd benchmarks/
#bash run_all_benchmarks.sh
#show environment
which python
python --version
nvcc --version
python -c "import torch; print('torch:', torch.__version__, torch)"
python -c "import torch; print('CUDA available:', torch.cuda.is_available())"
echo "******* Running transformers unittests *******"
bash tests/run_transformers_tests.sh
echo "******* Running fairseq unittests *******"
pip install apex==0.9.10.dev0
bash tests/run_fairseq_tests.sh
echo "******* Running fastseq unittests *******"
pip install pytorch-transformers==1.0.0
bash tests/run_fastseq_tests.sh
displayName: 'run fastseq unit tests'
- task: PublishTestResults@2
condition: succeededOrFailed()
inputs:
testRunTitle: 'Publish test results for Python $(python.version)'
testResultsFiles: 'tests/log_xml/*.xml'
failTaskOnFailedTests: true