Skip to content

Commit 1528091

Browse files
authored
Merge pull request #2342 from fatcat-z/update_required_ci
Complete the CI tests.
2 parents 01fcd9b + 1eddac5 commit 1528091

File tree

6 files changed

+128
-25
lines changed

6 files changed

+128
-25
lines changed

.github/workflows/keras_application_test_core.yml renamed to .github/workflows/keras_application_test_ci.yml

Lines changed: 23 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Keras2onnx Application Tests (CI)
1+
name: Keras2onnx App Test (CI)
22

33
on:
44
pull_request:
@@ -9,16 +9,33 @@ on:
99
- main
1010
workflow_dispatch:
1111

12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.event_name == 'workflow_dispatch' }}
14+
cancel-in-progress: true
15+
1216
jobs:
1317
run_tests:
1418
strategy:
19+
fail-fast: false
1520
matrix:
16-
tf_version: ['2.9.0', '2.13.0']
17-
python_version: ['3.8', '3.9']
21+
name:
22+
- 'py38-tf2.9'
23+
- 'py39-tf2.10'
24+
- 'py39-tf2.15'
25+
os: ['ubuntu-latest', 'windows-2022']
1826
opset_version: ['18', '15']
1927
ort_version: ['1.16.3']
20-
onnx_version: ['1.15.0']
21-
os: ['ubuntu-latest', 'windows-2022']
28+
onnx_version: ['1.16.1']
29+
include:
30+
- name: 'py38-tf2.9'
31+
tf_version: '2.9.0'
32+
python_version: '3.8'
33+
- name: 'py39-tf2.10'
34+
tf_version: '2.10.0'
35+
python_version: '3.9'
36+
- name: 'py39-tf2.15'
37+
tf_version: '2.15.0'
38+
python_version: '3.9'
2239

2340
runs-on: ${{ matrix.os }}
2441

@@ -63,6 +80,7 @@ jobs:
6380
pip install transformers==4.2.0
6481
pip install keras-self-attention
6582
pip install pytest pytest-cov pytest-runner
83+
pip install "numpy<2"
6684
6785
pip install -e .
6886

.github/workflows/keras_unit_test_core.yml renamed to .github/workflows/keras_unit_test_ci.yml

Lines changed: 28 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Keras2onnx Unit Tests (CI)
1+
name: Keras2onnx Unit Test (CI)
22

33
on:
44
pull_request:
@@ -9,16 +9,37 @@ on:
99
- main
1010
workflow_dispatch:
1111

12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.event_name == 'workflow_dispatch' }}
14+
cancel-in-progress: true
15+
1216
jobs:
1317
run_tests:
1418
strategy:
19+
fail-fast: false
1520
matrix:
16-
tf_version: ['2.9.0', '2.13.0']
17-
python_version: ['3.8', '3.9']
21+
name:
22+
- 'py38-tf2.9'
23+
- 'py39-tf2.10'
24+
- 'py39-tf2.14'
25+
- 'py310-tf2.15'
26+
os: ['ubuntu-latest', 'windows-2022']
1827
opset_version: ['18', '15']
1928
ort_version: ['1.16.3']
20-
onnx_version: ['1.15.0']
21-
os: ['ubuntu-latest', 'windows-2022']
29+
onnx_version: ['1.16.1']
30+
include:
31+
- name: 'py38-tf2.9'
32+
tf_version: '2.9.0'
33+
python_version: '3.8'
34+
- name: 'py39-tf2.10'
35+
tf_version: '2.10.0'
36+
python_version: '3.9'
37+
- name: 'py39-tf2.14'
38+
tf_version: '2.14.0'
39+
python_version: '3.9'
40+
- name: 'py310-tf2.15'
41+
tf_version: '2.15.0'
42+
python_version: '3.10'
2243

2344
runs-on: ${{ matrix.os }}
2445

@@ -46,6 +67,8 @@ jobs:
4667
pip install onnxruntime==${{ matrix.ort_version }}
4768
pip uninstall -y protobuf
4869
pip install "protobuf~=3.20"
70+
pip install "numpy<2"
71+
4972
pip install -e .
5073
5174
echo "----- List all of depdencies:"

.github/workflows/pretrained_model_tests_core.yml renamed to .github/workflows/pretrained_model_tests_ci.yml

Lines changed: 32 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,43 @@ on:
99
- main
1010
workflow_dispatch:
1111

12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.event_name == 'workflow_dispatch' }}
14+
cancel-in-progress: true
15+
1216
jobs:
1317
run_tests:
1418
strategy:
19+
fail-fast: false
1520
matrix:
16-
tf_version: ['2.9.0', '2.13.0']
17-
python_version: ['3.8', '3.9', '3.10']
21+
name:
22+
- 'py38-tf2.9'
23+
- 'py39-tf2.9'
24+
- 'py39-tf2.15'
25+
- 'py310-tf2.15'
1826
opset_version: ['18', '15']
1927
ort_version: ['1.16.3']
28+
onnx_version: ['1.16.1']
29+
include:
30+
- name: 'py38-tf2.9'
31+
tf_version: '2.9.0'
32+
python_version: '3.8'
33+
- name: 'py39-tf2.9'
34+
tf_version: '2.9.0'
35+
python_version: '3.9'
36+
- name: 'py39-tf2.15'
37+
tf_version: '2.15.0'
38+
python_version: '3.9'
39+
- name: 'py310-tf2.15'
40+
tf_version: '2.15.0'
41+
python_version: '3.10'
42+
- name: 'py37-tf1.15'
43+
tf_version: '1.15.5'
44+
python_version: '3.7'
45+
os: 'ubuntu-latest'
46+
opset_version: '15'
47+
ort_version: '1.14.1'
48+
onnx_version: '1.14.1'
2049

