lightning/.azure-pipelines/hpu-tests.yml

54 lines
1.2 KiB
YAML

# Pipeline to run the HPU tests in DL1 Instance
trigger:
tags:
include:
- '*'
branches:
include:
- "master"
- "release/*"
- "refs/tags/*"
pr:
- "master"
- "release/*"
jobs:
- job: hpu
# how long to run the job before automatically cancelling
timeoutInMinutes: "5"
# how much time to give 'run always even if cancelled tasks' before stopping them
cancelTimeoutInMinutes: "2"
pool: intel-hpus
workspace:
clean: all
steps:
- bash: |
apt-get install -y hwinfo
hwinfo --short
displayName: 'Instance HW info'
- bash: |
pip install . --requirement requirements/test.txt
displayName: 'Install dependencies'
- bash: |
python ".azure-pipelines/run_hpu_tests.py"
displayName: 'HPU Tests in parallel'
- bash: |
export PYTHONPATH="${PYTHONPATH}:$(pwd)"
python "pl_examples/hpu_examples/simple_mnist/mnist.py"
displayName: 'Testing: HPU examples'
- task: PublishTestResults@2
inputs:
testResultsFiles: 'hpu*_test-results.xml'
testRunTitle: '$(Agent.OS) - $(Build.DefinitionName) - Python $(python.version)'
condition: succeededOrFailed()
displayName: 'Publish test results'