diff --git a/.github/actions/setup/action.yml b/.github/actions/setup/action.yml index b73c757829b7..ffe854508fa6 100644 --- a/.github/actions/setup/action.yml +++ b/.github/actions/setup/action.yml @@ -56,7 +56,7 @@ runs: shell: bash - name: Install faiss-cpu - if: ${{ inputs.full_install == 'true' && inputs.cuda-version == 'cpu' }} + if: ${{ inputs.full_install == 'true' && inputs.cuda-version == 'cpu' && runner.os != 'macOS' }} run: | pip install faiss-cpu shell: bash @@ -67,10 +67,15 @@ runs: pip install faiss-gpu shell: bash - - name: Install extension packages + - name: Install torchvision if: ${{ inputs.full_install == 'true' && inputs.torch-version != 'nightly' }} run: | pip install torchvision==${{ inputs.torchvision-version }} --extra-index-url https://download.pytorch.org/whl/${{ inputs.cuda-version }} + shell: bash + + - name: Install extension packages + if: ${{ inputs.full_install == 'true' && inputs.torch-version != 'nightly' && runner.os != 'macOS' }} + run: | pip install scipy pip install --no-index --upgrade torch-scatter torch-sparse torch-cluster torch-spline-conv -f https://data.pyg.org/whl/torch-${{ inputs.torch-version }}+${{ inputs.cuda-version }}.html shell: bash diff --git a/.github/workflows/full_testing.yml b/.github/workflows/full_testing.yml index f68f9b31062e..061f41e7864d 100644 --- a/.github/workflows/full_testing.yml +++ b/.github/workflows/full_testing.yml @@ -14,7 +14,7 @@ jobs: strategy: fail-fast: false matrix: - os: [ubuntu-latest, windows-latest] + os: [ubuntu-latest, windows-latest, macos-14] python-version: ['3.8', '3.10'] torch-version: [1.13.0, 2.0.0, 2.1.0, 2.2.0, nightly] include: @@ -28,6 +28,9 @@ jobs: torchvision-version: 0.17.0 - torch-version: nightly torchvision-version: nightly + exclude: + - os: macos-14 + python-version: '3.8' steps: - name: Checkout repository diff --git a/.github/workflows/testing.yml b/.github/workflows/testing.yml index b782b42dee27..8e55355f22b6 100644 --- a/.github/workflows/testing.yml +++ b/.github/workflows/testing.yml @@ -9,7 +9,19 @@ on: # yamllint disable-line rule:truthy jobs: pytest: - runs-on: ubuntu-latest + runs-on: ${{ matrix.os }} + + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, windows-latest, macos-14] + include: + - os: ubuntu-latest + python-version: '3.8' + - os: windows-latest + python-version: '3.8' + - os: macos-14 + python-version: '3.10' steps: - name: Checkout repository @@ -35,6 +47,8 @@ jobs: - name: Setup packages if: steps.changed-files-specific.outputs.only_changed != 'true' uses: ./.github/actions/setup + with: + python-version: ${{ matrix.python-version }} - name: Install main package if: steps.changed-files-specific.outputs.only_changed != 'true' diff --git a/test/graphgym/test_graphgym.py b/test/graphgym/test_graphgym.py index 8b3c1122f879..321c31bdff74 100644 --- a/test/graphgym/test_graphgym.py +++ b/test/graphgym/test_graphgym.py @@ -26,7 +26,7 @@ auto_select_device, params_count, ) -from torch_geometric.testing import onlyOnline, withPackage +from torch_geometric.testing import onlyLinux, onlyOnline, withPackage num_trivial_metric_calls = 0 @@ -164,6 +164,7 @@ def test_graphgym_module(tmp_path): @onlyOnline +@onlyLinux @withPackage('yacs', 'pytorch_lightning') def test_train(tmp_path, capfd): warnings.filterwarnings('ignore', ".*does not have many workers.*")