2150
runs-on: ubuntu-latest
2251

@@ -33,7 +62,7 @@ jobs:
3362
shell: bash
3463
run: |
3564
chmod +x ./tests/utils/setup_test_env.sh
36-
./tests/utils/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }}
65+
./tests/utils/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }} ${{ matrix.onnx_version }}
3766
3867
- name: Fix Paths (Windows only)
3968
if: runner.os == 'Windows'

.github/workflows/pylint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Pylint Workflow
1+
name: Pylint
22

33
on:
44
pull_request:

.github/workflows/unit_tests_core.yml renamed to .github/workflows/unit_tests_ci.yml

Lines changed: 38 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Unit Tests (CI)
1+
name: Unit Test (CI)
22

33
on:
44
pull_request:
@@ -9,15 +9,46 @@ on:
99
- main
1010
workflow_dispatch:
1111

12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.event_name == 'workflow_dispatch' }}
14+
cancel-in-progress: true
15+
1216
jobs:
1317
run_tests:
1418
strategy:
19+
fail-fast: false
1520
matrix:
16-
tf_version: ['2.9.0', '2.13.0']
17-
python_version: ['3.8', '3.9']
21+
name:
22+
- 'py38-tf2.9'
23+
- 'py39-tf2.10'
24+
- 'py39-tf2.15'
25+
- 'py310-tf2.15'
26+
os: ['ubuntu-latest', 'windows-2022']
1827
opset_version: ['18', '15']
1928
ort_version: ['1.16.3']
20-
os: ['ubuntu-latest', 'windows-2022']
29+
onnx_version: ['1.16.1']
30+
skip_tflite: ['False']
31+
include:
32+
- name: 'py38-tf2.9'
33+
tf_version: '2.9.0'
34+
python_version: '3.8'
35+
- name: 'py39-tf2.10'
36+
tf_version: '2.10.0'
37+
python_version: '3.9'
38+
- name: 'py39-tf2.15'
39+
tf_version: '2.15.0'
40+
python_version: '3.9'
41+
- name: 'py310-tf2.15'
42+
tf_version: '2.15.0'
43+
python_version: '3.10'
44+
- name: 'py37-tf1.15'
45+
tf_version: '1.15.5'
46+
python_version: '3.7'
47+
os: 'ubuntu-latest'
48+
opset_version: '15'
49+
ort_version: '1.14.1'
50+
onnx_version: '1.14.1'
51+
skip_tflite: 'True'
2152

2253
runs-on: ${{ matrix.os }}
2354

@@ -34,7 +65,7 @@ jobs:
3465
shell: bash
3566
run: |
3667
chmod +x ./tests/utils/setup_test_env.sh
37-
./tests/utils/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }}
68+
./tests/utils/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }} ${{ matrix.onnx_version }}
3869
3970
- name: Fix Paths (Windows only)
4071
if: runner.os == 'Windows'
@@ -49,7 +80,7 @@ jobs:
4980
run: |
5081
export TF2ONNX_TEST_BACKEND=onnxruntime
5182
export TF2ONNX_TEST_OPSET=${{ matrix.opset_version }}
52-
export TF2ONNX_SKIP_TFLITE_TESTS=False
83+
export TF2ONNX_SKIP_TFLITE_TESTS=${{ matrix.skip_tflite }}
5384
export TF2ONNX_SKIP_TFJS_TESTS=True
5485
export TF2ONNX_SKIP_TF_TESTS=False
5586
python -m pytest --cov=tf2onnx --cov-report=term --disable-pytest-warnings -r s tests --cov-append --junitxml=junit/test-results.xml
@@ -60,7 +91,7 @@ jobs:
6091
run: |
6192
set TF2ONNX_TEST_BACKEND=onnxruntime
6293
set TF2ONNX_TEST_OPSET=${{ matrix.opset_version }}
63-
set TF2ONNX_SKIP_TFLITE_TESTS=False
94+
set TF2ONNX_SKIP_TFLITE_TESTS=${{ matrix.skip_tflite }}
6495
set TF2ONNX_SKIP_TFJS_TESTS=True
6596
set TF2ONNX_SKIP_TF_TESTS=False
6697
python -m pytest --cov=tf2onnx --cov-report=term --disable-pytest-warnings -r s tests --cov-append --junitxml=junit/test-results.xml

tests/utils/setup_test_env.sh

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,24 @@
11
#!/bin/bash
22

33
# # Check if the argument is provided
4-
if [ "$#" -ne 2 ]; then
5-
echo "Usage: $0 <tensorflow_version> <onnxruntime_version>"
4+
if [ "$#" -ne 3 ]; then
5+
echo "Usage: $0 <tensorflow_version> <onnxruntime_version> <onnx_version>"
66
exit 1
77
fi
88

99
# Assign the argument to a variable
1010
TF_VERSION=$1
1111
ORT_VERSION=$2
12+
ONNX_VERSION=$3
1213

1314
echo "==== TensorFlow version: $TF_VERSION"
1415
echo "==== ONNXRuntime version: $ORT_VERSION"
16+
echo "==== ONNX version: $ONNX_VERSION"
1517

1618
pip install pytest pytest-cov pytest-runner coverage graphviz requests pyyaml pillow pandas parameterized sympy coloredlogs flatbuffers timeout-decorator
17-
pip install onnx
19+
pip install onnx==$ONNX_VERSION
1820
pip install onnxruntime==$ORT_VERSION
19-
pip install numpy
21+
pip install "numpy<2"
2022

2123
pip install onnxruntime-extensions
2224
pip install "tensorflow-text<=$TF_VERSION"

0 commit comments

Comments
 (0)