3636 runner : docker-cpu
3737 image : diffusers/diffusers-flax-cpu
3838 report : flax_cpu
39- - name : Fast ONNXRuntime CPU tests
40- framework : onnxruntime
41- runner : docker-cpu
42- image : diffusers/diffusers-onnxruntime-cpu
43- report : onnx_cpu
4439 - name : PyTorch Example CPU tests
4540 framework : pytorch_examples
4641 runner : docker-cpu
9893 --make-reports=tests_${{ matrix.config.report }} \
9994 tests
10095
101- - name : Run fast ONNXRuntime CPU tests
102- if : ${{ matrix.config.framework == 'onnxruntime' }}
103- run : |
104- python -m pytest -n 2 --max-worker-restart=0 --dist=loadfile \
105- -s -v -k "Onnx" \
106- --make-reports=tests_${{ matrix.config.report }} \
107- tests/
108-
10996 - name : Run example PyTorch CPU tests
11097 if : ${{ matrix.config.framework == 'pytorch_examples' }}
11198 run : |
@@ -123,56 +110,3 @@ jobs:
123110 with :
124111 name : pr_${{ matrix.config.report }}_test_reports
125112 path : reports
126-
127- run_fast_tests_apple_m1 :
128- name : Fast PyTorch MPS tests on MacOS
129- runs-on : [ self-hosted, apple-m1 ]
130-
131- steps :
132- - name : Checkout diffusers
133- uses : actions/checkout@v3
134- with :
135- fetch-depth : 2
136-
137- - name : Clean checkout
138- shell : arch -arch arm64 bash {0}
139- run : |
140- git clean -fxd
141-
142- - name : Setup miniconda
143- uses : ./.github/actions/setup-miniconda
144- with :
145- python-version : 3.9
146-
147- - name : Install dependencies
148- shell : arch -arch arm64 bash {0}
149- run : |
150- ${CONDA_RUN} python -m pip install --upgrade pip
151- ${CONDA_RUN} python -m pip install -e .[quality,test]
152- ${CONDA_RUN} python -m pip install torch torchvision torchaudio --extra-index-url https://download.pytorch.org/whl/cpu
153- ${CONDA_RUN} python -m pip install accelerate --upgrade
154- ${CONDA_RUN} python -m pip install transformers --upgrade
155-
156- - name : Environment
157- shell : arch -arch arm64 bash {0}
158- run : |
159- ${CONDA_RUN} python utils/print_env.py
160-
161- - name : Run fast PyTorch tests on M1 (MPS)
162- shell : arch -arch arm64 bash {0}
163- env :
164- HF_HOME : /System/Volumes/Data/mnt/cache
165- HUGGING_FACE_HUB_TOKEN : ${{ secrets.HUGGING_FACE_HUB_TOKEN }}
166- run : |
167- ${CONDA_RUN} python -m pytest -n 0 -s -v --make-reports=tests_torch_mps tests/
168-
169- - name : Failure short reports
170- if : ${{ failure() }}
171- run : cat reports/tests_torch_mps_failures_short.txt
172-
173- - name : Test suite reports artifacts
174- if : ${{ always() }}
175- uses : actions/upload-artifact@v2
176- with :
177- name : pr_torch_mps_test_reports
178- path : reports
0 commit comments