Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue in SplineCNN while clustering #6

Closed
shreygadiya opened this issue Aug 30, 2018 · 6 comments
Closed

Issue in SplineCNN while clustering #6

shreygadiya opened this issue Aug 30, 2018 · 6 comments

Comments

@shreygadiya
Copy link

Hi,
I was using the SplineCNN with InMemoryDataset for one of my own datasets. I am getting the following errror in training while using graclus:

THCudaCheck FAIL file=aten/THC/generic/THCDegree.cuh line=23 error=11 : invalid argument
Traceback (most recent call last):
File "BACH.py", line 96, in
train(epoch)
File "BACH.py", line 75, in train
out = model(data)
File "/home/Drive2/shrey/shrey/venvSpline/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 477, in call
result = self.forward(*input, **kwargs)
File "BACH.py", line 40, in forward
cluster = graclus(data.edge_index, weight, data.x.size(0))
File "/home/Drive2/shrey/shrey/venvSpline/local/lib/python2.7/site-packages/torch_geometric/nn/pool/graclus.py", line 6, in graclus
return graclus_cluster(row, col, weight, num_nodes)
File "/home/Drive2/shrey/shrey/venvSpline/local/lib/python2.7/site-packages/torch_cluster/graclus.py", line 34, in graclus_cluster
graclus(cluster, row, col, weight)
File "/home/Drive2/shrey/shrey/venvSpline/local/lib/python2.7/site-packages/torch_cluster/utils/ffi.py", line 12, in graclus
func(self, row, col) if weight is None else func(self, row, col, weight)
File "/home/Drive2/shrey/shrey/venvSpline/local/lib/python2.7/site-packages/torch/utils/ffi/init.py", line 202, in safe_call
result = torch._C._safe_call(*args, **kwargs)
torch.FatalError: cuda runtime error (11) : invalid argument at aten/THC/generic/THCDegree.cuh:23

The error pops up for one of the graph everytime (I am currently using batch size = 1 with no shuffling). Note that the no of nodes in each graph is same.

Any help in this regard would be appreciated. Thanks

@rusty1s
Copy link
Owner

rusty1s commented Aug 30, 2018

Mh I guess I need more information to help. The error occurs always on the same graph?
Does the graph

  • has no edges?
  • contains self-loops?
  • contains isolated nodes?

@shreygadiya
Copy link
Author

Hi,
The graph has following properties:
Batch(batch=[9667], edge_attr=[1120425, 2], edge_index=[2, 1120425], pos=[9667, 2], x=[9667, 64], y=[1])

Since you ask, is not having any self-loops or isolated nodes a necessity? Many of the other graphs are rather disconnected at multiple places. And each node has a self loop in all the graphs.

Thanks.

@rusty1s
Copy link
Owner

rusty1s commented Aug 30, 2018

Self-loops are removed internally before clustering is computed, so this should be no problem.
Isolated nodes shouldn't be a problem on GPU (the CPU version has an issue there).

Please check if edge_index.max().item() + 1 is less than or equal to 9667.

@rusty1s
Copy link
Owner

rusty1s commented Sep 28, 2018

Any updates?

@shreygadiya
Copy link
Author

Hi. I discarded the graphs that were giving me issue and training on the rest of the network. However, I stopped working on the project a while ago, so I don't know yet what the exact issue is with those graphs. I'll try to figure it out and get back to you in a week or two.

@rusty1s rusty1s closed this as completed Dec 15, 2018
@rusty1s rusty1s reopened this Dec 15, 2018
@shreygadiya
Copy link
Author

Hi,
I wanted to inform that currently I am no longer working on this project. If you wish you can close this issue.
Thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants