Merge pull request #90 from a-r-j/lighten_install #400
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: build | |
on: | |
push: | |
paths-ignore: | |
- "README.md" | |
- "docs/**" | |
- "CHANGELOG.md" | |
pull_request: | |
paths-ignore: | |
- "README.md" | |
- "docs/**" | |
- "CHANGELOG.md" | |
jobs: | |
buld_cpu: | |
name: Build CPU | |
strategy: | |
matrix: | |
platform: [ubuntu-latest, macos-latest, windows-latest] | |
python-version: [3.9, "3.10"] | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Setup miniconda | |
uses: conda-incubator/setup-miniconda@v2 | |
with: | |
auto-update-conda: true | |
miniforge-variant: Mambaforge | |
channels: "conda-forge, pytorch, pyg" | |
python-version: ${{ matrix.python-version }} | |
use-mamba: true | |
- id: cache-dependencies | |
name: Cache dependencies | |
uses: actions/[email protected] | |
with: | |
path: ${{ github.workspace }}/.venv | |
key: ${{ matrix.os }}-${{ hashFiles('**/poetry.lock') }} | |
restore-keys: ${{ matrix.os }}- | |
- name: Install Workshop | |
if: steps.cache-dependencies.cache-hit != 'true' | |
run: | | |
python -m pip install -U pip poetry | |
python -m pip install -U pip poethepoet | |
poetry --version | |
poetry check --no-interaction | |
poetry config virtualenvs.in-project true | |
poetry install --no-interaction --without docs | |
poetry run install_pyg_workshop | |
poe install-torchdrug | |
- name: Run tests | |
run: | | |
poetry run pytest -v |