Skip to content

Commit a03cacb

Browse files
committed
echo
1 parent da1b0d2 commit a03cacb

File tree

2 files changed

+22
-18
lines changed

2 files changed

+22
-18
lines changed

.lightning/workflows/fabric.yml

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,17 @@ run: |
3737
CUDA_VERSION_M_M="${cuda_version%.*}" # Get major.minor by removing the last dot and everything after
3838
CUDA_VERSION_MM="${CUDA_VERSION_M_M//'.'/''}"
3939
TORCH_URL="https://download.pytorch.org/whl/cu${CUDA_VERSION_MM}/torch_stable.html"
40-
echo ${TORCH_URL}
40+
echo "Torch URL: ${TORCH_URL}"
4141
COVERAGE_SOURCE=$(python -c 'n = "$(PACKAGE_NAME)" ; print(dict(fabric="lightning_fabric").get(n, n))')
4242
echo "collecting coverage for: ${COVERAGE_SOURCE}"
4343
4444
if [ "${TORCH_VER}" == "2.1" ]; then
45-
# Set oldest versions
45+
echo "Set oldest versions"
4646
python .actions/assistant.py replace_oldest_ver
4747
pip install "cython<3.0" wheel # for compatibility
4848
fi
4949
50-
# Adjust torch versions in requirements files
50+
echo "Adjust torch versions in requirements files"
5151
PYTORCH_VERSION=$(python -c "import torch; print(torch.__version__.split('+')[0])")
5252
pip install -q wget packaging
5353
python -m wget https://raw.githubusercontent.com/Lightning-AI/utilities/main/scripts/adjust-torch-versions.py
@@ -56,6 +56,7 @@ run: |
5656
done
5757
5858
if [ "${PACKAGE_NAME}" == "fabric" ]; then
59+
echo "Replaced PL imports"
5960
pip install -U -q -r .actions/requirements.txt
6061
python .actions/assistant.py copy_replace_imports --source_dir="./tests/tests_fabric" \
6162
--source_import="lightning.fabric" \
@@ -73,22 +74,23 @@ run: |
7374
python requirements/pytorch/check-avail-extras.py
7475
python -c "import bitsandbytes"
7576
76-
# Testing: Fabric doctests
77+
echo "Testing: Fabric doctests"
7778
if [ "${PACKAGE_NAME}" == "fabric" ]; then
7879
cd src/
7980
python -m pytest lightning_fabric
8081
cd ..
8182
fi
8283
8384
cd tests/
84-
# Testing: fabric standard
85+
echo "Testing: fabric standard"
8586
python -m coverage run --source ${COVERAGE_SOURCE} -m pytest tests_fabric/ -v --durations=50
8687
87-
# Testing: fabric standalone
88+
echo "Testing: fabric standalone"
8889
export PL_RUN_STANDALONE_TESTS=1
8990
wget https://raw.githubusercontent.com/Lightning-AI/utilities/main/scripts/run_standalone_tests.sh
9091
bash ./run_standalone_tests.sh "tests_fabric"
9192
93+
echo "Reporting coverage"
9294
python -m coverage report
9395
python -m coverage xml
9496
python -m coverage html
@@ -102,7 +104,7 @@ run: |
102104
# ls -l
103105
cd ..
104106
105-
# Testing: fabric examples
107+
echo "Testing: fabric examples"
106108
cd examples/
107109
bash run_fabric_examples.sh --accelerator=cuda --devices=1
108110
bash run_fabric_examples.sh --accelerator=cuda --devices=2 --strategy ddp

