Skip to content

Commit a9ad249

Browse files
committed
merge main in branch
2 parents bc67f7a + 31d4ea9 commit a9ad249

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+1357
-862
lines changed

.github/workflows/build_main_documentation.yml

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -38,11 +38,6 @@ jobs:
3838
repository: 'huggingface/optimum-amd'
3939
path: optimum-amd
4040

41-
- uses: actions/checkout@v2
42-
with:
43-
repository: 'huggingface/optimum-tpu'
44-
path: optimum-tpu
45-
4641
- name: Free disk space
4742
run: |
4843
df -h
@@ -125,17 +120,6 @@ jobs:
125120
sudo mv intel-doc-build ../optimum
126121
cd ..
127122
128-
- name: Make TPU documentation
129-
run: |
130-
sudo docker system prune -a -f
131-
source venv-doc/bin/activate
132-
cd optimum-tpu
133-
pip install -U pip
134-
pip install . -f https://storage.googleapis.com/libtpu-releases/index.html
135-
doc-builder build optimum.tpu docs/source/ --build_dir tpu-doc-build --version pr_$PR_NUMBER --version_tag_suffix "" --html --clean
136-
mv tpu-doc-build ../optimum
137-
cd ..
138-
139123
- name: Make AMD documentation
140124
run: |
141125
sudo docker system prune -a -f

.github/workflows/build_pr_documentation.yml

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -49,11 +49,6 @@ jobs:
4949
repository: 'huggingface/optimum-amd'
5050
path: optimum-amd
5151

52-
- uses: actions/checkout@v2
53-
with:
54-
repository: 'huggingface/optimum-tpu'
55-
path: optimum-tpu
56-
5752
- name: Setup environment
5853
run: |
5954
python -m venv venv-doc
@@ -89,17 +84,6 @@ jobs:
8984
sudo mv amd-doc-build ../optimum
9085
cd ..
9186
92-
- name: Make TPU documentation
93-
run: |
94-
sudo docker system prune -a -f
95-
source venv-doc/bin/activate
96-
cd optimum-tpu
97-
pip install -U pip
98-
pip install . -f https://storage.googleapis.com/libtpu-releases/index.html
99-
doc-builder build optimum.tpu docs/source/ --build_dir tpu-doc-build --version pr_$PR_NUMBER --version_tag_suffix "" --html --clean
100-
mv tpu-doc-build ../optimum
101-
cd ..
102-
10387
- name: Make Optimum documentation
10488
run: |
10589
sudo docker system prune -a -f

.github/workflows/test_exporters_onnx.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,4 @@ jobs:
4040
4141
- name: Test with pytest
4242
run: |
43-
pytest tests/exporters/onnx/test_export.py -vvvv --durations=0 -n auto
43+
pytest tests/exporters/onnx/test_export.py -vvvv --durations=0

.github/workflows/test_exporters_tflite.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ on:
66
branches: [main]
77
pull_request:
88
branches: [main]
9-
types: [opened, synchronize, reopened, labeled, unlabeled]
109

1110
concurrency:
1211
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
@@ -17,12 +16,6 @@ env:
1716

1817
jobs:
1918
build:
20-
if: ${{
21-
(github.event_name == 'push') ||
22-
(github.event_name == 'workflow_dispatch') ||
23-
contains( github.event.pull_request.labels.*.name, 'tflite' )
24-
}}
25-
2619
strategy:
2720
fail-fast: false
2821
matrix:

.github/workflows/test_exporters_tflite_cli.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ on:
66
branches: [main]
77
pull_request:
88
branches: [main]
9-
types: [opened, synchronize, reopened, labeled, unlabeled]
109

1110
concurrency:
1211
group: ${{ github.workflow }}-${{ github.head_ref || github.run_id }}
@@ -17,12 +16,6 @@ env:
1716

1817
jobs:
1918
build:
20-
if: ${{
21-
(github.event_name == 'push') ||
22-
(github.event_name == 'workflow_dispatch') ||
23-
contains( github.event.pull_request.labels.*.name, 'tflite' )
24-
}}
25-
2619
strategy:
2720
fail-fast: false
2821
matrix:

