Drop testing standalone package in GPU CI

This commit is contained in:
awaelchli 2024-06-30 01:00:08 +02:00
parent 2524864b3c
commit 7575401be0
1 changed files with 3 additions and 24 deletions

View File

@ -56,12 +56,8 @@ jobs:
options: "--gpus=all --shm-size=2gb -v /var/tmp:/var/tmp"
strategy:
matrix:
"Fabric | latest":
image: "pytorchlightning/pytorch_lightning:base-cuda-py3.11-torch2.3-cuda12.1.0"
PACKAGE_NAME: "fabric"
"Lightning | latest":
image: "pytorchlightning/pytorch_lightning:base-cuda-py3.11-torch2.3-cuda12.1.0"
PACKAGE_NAME: "lightning"
workspace:
clean: all
steps:
@ -70,8 +66,7 @@ jobs:
cuda_ver=$(python -c "import torch ; print(''.join(map(str, torch.version.cuda.split('.')[:2])))")
echo "##vso[task.setvariable variable=CUDA_VERSION_MM]$cuda_ver"
echo "##vso[task.setvariable variable=TORCH_URL]https://download.pytorch.org/whl/cu${cuda_ver}/torch_stable.html"
scope=$(python -c 'n = "$(PACKAGE_NAME)" ; print(dict(fabric="lightning_fabric").get(n, n))')
echo "##vso[task.setvariable variable=COVERAGE_SOURCE]$scope"
echo "##vso[task.setvariable variable=COVERAGE_SOURCE]lightning"
displayName: "set env. vars"
- bash: |
echo "##vso[task.setvariable variable=TORCH_URL]https://download.pytorch.org/whl/test/cu${CUDA_VERSION_MM}/torch_test.html"
@ -102,8 +97,7 @@ jobs:
displayName: "Adjust dependencies"
- bash: |
extra=$(python -c "print({'lightning': 'fabric-'}.get('$(PACKAGE_NAME)', ''))")
pip install -e ".[${extra}dev]" pytest-timeout -U --find-links="${TORCH_URL}"
pip install -e ".[dev]" pytest-timeout -U --find-links="${TORCH_URL}"
displayName: "Install package & dependencies"
- bash: |
@ -113,24 +107,9 @@ jobs:
python -c "import bitsandbytes"
displayName: "Env details"
- bash: python -m pytest lightning_fabric
workingDirectory: src
# without succeeded this could run even if the job has already failed
condition: and(succeeded(), eq(variables['PACKAGE_NAME'], 'fabric'))
- bash: python -m pytest src/lightning/fabric
displayName: "Testing: Fabric doctests"
- bash: |
pip install -q -r .actions/requirements.txt
python .actions/assistant.py copy_replace_imports --source_dir="./tests/tests_fabric" \
--source_import="lightning.fabric" \
--target_import="lightning_fabric"
python .actions/assistant.py copy_replace_imports --source_dir="./examples/fabric" \
--source_import="lightning.fabric" \
--target_import="lightning_fabric"
# without succeeded this could run even if the job has already failed
condition: and(succeeded(), eq(variables['PACKAGE_NAME'], 'fabric'))
displayName: "Adjust tests & examples"
- bash: python -m coverage run --source ${COVERAGE_SOURCE} -m pytest . -v --durations=50
workingDirectory: tests/tests_fabric/
displayName: "Testing: fabric standard"