name: Building Wheels on: [workflow_dispatch] jobs: wheel: runs-on: ${{ matrix.os }} strategy: fail-fast: false matrix: os: [ubuntu-18.04, macos-10.15, windows-2019] python-version: ['3.7', '3.8', '3.9', '3.10'] torch-version: [1.10.0, 1.11.0] cuda-version: ['cpu', 'cu102', 'cu113', 'cu115'] exclude: - torch-version: 1.10.0 cuda-version: 'cu115' - torch-version: 1.10.0 python-version: '3.10' - os: windows-2019 torch-version: 1.11.0 cuda-version: 'cu102' - os: macos-10.15 cuda-version: 'cu102' - os: macos-10.15 cuda-version: 'cu113' - os: macos-10.15 cuda-version: 'cu115' # There is a weird bug going on for this combination: - os: windows-2019 python-version: '3.7' cuda-version: 'cu115' steps: - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v2 with: python-version: ${{ matrix.python-version }} - name: Free up disk space if: ${{ runner.os == 'Linux' }} run: | sudo rm -rf /usr/share/dotnet - name: Install CUDA ${{ matrix.cuda-version }} if: ${{ matrix.cuda-version != 'cpu' }} run: | bash .github/workflows/cuda/${{ matrix.cuda-version }}-${{ runner.os }}.sh - name: Install PyTorch ${{ matrix.torch-version }}+${{ matrix.cuda-version }} run: | pip install numpy typing-extensions dataclasses pip install --no-index --no-cache-dir torch==${{ matrix.torch-version}} -f https://download.pytorch.org/whl/${{ matrix.cuda-version }}/torch_stable.html python -c "import torch; print('PyTorch:', torch.__version__)" python -c "import torch; print('CUDA:', torch.version.cuda)" - name: Install torch-scatter run: | pip install torch-scatter -f https://data.pyg.org/whl/torch-${{ matrix.torch-version }}+${{ matrix.cuda-version }}.html - name: Install METIS if: ${{ runner.os != 'Windows' }} run: | bash .github/workflows/metis.sh - name: Install METIS on Windows if: ${{ runner.os == 'Windows' }} run: | bash .github/workflows/metis-${{ runner.os }}.sh - name: Install main package for CPU if: ${{ matrix.cuda-version == 'cpu' }} run: | FORCE_ONLY_CPU=1 WITH_METIS=1 pip install -e . shell: bash - name: Install main package for GPU if: ${{ matrix.cuda-version != 'cpu' }} run: | source .github/workflows/cuda/${{ matrix.cuda-version }}-${{ runner.os }}-env.sh WITH_METIS=1 pip install -e . shell: bash - name: Build wheel run: | pip install wheel python setup.py bdist_wheel --dist-dir=dist - name: Configure AWS uses: aws-actions/configure-aws-credentials@v1 with: aws-access-key-id: ${{ secrets.AWS_ACCESS_KEY_ID }} aws-secret-access-key: ${{ secrets.AWS_SECRET_ACCESS_KEY }} aws-region: us-west-1 - name: Upload wheel run: | aws s3 sync dist s3://data.pyg.org/whl/torch-${{ matrix.torch-version }}+${{ matrix.cuda-version }} --grants read=uri=http://acs.amazonaws.com/groups/global/AllUsers