.github/workflows/test_onnxruntime.yml

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ jobs:
2727
matrix:
2828
python-version: [3.9]
2929
runs-on: [ubuntu-22.04]
30+
transformers_version: [latest, 4.36.*, 4.45.*]
3031
test_file:
3132
[
3233
test_timm.py,
@@ -59,13 +60,26 @@ jobs:
5960
pip install --no-cache-dir torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
6061
pip install .[tests,onnxruntime] diffusers
6162
62-
- name: Test with pytest (in series)
63-
if: matrix.test_file == 'test_modeling.py'
63+
- name: Install transformers ${{ matrix.transformers-version }}
6464
run: |
65-
pytest tests/onnxruntime/test_modeling.py -m "run_in_series" --durations=0 -vvvv
65+
if [ "${{ matrix.transformers_version }}" == '4.36.*' ]; then
66+
pip install "transformers==4.36.*" "diffusers<0.32.0"
67+
elif [ "${{ matrix.transformers_version }}" == '4.45.*' ]; then
68+
pip install "transformers==4.45.*" "diffusers<0.33.0"
69+
else
70+
pip install transformers;
71+
fi
6672
6773
- name: Test with pytest (in parallel)
74+
if: matrix.test_file != 'test_diffusion.py'
75+
run: |
76+
pytest tests/onnxruntime/${{ matrix.test_file }} --durations=0 -vvvv -n auto
77+
env:
78+
HF_HUB_READ_TOKEN: ${{ secrets.HF_HUB_READ_TOKEN }}
79+
80+
- name: Test with pytest (in series)
81+
if: matrix.test_file == 'test_diffusion.py'
6882
run: |
69-
pytest tests/onnxruntime/${{ matrix.test_file }} -m "not run_in_series" --durations=0 -vvvv -n auto
83+
pytest tests/onnxruntime/${{ matrix.test_file }} --durations=0 -vvvv
7084
env:
7185
HF_HUB_READ_TOKEN: ${{ secrets.HF_HUB_READ_TOKEN }}

.github/workflows/test_onnxruntime_slow.yml

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -36,16 +36,15 @@ jobs:
3636
python-version: [3.9]
3737
transformers-version: [latest]
3838
runs-on: [ubuntu-22.04, windows-2022]
39-
include:
40-
- {python-version: 3.9, transformers-version: 4.36.*, runs-on: ubuntu-22.04}
41-
- {python-version: 3.9, transformers-version: 4.45.*, runs-on: ubuntu-22.04}
4239

4340
runs-on: ${{ matrix.runs-on }}
4441

4542
steps:
4643
- name: Free Disk Space (Ubuntu)
4744
if: matrix.runs-on == 'ubuntu-22.04'
4845
uses: jlumbroso/free-disk-space@main
46+
with:
47+
swap-storage: false
4948

5049
- name: Free Disk Space (macOS)
5150
if: matrix.runs-on == 'macos-15'
@@ -69,25 +68,15 @@ jobs:
6968
pip install --no-cache-dir torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu
7069
pip install .[tests,onnxruntime] diffusers
7170
72-
- name: Install transformers ${{ matrix.transformers-version }}
73-
if: ${{ matrix.transformers-version == '4.36.*' }}
74-
run: |
75-
pip install "transformers==${{ matrix.transformers-version }}" "diffusers<0.32.0"
76-
77-
- name: Install transformers ${{ matrix.transformers-version }}
78-
if: ${{ matrix.transformers-version == '4.45.*' }}
79-
run: |
80-
pip install "transformers==${{ matrix.transformers-version }}" "diffusers<0.33.0"
81-
8271
- name: Test with pytest (in series)
8372
run: |
8473
pytest tests/onnxruntime -m "run_in_series" --durations=0 -vvvv
8574
env:
8675
RUN_SLOW: 1
87-
76+
8877
- name: Test with pytest (in parallel)
8978
run: |
90-
pytest tests/onnxruntime -m "not run_in_series" --durations=0 -vvvv -n auto
79+
pytest tests/onnxruntime -m "not run_in_series" --durations=0 -vvvv
9180
env:
9281
HF_HUB_READ_TOKEN: ${{ secrets.HF_HUB_READ_TOKEN }}
9382
RUN_SLOW: 1

0 commit comments

Comments
 (0)