47 ms·
Graphs are usually persisted as a list of nodes and a list of vertices. The ML approaches usually use tuples or triplets of nodes to represent connectivity and
by trumpeta 6y ago
Graphs are usually persisted as a list of nodes and a list of vertices. The ML approaches usually use tuples or triplets of nodes to represent connectivity and model neighborhood. I wonder if that can not be used to model a graph in a linear system?
- DougBTX 6y agoYes, that makes a lot of sense. The ownership would be linear: struct Graph { nodes: Vec<Node>, edges: Vec<Edge>, } but the associations between nodes would have an arbitrary structure. The article suggests that handles are better than references anyway (I'd tend to agree in this case) so Edge would be a pair of handles. That seems totally fine, so maybe the "fatal flaw" is overstated...