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

Possible bug in scatter_sum #228

Open
soham0209 opened this issue Sep 29, 2023 · 0 comments
Open

Possible bug in scatter_sum #228

soham0209 opened this issue Sep 29, 2023 · 0 comments

Comments

@soham0209
Copy link
Collaborator

The bug happens when the last cell / simplex (index-wise) is isolated. Simple code to reproduce the issue:

from toponetx.classes.cell_complex import CellComplex
import torch
from topomodelx.base.conv import Conv


if __name__ == '__main__':
    complex = CellComplex()
    complex.add_cell([0,1,2], 2)
    complex.add_cell([0,1,3], 2)
    complex.add_node(4)
    vertex_feats = torch.zeros(5, 3)
    hidden_dim = 8
    A0 = torch.from_numpy(complex.adjacency_matrix(rank=0).todense()).to_sparse().float()
    
conv_0_to_0 = Conv(
            in_channels=in_channels_0, out_channels=in_channels_0, att=False
        )
    
    zv = conv_0_to_0(vertex_feats, A0)
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

1 participant