-
Notifications
You must be signed in to change notification settings - Fork 32
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #81 from kornia/ci
CI: Use `kornia/workflows`
- Loading branch information
Showing
44 changed files
with
246 additions
and
133 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,82 +14,48 @@ concurrency: | |
|
||
jobs: | ||
test: | ||
name: Run tutorials - ${{ matrix.os }}, ${{ matrix.python-version }}, ${{ matrix.pytorch-version }} | ||
runs-on: ${{ matrix.os }}-latest | ||
|
||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: ['Ubuntu'] | ||
python-version: ['3.8', '3.10'] | ||
pytorch-version: ['2.0.1'] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Setup environment | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install pytorch | ||
shell: bash | ||
run: pip install torch==${{ matrix.pytorch-version }} torchvision --index-url https://download.pytorch.org/whl/cpu | ||
|
||
kornia-ref: ['main'] # TODO: coverage check through multiple versions: , 'v0.7.1', 'v0.7.0'] | ||
|
||
- name: Install dependencies | ||
shell: bash -l {0} | ||
run: | | ||
pip install -r requirements.txt --upgrade | ||
pip install -r requirements-dev.txt --upgrade | ||
- name: Check deps | ||
shell: bash -l {0} | ||
run: make check-deps | ||
|
||
- name: Generate tutorials | ||
shell: bash -l {0} | ||
run: make generate | ||
|
||
- name: Run tutorials | ||
shell: bash -l {0} | ||
run: make execute | ||
uses: kornia/workflows/.github/workflows/[email protected] | ||
with: | ||
ref: ${{ matrix.kornia-ref }} | ||
|
||
build: | ||
needs: test | ||
name: Build tutorials - ${{ matrix.os }}, ${{ matrix.python-version }}, ${{ matrix.pytorch-version }} | ||
name: Build tutorials | ||
runs-on: ${{ matrix.os }}-latest | ||
|
||
strategy: | ||
matrix: | ||
os: ['Ubuntu'] | ||
python-version: ['3.10'] | ||
pytorch-version: ['2.0.1'] | ||
os: ['ubuntu'] | ||
kornia-ref: ['main'] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: kornia/workflows/.github/actions/[email protected] | ||
with: | ||
ref: ${{ matrix.kornia-ref }} | ||
|
||
- name: Setup conda dependencies | ||
uses: conda-incubator/setup-miniconda@v2 | ||
- uses: actions/checkout@v4 | ||
with: | ||
auto-update-conda: true | ||
python-version: ${{ matrix.python-version }} | ||
repository: 'kornia/tutorials' | ||
path: 'tutorials-repo/' | ||
|
||
- name: Install dependencies | ||
working-directory: ./tutorials-repo/ | ||
shell: bash -l {0} | ||
run: | | ||
conda install pytorch=${{ matrix.pytorch-version }} torchvision cpuonly -c pytorch | ||
pip install -r requirements.txt --upgrade | ||
pip install -r requirements-dev.txt --upgrade | ||
run: make setup | ||
|
||
- uses: quarto-dev/quarto-actions/setup@v2 | ||
|
||
- name: Check deps | ||
working-directory: ./tutorials-repo/ | ||
shell: bash -l {0} | ||
run: make check-deps | ||
|
||
- name: Render Quarto Project | ||
uses: quarto-dev/quarto-actions/render@v2 | ||
with: | ||
to: html | ||
path: . | ||
path: ./tutorials-repo/ |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -10,40 +10,38 @@ jobs: | |
runs-on: ${{ matrix.os }}-latest | ||
|
||
strategy: | ||
fail-fast: true | ||
matrix: | ||
os: ['Ubuntu'] | ||
python-version: ['3.10'] | ||
pytorch-version: ['2.0.1'] | ||
os: ['ubuntu'] | ||
kornia-ref: ['main'] | ||
|
||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup conda dependencies | ||
uses: conda-incubator/setup-miniconda@v2 | ||
with: | ||
auto-update-conda: true | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Install dependencies | ||
shell: bash -l {0} | ||
run: | | ||
conda install pytorch=${{ matrix.pytorch-version }} torchvision cpuonly -c pytorch | ||
pip install -r requirements.txt | ||
pip install -r requirements-dev.txt; | ||
- uses: quarto-dev/quarto-actions/setup@v2 | ||
|
||
- name: Render Quarto Project | ||
uses: quarto-dev/quarto-actions/render@v2 | ||
with: | ||
to: html | ||
path: . | ||
|
||
- name: Deploy to GitHub Pages | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
force_orphan: true | ||
publish_dir: ./_site | ||
user_name: github-actions[bot] | ||
user_email: 41898282+github-actions[bot]@users.noreply.github.com | ||
- uses: kornia/workflows/.github/actions/[email protected] | ||
with: | ||
ref: ${{ matrix.kornia-ref }} | ||
|
||
- uses: actions/checkout@v4 | ||
with: | ||
repository: 'kornia/tutorials' | ||
path: 'tutorials-repo/' | ||
|
||
- name: Install dependencies | ||
working-directory: ./tutorials-repo/ | ||
shell: bash -l {0} | ||
run: make setup | ||
|
||
- uses: quarto-dev/quarto-actions/setup@v2 | ||
|
||
- name: Render Quarto Project | ||
uses: quarto-dev/quarto-actions/render@v2 | ||
with: | ||
to: html | ||
path: ./tutorials-repo/ | ||
|
||
- name: Deploy to GitHub Pages | ||
uses: peaceiris/actions-gh-pages@v3 | ||
with: | ||
github_token: ${{ secrets.GITHUB_TOKEN }} | ||
force_orphan: true | ||
publish_dir: ./_site | ||
user_name: github-actions[bot] | ||
user_email: 41898282+github-actions[bot]@users.noreply.github.com |
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
Oops, something went wrong.