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

Problem with Dydigraph time_slice() + interactions() #135

Open
tommantonela opened this issue Feb 8, 2022 · 0 comments · May be fixed by #159
Open

Problem with Dydigraph time_slice() + interactions() #135

tommantonela opened this issue Feb 8, 2022 · 0 comments · May be fixed by #159

Comments

@tommantonela
Copy link

Hi,
I was running the code for the example of the time_slice method, and the output does not match the one in the documentation.
Given:

G = dn.DynDiGraph()
G.add_interaction(0,1, t=0)
G.add_interaction(1,2, t=0)
G.add_interaction(2,3, t=0)
G.add_interaction(0,4, t=1)
G.add_interaction(4,5, t=1)
G.add_interaction(5,6, t=1)
G.add_interaction(7,1, t=2)
G.add_interaction(1,2, t=2)
G.add_interaction(2,3, t=2)
H = G.time_slice(0)
H.interactions()

The output should be: [(0, 1), (1, 2), (1, 3)], but instead, it is [(0, 1, {'t': [[0, -1]]})]. Notice also the -1 in the t. Nonetheless, for [e for e in G1.time_slice(0).edges()] the output is correct (except for the t, which continue to show -1).

Could it be related to how seen is populated in interactions_iter?

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 a pull request may close this issue.

1 participant