scott icon indicating copy to clipboard operation
scott copied to clipboard

Error when creating adjacency matrix of simple graph

Open janlaub opened this issue 3 months ago • 1 comments

Hello!

I am iteratively generating graphs and want to get the adjacency matrix for each one of them. In the beginning, the my graph is very simple (4 nodes that each connect to a fifth central node, no loops). This leads to the list permut in graph.py line 437 being empty. Thus, the flatten function in line 447 throws an out of index error. I fixed this problem by checking if permut is empty before calling the flatten function.

Thank you for this nice repository!

janlaub avatar May 15 '24 09:05 janlaub