Extend CI to test with onnxruntime==1.18.0 #1
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Documentation and Code Coverage | ||
on: | ||
push: | ||
pull_request: | ||
types: | ||
- closed | ||
branches: | ||
- main | ||
jobs: | ||
run: | ||
name: CI ${{ matrix.os }} | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-latest] | ||
python_version: ['3.12', '3.11', '3.10', '3.9'] | ||
include: | ||
- python_version: '3.12' | ||
documentation: 1 | ||
numpy.version: '>=1.21.1' | ||
scipy.version: '>=1.7.0' | ||
onnx.version: 'onnx==1.16.0' | ||
onnxrt.version: 'onnxruntime==1.18.0' | ||
sklearn.version: '>=1.4.2' | ||
- python_version: '3.11' | ||
documentation: 0 | ||
numpy.version: '>=1.21.1' | ||
scipy.version: '>=1.7.0' | ||
onnx.version: 'onnx<1.16.0' | ||
onnxrt.version: 'onnxruntime==1.17.3' | ||
sklearn.version: '==1.3.2' | ||
- python_version: '3.10' | ||
documentation: 0 | ||
numpy.version: '>=1.21.1' | ||
scipy.version: '>=1.7.0' | ||
onnx.version: 'onnx==1.14.1' | ||
onnxrt.version: 'onnxruntime==1.16.0' | ||
sklearn.version: '==1.2.2' | ||
- python_version: '3.9' | ||
documentation: 0 | ||
numpy.version: '>=1.21.1' | ||
scipy.version: '>=1.7.0' | ||
onnx.version: 'onnx==1.13.0' | ||
onnxrt.version: 'onnxruntime==1.14.0' | ||
sklearn.version: '==1.1.3' | ||
runs-on: ${{ matrix.os }} | ||
steps: | ||
- name: Checkout repository | ||
uses: actions/checkout@v4 | ||
- name: Set up Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: ${{ matrix.python_version }} | ||
- uses: tlylt/install-graphviz@v1 | ||
- name: Install pandoc | ||
if: matrix.documentation == 1 | ||
run: sudo apt-get install -y pandoc | ||
- name: Install requirements | ||
run: python -m pip install -r requirements.txt | ||
- name: Install requirements dev | ||
run: python -m pip install -r requirements-dev.txt | ||
- name: Cache pip | ||
uses: actions/cache@v2 | ||
with: | ||
path: ~/.cache/pip | ||
key: ${{ runner.os }}-pip-${{ hashFiles('requirements-dev.txt') }} | ||
restore-keys: | | ||
${{ runner.os }}-pip- | ||
${{ runner.os }}- | ||
- name: Install specific versions | ||
run: pip install $(onnx.version) $(onnxrt.version) "numpy$(numpy.version)" scikit-learn$(sklearn.version) scipy$(scipy.version) "pandas$(pandas.version)" | ||
- name: Install | ||
run: pip install -e . | ||
- name: versions | ||
run: | | ||
echo "---------------" | ||
pip show numpy | ||
echo "---------------" | ||
pip show pandas | ||
echo "---------------" | ||
pip show scipy | ||
echo "---------------" | ||
pip show pandas | ||
echo "---------------" | ||
pip show onnx | ||
echo "---------------" | ||
pip show onnxruntime | ||
echo "---------------" | ||
pip show onnxconverter-common | ||
echo "---------------" | ||
pip show scikit-learn | ||
echo "---------------" | ||
pip show onnxmltools | ||
echo "---------------" | ||
- name: Generate coverage report | ||
if: matrix.documentation == 1 | ||
run: | | ||
pytest tests --maxfail=10 --durations=10 --basetemp=temp --doctest-modules --junitxml=junit/test-results.xml | ||
- name: documentation test | ||
run: | | ||
pip install -r docs/requirements.txt | ||
pytest docs/tests --durations=10 --basetemp=temp --doctest-modules -v -v --maxfail=5 | ||
python tests/benchmark.py | ||
- name: build | ||
run: python setup.py bdist_wheel | ||
- uses: actions/upload-artifact@v3 | ||
with: | ||
path: ./dist/** |