Skip to content

Commit ece9a22

Browse files
committed
Add keras_application_tests core.
Signed-off-by: Jay Zhang <jiz@microsoft.com>
1 parent 5c2edd1 commit ece9a22

File tree

6 files changed

+79
-79
lines changed

6 files changed

+79
-79
lines changed
Lines changed: 76 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,76 @@
1+
name: Keras2Onnx Application Tests (Core)
2+
3+
on:
4+
pull_request:
5+
push:
6+
branches:
7+
- main
8+
9+
jobs:
10+
run_tests:
11+
strategy:
12+
matrix:
13+
tf_version: ['2.9.0', '2.13.0']
14+
python_version: ['3.8', '3.9']
15+
opset_version: ['18', '15']
16+
ort_version: ['1.16.3']
17+
onnx_version: ['1.15.0']
18+
19+
runs-on: ubuntu-latest
20+
21+
steps:
22+
- name: Set up Python (${{ matrix.python_version }})
23+
uses: actions/setup-python@v5
24+
with:
25+
python-version: ${{ matrix.python_version }}
26+
27+
- name: Checkout code
28+
uses: actions/checkout@v4
29+
30+
- name: Install dependencies (tf v${{ matrix.tf_version }})
31+
shell: bash
32+
run: |
33+
python -m pip install --upgrade pip
34+
# conda config --set always_yes yes --set changeps1 no
35+
pip install onnxconverter-common
36+
pip install onnx==${{ matrix.onnx_version }}
37+
pip uninstall -y protobuf
38+
pip install "protobuf~=3.20"
39+
pip install h5py==3.7.0
40+
pip install parameterized
41+
pip install timeout-decorator
42+
pip install coloredlogs flatbuffers
43+
pip install tensorflow==${{ matrix.tf_version }}
44+
pip install onnxruntime==${{ matrix.ort_version }}
45+
pip install Pillow==8.2.0
46+
pip install opencv-python
47+
pip install tqdm
48+
pip install keras-segmentation==0.2.0
49+
git clone https://github.com/matterport/Mask_RCNN
50+
cd Mask_RCNN
51+
pip install -r requirements.txt
52+
python setup.py install
53+
cd ..
54+
pip install matplotlib
55+
git clone https://github.com/qqwweee/keras-yolo3
56+
pip install keras-resnet
57+
pip install git+https://www.github.com/keras-team/keras-contrib.git
58+
pip install keras-tcn==2.8.3
59+
pip install git+https://github.com/qubvel/efficientnet
60+
pip install transformers==4.2.0
61+
pip install keras-self-attention
62+
pip install pytest pytest-cov pytest-runner
63+
64+
pip freeze --all
65+
66+
- name: Run keras application tests
67+
run: |
68+
set -x
69+
status=0
70+
pip install -e .
71+
python -c "import onnxruntime"
72+
pytest tests/keras2onnx_unit_tests --doctest-modules --junitxml=junit/test-results.xml
73+
cd tests/keras2onnx_applications/nightly_build
74+
python run_all_v2.py
75+
exit $status
76+

.github/workflows/pretrained_model_tests_core.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
shell: bash
3131
run: |
3232
chmod +x ./tests/setup_test_env.sh
33-
./tests/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }}
33+
./tests/utils/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }}
3434
3535
- name: Fix Paths (Windows only)
3636
if: runner.os == 'Windows'

.github/workflows/pylint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ jobs:
1616
- name: Set up Python
1717
uses: actions/setup-python@v5
1818
with:
19-
python-version: 3.8 # Specify the desired Python version (e.g., 3.8, 3.9)
19+
python-version: 3.9 # Specify the desired Python version (e.g., 3.8, 3.9)
2020

2121
- name: Install dependencies
2222
run: pip install pylint==2.4.4

.github/workflows/unit_test_matrix.yml

Lines changed: 0 additions & 76 deletions
This file was deleted.

.github/workflows/unit_tests_core.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
shell: bash
3131
run: |
3232
chmod +x ./tests/setup_test_env.sh
33-
./tests/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }}
33+
./tests/utils/setup_test_env.sh ${{ matrix.tf_version }} ${{ matrix.ort_version }}
3434
3535
- name: Fix Paths (Windows only)
3636
if: runner.os == 'Windows'
File renamed without changes.

0 commit comments

Comments
 (0)