Skip to content

Commit 4b11ab2

Browse files
committed
add to nightly ci.
1 parent cf2ea33 commit 4b11ab2

File tree

1 file changed

+52
-0
lines changed

1 file changed

+52
-0
lines changed

.github/workflows/nightly_tests.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -180,6 +180,58 @@ jobs:
180180
pip install slack_sdk tabulate
181181
python utils/log_reports.py >> $GITHUB_STEP_SUMMARY
182182
183+
run_torch_lora_hotswap_tests:
184+
name: PyTorch LoRA hotswapping with torch.compile CUDA tests
185+
186+
runs-on:
187+
group: aws-g4dn-2xlarge
188+
189+
container:
190+
image: diffusers/diffusers-pytorch-compile-cuda
191+
options: --gpus 0 --shm-size "16gb" --ipc host
192+
193+
steps:
194+
- name: Checkout diffusers
195+
uses: actions/checkout@v3
196+
with:
197+
fetch-depth: 2
198+
199+
- name: NVIDIA-SMI
200+
run: |
201+
nvidia-smi
202+
- name: Install dependencies
203+
run: |
204+
python -m venv /opt/venv && export PATH="/opt/venv/bin:$PATH"
205+
python -m uv pip install -e [quality,test]
206+
python -m uv pip install peft@git+https://github.com/huggingface/peft.git
207+
pip uninstall accelerate -y && python -m uv pip install -U accelerate@git+https://github.com/huggingface/accelerate.git
208+
python -m uv pip install pytest-reportlog
209+
- name: Environment
210+
run: |
211+
python utils/print_env.py
212+
- name: Run torch compile tests on GPU
213+
env:
214+
HF_TOKEN: ${{ secrets.DIFFUSERS_HF_HUB_READ_TOKEN }}
215+
RUN_COMPILE: yes
216+
run: |
217+
python -m pytest -n 1 --max-worker-restart=0 --dist=loadfile -s -v -k "hotswap" --make-reports=tests_torch_compile_hotswap tests/models/
218+
- name: Failure short reports
219+
if: ${{ failure() }}
220+
run: cat reports/tests_torch_compile_hotswap_failures_short.txt
221+
222+
- name: Test suite reports artifacts
223+
if: ${{ always() }}
224+
uses: actions/upload-artifact@v4
225+
with:
226+
name: torch_compile_hotswap_test_reports
227+
path: reports
228+
229+
- name: Generate Report and Notify Channel
230+
if: always()
231+
run: |
232+
pip install slack_sdk tabulate
233+
python utils/log_reports.py >> $GITHUB_STEP_SUMMARY
234+
183235
run_big_gpu_torch_tests:
184236
name: Torch tests on big GPU
185237
strategy:

0 commit comments

Comments
 (0)