🐍 Geometric Computer Vision Library for Spatial AI
Python artificial-intelligencecomputer-visiondeep-learninghacktoberfestimage-processingmachine-learningneural-networkpythonpytorchroboticsspatial-ai
update CI nightly (#2106)
João Gustavo A. Amorim63c1f36a66c8
diff --git a/.github/actions/env/action.yml b/.github/actions/env/action.ymlindex 4e8a3ea35..750518b13 100644--- a/.github/actions/env/action.yml+++ b/.github/actions/env/action.yml@@ -28,12 +28,14 @@ runs:shell: bash -l {0}run: conda install curl -c conda-forge- - if: ${{ contains(fromJson('["lts", "nightly"]'), inputs.pytorch-version ) }}- name: Install pytorch+ - if: ${{ contains(fromJson('["nightly"]'), inputs.pytorch-version ) }}+ name: Install dependenciesshell: bash -l {0}- run: conda install pytorch cpuonly -c pytorch-${{ inputs.pytorch-version }}+ run: |+ pip install numpy --pre torch[dynamo] --force-reinstall --extra-index-url https://download.pytorch.org/whl/nightly/cpu/+ pip install onnx- - if: ${{ contains(fromJson('["lts", "nightly"]'), inputs.pytorch-version ) == false}}+ - if: ${{ contains(fromJson('["nightly"]'), inputs.pytorch-version ) == false}}name: Install pytorchshell: bash -l {0}run: conda install pytorch=${{ inputs.pytorch-version }} cpuonly -c pytorchdiff --git a/.github/workflows/scheduled_test_cpu.yml b/.github/workflows/scheduled_test_cpu.ymlindex 5c6378a84..428d370d7 100644--- a/.github/workflows/scheduled_test_cpu.yml+++ b/.github/workflows/scheduled_test_cpu.yml@@ -1,4 +1,4 @@-name: (scheduled) Run tests on CPU+name: (scheduled) Tests on CPUon:push:@@ -20,7 +20,7 @@ jobs:matrix:os: ['Ubuntu', 'Windows', 'MacOS']python-version: ['3.7', '3.8']- pytorch-version: ['1.9.1', '1.10.2', '1.12.1', '1.13.0', 'nightly']+ pytorch-version: ['1.9.1', '1.10.2', '1.12.1', '1.13.0']pytorch-dtype: ['float16', 'float32', 'float64']steps:diff --git a/.github/workflows/tests_nightly.yml b/.github/workflows/tests_nightly.ymlnew file mode 100644index 000000000..fce36bf09--- /dev/null+++ b/.github/workflows/tests_nightly.yml@@ -0,0 +1,51 @@+name: Tests on CPU (nightly)++on:+ pull_request:+ branches: [master]+ types: [opened, reopened, synchronize, review_requested, ready_for_review]+ push:+ branches: [master]+ schedule:+ - cron: "0 4 * * *"++concurrency:+ group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}+ cancel-in-progress: true++jobs:+ tests-cpu:+ name: ${{ matrix.os }} - python-${{ matrix.python-version }}, torch-${{ matrix.pytorch-version }}, ${{ matrix.pytorch-dtype }}+ runs-on: ${{ matrix.os }}-latest++ strategy:+ fail-fast: false+ matrix:+ os: ['Ubuntu', 'Windows', 'MacOS']+ python-version: ['3.7', '3.8']+ pytorch-version: ['nightly']+ pytorch-dtype: ['float32', 'float64']++ steps:+ - name: Checkout kornia+ uses: actions/checkout@v3++ - name: Setting environment on ${{ matrix.os }} with python ${{ matrix.python-version }} and pytorch ${{ matrix.pytorch-version }}+ uses: ./.github/actions/env+ with:+ python-version: ${{ matrix.python-version }}+ pytorch-version: ${{ matrix.pytorch-version }}++ - name: Run CPU tests ${{ matrix.pytorch-dtype }}+ shell: bash -l {0}+ run: pytest -v --device cpu --dtype ${{ matrix.pytorch-dtype }} --cov=kornia --cov-report xml ./test+++ - if: always()+ name: Upload coverage+ uses: codecov/codecov-action@v3+ with:+ file: coverage.xml+ token: ${{ secrets.CODECOV_TOKEN }} # to not depend on build via GH API+ flags: cpu,${{ matrix.os }}_py-${{ matrix.python-version }}_pt-${{ matrix.pytorch-version }}_${{ matrix.pytorch-dtype }}+ name: cpu-coveragediff --git a/README.md b/README.mdindex 210475dc7..755d662a3 100644--- a/README.md+++ b/README.md@@ -23,7 +23,8 @@ English | [简体中文](README_zh-CN.md)[](https://join.slack.com/t/kornia/shared_invite/zt-csobk21g-2AQRi~X9Uu6PLMuUZdvfjA)[](https://twitter.com/kornia_foss)-[](https://github.com/kornia/kornia/actions/workflows/tests_cpu.yml)+[](https://github.com/kornia/kornia/actions/workflows/scheduled_test_cpu.yml)+[](https://github.com/kornia/kornia/actions/workflows/tests_nightly.yml)[](https://github.com/kornia/kornia/actions/workflows/tests_cuda.yml)[](https://codecov.io/gh/kornia/kornia)[](https://kornia.readthedocs.io/en/latest/?badge=latest)