Improve scalability of centrality computation using sparse matrix#969
Improve scalability of centrality computation using sparse matrix#969sandeepvaday wants to merge 3 commits intonetworkx:masterfrom
Conversation
|
Also, since we don't have a hard dependency on |
|
Sometimes it is better to use sparse and sometimes it is better to use Also, in looking at the PR, there is a function smat used. What is that? On Sun, Oct 6, 2013 at 8:35 PM, chebee7i notifications@github.com wrote:
|
|
Can we just use to_scipy_sparse_matrix() instead of smat? There is discussion in #913 about using sparse matrices for all of the linear algebra operations in NetworkX. |
|
My first attempt was to utilize Using sparse matrices would indeed be a good idea. This is an implementation that I have been using for my own work which makes it applicable for large graphs. So I thought I'd share it. |
|
Using the sparse eigensolver is probably the right approach for large enough problems and I like the approach. |
|
@hagberg Issue opened w.r.t to_scipy_sparse_matrix() thanks |
|
Can this be updated to use to_scipy_sparse_matrix() ? |
|
Yeah, I'm on it. |
To enable computation of eigenvector centrality scores for all nodes, in a graph with more than just a few thousand nodes, I have used sparse matrix representation here. Please take a look.
A note:
http://docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.linalg.eigs.html
k=6 is the default