Skip to content

Commit a706309

Browse files
committed
backward compatibility with torch-sparse==0.6.9
1 parent 48eed83 commit a706309

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

.github/workflows/building.yml

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,10 +49,20 @@ jobs:
4949
python -c "import torch; print('PyTorch:', torch.__version__)"
5050
python -c "import torch; print('CUDA:', torch.version.cuda)"
5151
52-
- name: Install internal dependencies
52+
- name: Install torch-scatter
5353
run: |
5454
pip install torch-scatter -f https://pytorch-geometric.com/whl/torch-${{ matrix.torch-version }}+${{ matrix.cuda-version }}.html
5555
56+
- name: Install METIS
57+
if: ${{ runner.os != 'Windows' }}
58+
run: |
59+
bash .github/workflows/metis.sh
60+
61+
- name: Install METIS on Windows
62+
if: ${{ runner.os == 'Windows' }}
63+
run: |
64+
bash .github/workflows/metis-${{ runner.os }}.sh
65+
5666
- name: Install main package for CPU
5767
if: ${{ matrix.cuda-version == 'cpu' }}
5868
run: |

csrc/metis.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ torch::Tensor partition(torch::Tensor rowptr, torch::Tensor col,
2121
AT_ERROR("Not compiled with CUDA support");
2222
#endif
2323
} else {
24-
return partition_cpu(rowptr, col, optional_value, nullptr, num_parts,
24+
return partition_cpu(rowptr, col, optional_value, torch::nullopt, num_parts,
2525
recursive);
2626
}
2727
}

0 commit comments

Comments
 (0)