This repository has been archived by the owner on Oct 9, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 212
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
600 changed files
with
3,116 additions
and
4,080 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,68 @@ | ||
jobs: | ||
- ${{ each topic in parameters.domains }}: | ||
- job: | ||
displayName: "domain ${{topic}} with 2 GPU" | ||
# how long to run the job before automatically cancelling | ||
timeoutInMinutes: "45" | ||
# how much time to give 'run always even if cancelled tasks' before stopping them | ||
cancelTimeoutInMinutes: "2" | ||
|
||
pool: "lit-rtx-3090" | ||
variables: | ||
DEVICES: $( python -c 'print("$(Agent.Name)".split("_")[-1])' ) | ||
|
||
# this need to have installed docker in the base image... | ||
container: | ||
# base ML image: mcr.microsoft.com/azureml/openmpi3.1.2-cuda10.2-cudnn8-ubuntu18.04 | ||
# image: "pytorchlightning/pytorch_lightning:base-cuda-py3.9-torch1.11" | ||
image: "pytorch/pytorch:1.11.0-cuda11.3-cudnn8-runtime" | ||
options: "-it --rm --gpus=all --shm-size=16g -v /usr/bin/docker:/tmp/docker:ro" | ||
|
||
workspace: | ||
clean: all | ||
steps: | ||
|
||
- bash: | | ||
echo "##vso[task.setvariable variable=CUDA_VISIBLE_DEVICES]$(DEVICES)" | ||
echo "##vso[task.setvariable variable=CONTAINER_ID]$(head -1 /proc/self/cgroup|cut -d/ -f3)" | ||
displayName: 'Set environment variables' | ||
- script: | | ||
/tmp/docker exec -t -u 0 $CONTAINER_ID \ | ||
sh -c "apt-get update && DEBIAN_FRONTEND=noninteractive apt-get -o Dpkg::Options::="--force-confold" -y install sudo" | ||
displayName: 'Install Sudo in container (thanks Microsoft!)' | ||
- bash: | | ||
echo $CUDA_VISIBLE_DEVICES | ||
lspci | egrep 'VGA|3D' | ||
whereis nvidia | ||
nvidia-smi | ||
pip --version | ||
pip list | ||
df -kh /dev/shm | ||
displayName: 'Image info & NVIDIA' | ||
- script: | | ||
python -c "import torch ; mgpu = torch.cuda.device_count() ; assert mgpu >= 2, f'GPU: {mgpu}'" | ||
displayName: 'Sanity check' | ||
- script: | | ||
sudo apt-get install -y build-essential gcc cmake software-properties-common | ||
python -m pip install "pip==22.2.1" | ||
pip --version | ||
pip install '.[${{topic}},test]' -r "requirements/testing_${{topic}}.txt" -U --prefer-binary | ||
env: | ||
FREEZE_REQUIREMENTS: 1 | ||
displayName: 'Install dependencies' | ||
- script: | | ||
pip list | ||
python -m coverage run --source flash -m pytest tests/examples -vV --durations=30 | ||
displayName: 'Testing' | ||
- bash: | | ||
python -m coverage report | ||
python -m coverage xml | ||
# python -m codecov --token=$(CODECOV_TOKEN) --commit=$(Build.SourceVersion) --flags=gpu,pytest --name="GPU-coverage" --env=linux,azure | ||
ls -l | ||
displayName: 'Statistics' |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.