Replies: 1 comment 2 replies
-
If you are running with PyTorch 1.7.1, can you try to install |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
RuntimeError Traceback (most recent call last)
Cell In[1], line 6
4 import pickle as pkl
5 import torch
----> 6 from torch_geometric.data import Data, DataLoader
8 from utils.utils import build_spanning_tree_edge, find_higher_order_neighbors, add_self_loops
File ~/.conda/envs/xcml/lib/python3.9/site-packages/torch_geometric/init.py:4
1 from types import ModuleType
2 from importlib import import_module
----> 4 import torch_geometric.data
5 import torch_geometric.loader
6 import torch_geometric.transforms
File ~/.conda/envs/xcml/lib/python3.9/site-packages/torch_geometric/data/init.py:1
----> 1 from .data import Data
2 from .hetero_data import HeteroData
3 from .temporal import TemporalData
File ~/.conda/envs/xcml/lib/python3.9/site-packages/torch_geometric/data/data.py:20
18 import torch
19 from torch import Tensor
---> 20 from torch_sparse import SparseTensor
22 from torch_geometric.data.feature_store import (
23 FeatureStore,
24 FeatureTensorType,
25 TensorAttr,
26 _field_status,
27 )
28 from torch_geometric.data.graph_store import (
29 EDGE_LAYOUT_TO_ATTR_NAME,
30 EdgeAttr,
(...)
34 edge_tensor_type_to_adj_type,
35 )
File ~/.conda/envs/xcml/lib/python3.9/site-packages/torch_sparse/init.py:39
31 if t_major != major:
32 raise RuntimeError(
33 f'Detected that PyTorch and torch_sparse were compiled with '
34 f'different CUDA versions. PyTorch has CUDA version '
35 f'{t_major}.{t_minor} and torch_sparse has CUDA version '
36 f'{major}.{minor}. Please reinstall the torch_sparse that '
37 f'matches your PyTorch install.')
---> 39 from .storage import SparseStorage # noqa
40 from .tensor import SparseTensor # noqa
41 from .transpose import t # noqa
File ~/.conda/envs/xcml/lib/python3.9/site-packages/torch_sparse/storage.py:21
16 assert layout == 'coo' or layout == 'csr' or layout == 'csc'
17 return layout
20 @torch.jit.script
---> 21 class SparseStorage(object):
22 _row: Optional[torch.Tensor]
23 _rowptr: Optional[torch.Tensor]
File ~/.conda/envs/xcml/lib/python3.9/site-packages/torch/jit/_script.py:924, in script(obj, optimize, _frames_up, _rcb)
922 if _rcb is None:
923 _rcb = _jit_internal.createResolutionCallbackFromFrame(_frames_up + 1)
--> 924 _compile_and_register_class(obj, _rcb, qualified_name)
925 return obj
926 else:
927 # this is a decorated fn, and we need to the underlying fn and its rcb
File ~/.conda/envs/xcml/lib/python3.9/site-packages/torch/jit/_script.py:64, in _compile_and_register_class(obj, rcb, qualified_name)
62 ast = get_jit_class_def(obj, obj.name)
63 defaults = torch.jit.frontend.get_default_args_for_class(obj)
---> 64 torch._C._jit_script_class_compile(qualified_name, ast, defaults, rcb)
65 torch.jit._state._add_script_class(obj, qualified_name)
RuntimeError:
Arguments for call are not valid.
The following variants are available:
aten::div.Tensor(Tensor self, Tensor other) -> (Tensor):
Expected a value of type 'Tensor' for argument 'other' but instead found type 'int'.
aten::div.Scalar(Tensor self, Scalar other) -> (Tensor):
Keyword argument rounding_mode unknown.
aten::div.out(Tensor self, Tensor other, *, Tensor(a!) out) -> (Tensor(a!)):
Expected a value of type 'Tensor' for argument 'other' but instead found type 'int'.
aten::div.int(int a, int b) -> (float):
Keyword argument rounding_mode unknown.
aten::div.float(float a, float b) -> (float):
Expected a value of type 'float' for argument 'b' but instead found type 'int'.
aten::div(Scalar a, Scalar b) -> (float):
Keyword argument rounding_mode unknown.
div(float a, Tensor b) -> (Tensor):
Expected a value of type 'Tensor' for argument 'b' but instead found type 'int'.
div(int a, Tensor b) -> (Tensor):
Expected a value of type 'Tensor' for argument 'b' but instead found type 'int'.
The original call is:
File "/home/xuchen/.conda/envs/xcml/lib/python3.9/site-packages/torch_sparse/storage.py", line 316
idx = self.sparse_size(1) * self.row() + self.col()
I have had all the torch_geometric related packages installed.
Name Version Build Channel
_pytorch_select 0.1 cpu_0
pytorch 1.7.1 py3.9_cuda11.0.221_cudnn8.0.5_0 pytorch
torch 1.13.0 pypi_0 pypi
torch-cluster 1.6.0 pypi_0 pypi
torch-geometric 2.2.0 pypi_0 pypi
torch-scatter 2.0.7 pypi_0 pypi
torch-sparse 0.6.16 pypi_0 pypi
torch-spline-conv 1.2.1 pypi_0 pypi
torchaudio 0.7.2 py39 pytorch
torchvision 0.14.0 pypi_0 pypi
Beta Was this translation helpful? Give feedback.
All reactions