Open Vimos opened 3 months ago
Try calling Graph.Adjacency(adj_matrix.astype(numpy.int32))
instead. Your matrix contains floating-point numbers; igraph tries to interpret the entries of the matrix as edge multiplicities, which are supposed to be integers. Alternatively, if you want a weighted matrix, use Graph.Weighted_Adjacency()
instead.
Describe the bug A clear and concise description of what the bug is.
Failed to use
scipy.sparse._csr.csr_matrix
to init a graph.To reproduce Steps or minimal example code to reproduce the problem.
If you are confident that the issue is not in the Python interface but in the C core of igraph, please add it to the main igraph repo instead.
If you are unsure, feel free to add your issue here - we will transfer it to the main igraph repo if the root cause is in the C core of igraph.
Version information Which version of
python-igraph
are you using and where did you obtain it?git+https://github.com/igraph/python-igraph@develop