9
9
- main
10
10
11
11
jobs :
12
- # run_tests_linux:
13
- # strategy:
14
- # matrix:
15
- # tf_version: ['2.9.0', '2.13.0']
16
- # python_version: ['3.8', '3.9', '3.10']
17
- # opset_version: ['18', '15']
18
- # ort_version: ['1.16.3']
19
- # onnx_version: ['1.15.0']
20
-
21
- # runs-on: ubuntu-latest
22
-
23
- # steps:
24
- # - name: Set up Python (${{ matrix.python_version }})
25
- # uses: actions/setup-python@v5
26
- # with:
27
- # python-version: ${{ matrix.python_version }}
28
-
29
- # - name: Checkout code
30
- # uses: actions/checkout@v4
31
-
32
- # - name: Install dependencies (tf v${{ matrix.tf_version }})
33
- # shell: bash
34
- # run: |
35
- # python -m pip install --upgrade pip
36
- # pip install onnxconverter-common
37
- # pip install onnx==${{ matrix.onnx_version }}
38
- # pip install h5py==3.7.0
39
- # pip install parameterized
40
- # pip install timeout-decorator
41
- # pip install coloredlogs flatbuffers
42
- # pip install tensorflow==${{ matrix.tf_version }}
43
- # pip install pytest pytest-cov pytest-runner
44
- # pip install onnxruntime==${{ matrix.ort_version }}
45
- # pip uninstall -y protobuf
46
- # pip install "protobuf~=3.20"
47
- # pip install -e .
48
-
49
- # echo "----- List all of depdencies:"
50
- # pip freeze --all
51
-
52
- # - name: Run keras unit tests
53
- # run: |
54
- # set -x
55
- # status=0
56
- # python -c "import onnxruntime"
57
- # python -c "import onnxconverter_common"
58
- # pytest tests/keras2onnx_unit_tests --doctest-modules --junitxml=junit/test-results.xml
59
- # exit $status
60
-
61
- run_tests_windows :
12
+ run_tests :
62
13
strategy :
63
14
matrix :
64
15
tf_version : ['2.9.0', '2.13.0']
65
16
python_version : ['3.8', '3.9', '3.10']
66
17
opset_version : ['18', '15']
67
18
ort_version : ['1.16.3']
68
19
onnx_version : ['1.15.0']
20
+ os : ['ubuntu-latest', 'windows-2022']
69
21
70
- runs-on : windows-2022
22
+ runs-on : ${{ matrix.os }}
71
23
72
24
steps :
73
25
- name : Set up Python (${{ matrix.python_version }})
78
30
- name : Checkout code
79
31
uses : actions/checkout@v4
80
32
81
- - name : Install dependencies (tf v${{ matrix.tf_version }})
33
+ - name : Install dependencies (TF- v${{ matrix.tf_version }})
82
34
shell : bash
83
35
run : |
84
36
python -m pip install --upgrade pip
@@ -98,22 +50,23 @@ jobs:
98
50
echo "----- List all of depdencies:"
99
51
pip freeze --all
100
52
101
- - name : Run keras unit tests
53
+ - name : Run keras unit tests (${{ matrix.os }})
102
54
run : |
103
55
python -c "import onnxruntime"
104
56
python -c "import onnxconverter_common"
105
57
pytest tests/keras2onnx_unit_tests --doctest-modules --junitxml=junit/test-results.xml
106
58
107
- run_tests_linux_TF_15 :
59
+ run_tests_tf_15 :
108
60
strategy :
109
61
matrix :
110
62
tf_version : ['1.15.0']
111
63
python_version : ['3.7'] # Max version that supports tf 1.15
112
64
opset_version : ['18', '15']
113
65
ort_version : ['1.14.1'] # Max version that supports python 3.7
114
66
onnx_version : ['1.14.1'] # Max version that supports python 3.7
67
+ os : ['ubuntu-latest', 'windows-2022']
115
68
116
- runs-on : ubuntu-latest
69
+ runs-on : ${{ matrix.os }}
117
70
118
71
steps :
119
72
- name : Set up Python (${{ matrix.python_version }})
@@ -145,58 +98,46 @@ jobs:
145
98
echo "----- List all of depdencies:"
146
99
pip freeze --all
147
100
148
- - name : Run keras unit tests
101
+ - name : Run keras unit tests (${{ matrix.os }})
149
102
run : |
150
- set -x
151
- status=0
152
103
python -c "import onnxruntime"
153
104
python -c "import onnxconverter_common"
154
105
pytest tests/keras2onnx_unit_tests --doctest-modules --junitxml=junit/test-results.xml
155
- exit $status
156
-
157
- run_tests_windows_TF_15 :
158
- strategy :
159
- matrix :
160
- tf_version : ['1.15.0']
161
- python_version : ['3.7'] # Max version that supports tf 1.15
162
- opset_version : ['18', '15']
163
- ort_version : ['1.14.1'] # Max version that supports python 3.7
164
- onnx_version : ['1.14.1'] # Max version that supports python 3.7
165
-
166
- runs-on : windows-2022
167
106
107
+ publish-test-results :
108
+ name : " Publish Tests Results to Github"
109
+ needs : run_tests
110
+ runs-on : ubuntu-latest
111
+ permissions :
112
+ checks : write
113
+ pull-requests : write
114
+ if : always()
168
115
steps :
169
- - name : Set up Python (${{ matrix.python_version }})
170
- uses : actions/setup-python@v5
116
+ - name : Download Artifacts
117
+ uses : actions/download-artifact@v3
171
118
with :
172
- python-version : ${{ matrix.python_version }}
173
-
174
- - name : Checkout code
175
- uses : actions/checkout@v4
119
+ path : artifacts
176
120
177
- - name : Install dependencies (tf v${{ matrix.tf_version }})
178
- shell : bash
179
- run : |
180
- python -m pip install --upgrade pip
181
- pip install onnxconverter-common
182
- pip install onnx==${{ matrix.onnx_version }}
183
- pip uninstall -y protobuf
184
- pip install "protobuf~=3.20"
185
- pip install h5py==3.7.0
186
- pip install parameterized
187
- pip install timeout-decorator
188
- pip install coloredlogs flatbuffers
189
- pip install tensorflow==${{ matrix.tf_version }}
190
- pip install pytest pytest-cov pytest-runner
191
- pip install onnxruntime==${{ matrix.ort_version }}
192
- pip install numpy==1.19.0
193
- pip install -e .
121
+ - name : Publish Test Results
122
+ uses : EnricoMi/publish-unit-test-result-action@v2
123
+ with :
124
+ files : " artifacts/**/*.xml"
194
125
195
- echo "----- List all of depdencies:"
196
- pip freeze --all
126
+ publish-test-results-tf-15 :
127
+ name : " Publish Tests Results(TF15) to Github"
128
+ needs : run_tests_tf_15
129
+ runs-on : ubuntu-latest
130
+ permissions :
131
+ checks : write
132
+ pull-requests : write
133
+ if : always()
134
+ steps :
135
+ - name : Download Artifacts
136
+ uses : actions/download-artifact@v3
137
+ with :
138
+ path : artifacts
197
139
198
- - name : Run keras unit tests
199
- run : |
200
- python -c "import onnxruntime"
201
- python -c "import onnxconverter_common"
202
- pytest tests/keras2onnx_unit_tests --doctest-modules --junitxml=junit/test-results.xml
140
+ - name : Publish Test Results
141
+ uses : EnricoMi/publish-unit-test-result-action@v2
142
+ with :
143
+ files : " artifacts/**/*.xml"
0 commit comments