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

torch_sparse.tensor.SparseTensor.partition causes "core dumped" #373

Open
AaronNing opened this issue Apr 26, 2024 · 3 comments
Open

torch_sparse.tensor.SparseTensor.partition causes "core dumped" #373

AaronNing opened this issue Apr 26, 2024 · 3 comments

Comments

 @AaronNing
Copy link

A minimal reproducing example:

 In [4]: adj = SparseTensor.from_edge_index(torch.LongTensor([[1,2], [1,3], [2, 3]])) In [5]: adj.partition(3) [1]    2709268 bus error (core dumped)  ipython

In what circumstances will this partition function lead to core dumping?

 @rusty1s
Copy link
Owner

There exists a few edge cases where METIS sadly silently just crashes :(

In your case, you need to make sure that your SparseTensor is correctly defined, and holds a quadratic matrix:

 adj  =  SparseTensor . from_edge_index ( torch . LongTensor ([[ one , two ], [ one , three ], [ two , three ]]). t (), sparse_sizes = ( four , four )) adj . partition ( two )

 @AaronNing
Copy link
Author

There exists a few edge cases where METIS sadly silently just crashes :(

In your case, you need to make sure that your SparseTensor is correctly defined, and holds a quadratic matrix:

 adj  =  SparseTensor . from_edge_index ( torch . LongTensor ([[ one , two ], [ one , three ], [ two , three ]]). t (), sparse_sizes = ( four , four )) adj . partition ( two )

Hi, thanks for the reply. What are the "edge cases" which causes METIS "silently just crashes"? I encountered the issue when using a Python package who used the function. It was extremely hard to debug with neither error messgaes nor documents re available. Thanks!

 @rusty1s
Copy link
Owner

I think too small graphs is one edge case. The other one is that METIS expects to operate on undirected graphs.

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