@@ -2,6 +2,10 @@ name: Building Wheels
22
33on : [workflow_dispatch]
44
5+ defaults :
6+ run :
7+ shell : bash
8+
59jobs :
610
711 wheel :
@@ -10,38 +14,61 @@ jobs:
1014 strategy :
1115 fail-fast : false
1216 matrix :
13- os : [ubuntu-20 .04, macos-14, windows-2019 ]
14- python-version : ['3.8 ', '3.9 ', '3.10 ', '3.11 ', '3.12 ']
15- torch-version : [2.5.0] # [2.3.0, 2.4.0, 2.5 .0]
16- cuda-version : ['cpu', 'cu118', 'cu121 ', 'cu124 ']
17+ os : [ubuntu-22 .04, macos-14, windows-2022, ubuntu-22.04-arm ]
18+ python-version : ['3.9 ', '3.10 ', '3.11 ', '3.12 ', '3.13 ']
19+ torch-version : [2.8 .0]
20+ cuda-version : ['cpu', 'cu118', 'cu124 ', 'cu126', 'cu128', 'cu129 ']
1721 exclude :
18- - torch-version : 2.5.0
19- python-version : ' 3.8'
20- - torch-version : 2.3.0
22+ - torch-version : 2.6.0
23+ cuda-version : ' cu128'
24+ - torch-version : 2.6.0
25+ cuda-version : ' cu129'
26+ - torch-version : 2.7.0
27+ cuda-version : ' cu124'
28+ - torch-version : 2.7.0
29+ cuda-version : ' cu129'
30+ - torch-version : 2.8.0
31+ cuda-version : ' cu118'
32+ - torch-version : 2.8.0
2133 cuda-version : ' cu124'
2234 - os : macos-14
2335 cuda-version : ' cu118'
2436 - os : macos-14
25- cuda-version : ' cu121 '
37+ cuda-version : ' cu124 '
2638 - os : macos-14
39+ cuda-version : ' cu126'
40+ - os : macos-14
41+ cuda-version : ' cu128'
42+ - os : macos-14
43+ cuda-version : ' cu129'
44+ - os : ubuntu-22.04-arm
45+ cuda-version : ' cu118'
46+ - os : ubuntu-22.04-arm
2747 cuda-version : ' cu124'
48+ - os : ubuntu-22.04-arm
49+ cuda-version : ' cu126'
50+ - os : ubuntu-22.04-arm
51+ cuda-version : ' cu128'
52+ - os : ubuntu-22.04-arm
53+ cuda-version : ' cu129'
2854
2955 steps :
30- - uses : actions/checkout@v2
56+ - uses : actions/checkout@v4
3157 with :
3258 submodules : ' recursive'
3359
3460 - name : Set up Python ${{ matrix.python-version }}
35- uses : actions/setup-python@v2
61+ uses : actions/setup-python@v5
3662 with :
3763 python-version : ${{ matrix.python-version }}
3864
3965 - name : Upgrade pip
4066 run : |
4167 pip install --upgrade setuptools
68+ pip install wheel
4269
4370 - name : Install scipy
44- if : ${{ ( matrix.python-version == '3.8') || (matrix.python-version == '3.9') }}
71+ if : ${{ matrix.python-version == '3.9' }}
4572 run : |
4673 pip install scipy==1.10.1
4774
6996 echo "New version name: $VERSION+$TORCH_VERSION$CUDA_VERSION"
7097 sed -i "s/$VERSION/$VERSION+$TORCH_VERSION$CUDA_VERSION/" setup.py
7198 sed -i "s/$VERSION/$VERSION+$TORCH_VERSION$CUDA_VERSION/" torch_sparse/__init__.py
72- shell :
73- bash
7499
75100 - name : Install torch-scatter
76101 run : |
@@ -80,35 +105,30 @@ jobs:
80105 if : ${{ runner.os != 'Windows' }}
81106 run : |
82107 bash .github/workflows/metis.sh
108+ echo WITH_METIS=1 >> $GITHUB_ENV
83109
84110 - name : Install METIS on Windows
85111 if : ${{ runner.os == 'Windows' }}
86112 run : |
87- bash .github/workflows/metis-${{ runner.os }}.sh
113+ # bash .github/workflows/metis-${{ runner.os }}.sh
114+ echo WITH_METIS=0 >> $GITHUB_ENV
88115
89- - name : Install main package for CPU
116+ - name : Build wheel for CPU
90117 if : ${{ matrix.cuda-version == 'cpu' }}
91118 run : |
92- FORCE_ONLY_CPU=1 WITH_METIS=1 python setup.py develop
93- shell :
94- bash
119+ python setup.py bdist_wheel --dist-dir=dist
120+ env :
121+ FORCE_ONLY_CPU : 1
122+ WITH_METIS : ${{ env.WITH_METIS }}
95123
96- - name : Install main package for GPU
124+ - name : Build wheel for GPU
97125 if : ${{ matrix.cuda-version != 'cpu' }}
98126 run : |
99127 source .github/workflows/cuda/${{ matrix.cuda-version }}-${{ runner.os }}-env.sh
100- WITH_METIS=1 python setup.py develop
101- shell :
102- bash
103-
104- - name : Test installation
105- run : |
106- python -c "import torch_sparse; print('torch-sparse:', torch_sparse.__version__)"
107-
108- - name : Build wheel
109- run : |
110- pip install wheel
111128 python setup.py bdist_wheel --dist-dir=dist
129+ env :
130+ FORCE_CUDA : 1
131+ WITH_METIS : ${{ env.WITH_METIS }}
112132
113133 - name : Configure AWS
114134 uses : aws-actions/configure-aws-credentials@v1
0 commit comments