2021-09-10 11:30:44 +00:00
|
|
|
# Python package
|
|
|
|
# Create and test a Python package on multiple Python versions.
|
|
|
|
# Add steps that analyze code, save the dist with the build record, publish to a PyPI-compatible index, and more:
|
|
|
|
# https://docs.microsoft.com/azure/devops/pipelines/languages/python
|
|
|
|
|
|
|
|
trigger:
|
|
|
|
tags:
|
|
|
|
include:
|
|
|
|
- '*'
|
|
|
|
branches:
|
|
|
|
include:
|
|
|
|
- "master"
|
|
|
|
- "release/*"
|
|
|
|
- "refs/tags/*"
|
|
|
|
|
|
|
|
pr: none
|
|
|
|
|
2021-07-28 16:09:15 +00:00
|
|
|
schedules:
|
|
|
|
- cron: "0 0 * * *" # At the end of every day
|
|
|
|
displayName: Daily midnight benchmark
|
|
|
|
branches:
|
|
|
|
include:
|
|
|
|
- "master"
|
2021-07-20 21:23:53 +00:00
|
|
|
|
|
|
|
jobs:
|
2021-07-28 16:09:15 +00:00
|
|
|
- job: benchmarks
|
|
|
|
timeoutInMinutes: "90"
|
|
|
|
cancelTimeoutInMinutes: "2"
|
2022-06-14 17:11:54 +00:00
|
|
|
pool: azure-jirka-spot
|
2021-07-20 21:23:53 +00:00
|
|
|
container:
|
2022-05-14 01:59:03 +00:00
|
|
|
image: "pytorchlightning/pytorch_lightning:base-cuda-py3.9-torch1.11"
|
2021-07-28 16:09:15 +00:00
|
|
|
options: "--runtime=nvidia -e NVIDIA_VISIBLE_DEVICES=all --shm-size=32g"
|
2021-07-20 21:23:53 +00:00
|
|
|
workspace:
|
|
|
|
clean: all
|
|
|
|
|
|
|
|
steps:
|
2022-06-15 00:54:55 +00:00
|
|
|
|
|
|
|
- bash: |
|
2022-06-21 15:11:33 +00:00
|
|
|
pip install -e . -r requirements/pytorch/strategies.txt
|
2022-06-15 00:54:55 +00:00
|
|
|
pip list
|
2022-06-27 13:34:18 +00:00
|
|
|
env:
|
|
|
|
PACKAGE_NAME: pytorch
|
2022-06-29 13:35:57 +00:00
|
|
|
FREEZE_REQUIREMENTS: 1
|
2022-06-15 00:54:55 +00:00
|
|
|
displayName: 'Install package'
|
|
|
|
|
2022-06-15 22:10:49 +00:00
|
|
|
- bash: python -m pytest benchmarks -v --durations=0
|
2022-06-15 00:54:55 +00:00
|
|
|
env:
|
|
|
|
PL_RUNNING_BENCHMARKS: 1
|
2022-06-15 22:10:49 +00:00
|
|
|
workingDirectory: tests/tests_pytorch
|
|
|
|
displayName: 'Testing: PyTorch benchmarks'
|