graspologic icon indicating copy to clipboard operation
graspologic copied to clipboard

Graph utility: "At Most N Edges"

Open daxpryce opened this issue 5 years ago • 4 comments

Post graspy + topologic merger, we have a request to make it easy to turn a large graph into a smaller graph based on edge cuts. The idea is that a user may have a graph with 10 million edges and want to work with at most 1m edges, so we should be able to do that automatically on their behalf

daxpryce avatar Sep 15 '20 19:09 daxpryce

based on edge cuts

like just by weight, or by any other properties of the network? reason I ask is I saw some math voodoo paper about "sparsifying" networks (adjacency matrices) and keeping the spectral structure as similar as possible

bdpedigo avatar Sep 15 '20 20:09 bdpedigo

I know for sure we want to do weight, but I guarantee that @bryantower is going to be interested in hearing more about the other options

daxpryce avatar Sep 15 '20 20:09 daxpryce

The specific feature that I would like to see is the one that Dwayne mentioned. I want at most X total edges, please cut the minimum number of edges to make that happen, by removing the lowest weight edges first.

bryantower avatar Sep 15 '20 20:09 bryantower

well, an obvious way is : turn_to_edgelist -> sort -> head(X), which is O(V^2 + E log(E)) i think (V^2 comes from converting to edgelist if you are given adjacency matrix, so it's there, but it is fast), but we might be able to do better than that..

alyakin314 avatar Sep 16 '20 18:09 alyakin314