Skip to content

Commit 0923ad8

Browse files
authored
Merge pull request #304 from AndBoyS/master
Remove torch-sparse and torch-scatter dependencies
2 parents efb18e1 + c9f5ee6 commit 0923ad8

File tree

3 files changed

+4
-8
lines changed

3 files changed

+4
-8
lines changed

.github/workflows/main.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,6 @@ jobs:
2929
- name: Install main dependencies
3030
run: |
3131
python -m pip install torch==2.3.0 torchvision torchaudio -f https://download.pytorch.org/whl/cpu/torch_stable.html
32-
python -m pip install torch-sparse -f https://data.pyg.org/whl/torch-2.3.0+cpu.html
33-
python -m pip install torch-scatter -f https://data.pyg.org/whl/torch-2.3.0+cpu.html
3432
python -m pip install torch-geometric
3533
python -m pip install sphinx sphinx_rtd_theme
3634
- name: Install main package

setup.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,11 @@
44
"decorator==4.4.2",
55
"torch",
66
"cython",
7-
"torch_sparse",
8-
"torch_scatter",
97
"torch_geometric",
108
"numpy",
119
"networkx",
1210
]
13-
tests_require = ["pytest", "pytest-cov", "mock", "networkx", "tqdm",'dask', "pandas", "tables"]
11+
tests_require = ["pytest", "pytest-cov", "mock", "networkx", "tqdm",'dask', "pandas", "tables", "scipy"]
1412
index_require = ['dask', "pandas", "tables"]
1513
ddp_require = ["dask[distributed]", "dask_pytorch_ddp", "pandas", "tables"]
1614

torch_geometric_temporal/nn/recurrent/evolvegcno.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
from torch import Tensor
55
from torch.nn import GRU
66
from torch_geometric.typing import Adj, OptTensor
7-
from torch_sparse import SparseTensor
7+
from torch_geometric.typing import SparseTensor
88
from torch_geometric.nn.inits import glorot
99
from torch_geometric.nn.conv import MessagePassing
1010
from torch_geometric.nn.conv.gcn_conv import gcn_norm
@@ -142,7 +142,7 @@ def __init__(
142142
self.weight = None
143143
self._create_layers()
144144
self.reset_parameters()
145-
145+
146146
def reset_parameters(self):
147147
glorot(self.initial_weight)
148148

@@ -182,7 +182,7 @@ def forward(
182182
Return types:
183183
* **X** *(PyTorch Float Tensor)* - Output matrix for all nodes.
184184
"""
185-
185+
186186
if self.weight is None:
187187
_, self.weight = self.recurrent_layer(self.initial_weight, self.initial_weight)
188188
else:

0 commit comments

Comments
 (0)