Skip to content

Fix higher-order ID detection by checking IndexMap tuple IDs#324

Merged
vineetbansal merged 1 commit into
devfrom
vb/issue323
Jul 20, 2026
Merged

Fix higher-order ID detection by checking IndexMap tuple IDs#324
vineetbansal merged 1 commit into
devfrom
vb/issue323

Conversation

@vineetbansal

@vineetbansal vineetbansal commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator

Closes #323

Node/edge iteration and plotting decided whether IDs were tuples by checking graph.order > 1. This PR bases the decision on the actual ID structure instead of graph order.

Graph order and ID structure may not always coincide - in an upcoming EventGraph, the order is 2, but it provides its own mapping IDs constructed from the underlying TemporalGraph. The same will probably be true for an upcoming HigherOrderGraph.

@vineetbansal
vineetbansal requested a review from M-Lampert July 17, 2026 19:33
@vineetbansal
vineetbansal changed the base branch from main to dev July 17, 2026 20:50

@M-Lampert M-Lampert left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like a good way to fix this problem temporarily. Feel free to merge it.

But I still think we should remove these functionalities from the base Graph-class once we have the HigherOrderGraph, since then no higher-order graphs should use the Graph-class but either EventGraph or HigherOrderGraph instead.

@vineetbansal

Copy link
Copy Markdown
Collaborator Author

Thanks @M-Lampert - let me merge this then, so EventGraph can be merged shortly as well (I'll add a test there to ensure that the labels on nodes will now come out correct) Then we can revisit this for the longer term.

@vineetbansal
vineetbansal merged commit 1cde6e1 into dev Jul 20, 2026
5 checks passed
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

Successfully merging this pull request may close these issues.

Higher-order graph handling inside Graph conflicts with new higher-order classes like EventGraph

2 participants