.lightning/workflows/pytorch.yml

Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -37,17 +37,17 @@ run: |
3737
CUDA_VERSION_M_M="${cuda_version%.*}" # Get major.minor by removing the last dot and everything after
3838
CUDA_VERSION_MM="${CUDA_VERSION_M_M//'.'/''}"
3939
TORCH_URL="https://download.pytorch.org/whl/cu${CUDA_VERSION_MM}/torch_stable.html"
40-
echo ${TORCH_URL}
40+
echo "Torch URL: ${TORCH_URL}"
4141
COVERAGE_SOURCE=$(python -c 'n = "$(PACKAGE_NAME)" ; print(dict(fabric="pytorch_lightning").get(n, n))')
4242
echo "collecting coverage for: ${COVERAGE_SOURCE}"
4343
4444
if [ "${TORCH_VER}" == "2.1" ]; then
45-
# Set oldest versions
45+
recho "Set oldest versions"
4646
python .actions/assistant.py replace_oldest_ver
4747
pip install "cython<3.0" wheel # for compatibility
4848
fi
4949
50-
# Adjust torch versions in requirements files
50+
echo "Adjust torch versions in requirements files"
5151
PYTORCH_VERSION=$(python -c "import torch; print(torch.__version__.split('+')[0])")
5252
pip install -q wget packaging
5353
python -m wget https://raw.githubusercontent.com/Lightning-AI/utilities/main/scripts/adjust-torch-versions.py
@@ -56,6 +56,7 @@ run: |
5656
done
5757
5858
if [ "${PACKAGE_NAME}" == "pytorch" ]; then
59+
echo "Adjust PL imports"
5960
pip install -U -q -r .actions/requirements.txt
6061
python .actions/assistant.py copy_replace_imports --source_dir="./tests/tests_pytorch" \
6162
--source_import="lightning.fabric,lightning.pytorch" \
@@ -69,10 +70,10 @@ run: |
6970
pip install -e ".[${extra}dev]" -U --upgrade-strategy=eager --extra-index-url="${TORCH_URL}"
7071
7172
if [ "${PACKAGE_NAME}" == "pytorch" ]; then
72-
# Drop LAI from extensions
73+
echo "uninstall lightning to have just single package"
7374
pip uninstall -y lightning
7475
elif [ "${PACKAGE_NAME}" == "lightning" ]; then
75-
# Drop PL for LAI
76+
echo "uninstall PL to have just single package"
7677
pip uninstall -y pytorch-lightning
7778
fi
7879
@@ -81,33 +82,34 @@ run: |
8182
python requirements/pytorch/check-avail-extras.py
8283
python -c "import bitsandbytes"
8384
84-
# Testing: Fabric doctests
85+
echo "Testing: Fabric doctests"
8586
if [ "${PACKAGE_NAME}" == "pytorch" ]; then
8687
cd src/
8788
python -m pytest pytorch_lightning
8889
cd ..
8990
fi
9091
91-
# Get legacy checkpoints
92+
echo "Get legacy checkpoints"
9293
bash .actions/pull_legacy_checkpoints.sh
9394
cd tests/legacy
9495
bash generate_checkpoints.sh
9596
ls -l checkpoints/
9697
9798
cd tests/
98-
# Testing: fabric standard
99+
echo "Testing: fabric standard"
99100
python -m coverage run --source ${COVERAGE_SOURCE} -m pytest tests_pytorch/ -v --durations=50
100101
101-
# Testing: fabric standalone
102+
echo "Testing: fabric standalone"
102103
export PL_USE_MOCKED_MNIST=1
103104
export PL_RUN_STANDALONE_TESTS=1
104105
wget https://raw.githubusercontent.com/Lightning-AI/utilities/main/scripts/run_standalone_tests.sh
105106
bash ./run_standalone_tests.sh "tests_pytorch"
106107
107-
# Testing: PyTorch standalone tasks
108+
echo "Testing: PyTorch standalone tasks"
108109
cd tests_pytorch/
109110
bash run_standalone_tasks.sh
110111
112+
echo "Reporting coverage"
111113
python -m coverage report
112114
python -m coverage xml
113115
python -m coverage html
@@ -121,7 +123,7 @@ run: |
121123
# ls -l
122124
cd ../..
123125
124-
# Testing: PyTorch examples
126+
echo "Testing: PyTorch examples"
125127
cd examples/
126128
bash run_pl_examples.sh --trainer.accelerator=gpu --trainer.devices=1
127129
bash run_pl_examples.sh --trainer.accelerator=gpu --trainer.devices=2 --trainer.strategy=ddp

0 commit comments

Comments
 (0)