-
From the docs the details about what layout algorithm(s) the library uses are not clear. Does it support something like a Sugiyama variant for efficient and somewhat optimized layered DAG layout? There's not a ton of options for that, and most are kind of tied to specific other libraries. Performance is also an issue in JS obviously. Having a self-contained performant option would be useful. How does the layout algorithm used here compare to e.g. dagre or d3-dag? How is performance for different graph sizes? |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hey @senritsu, thanks for asking! tl;dr - it's a rough port of Dagre to rust with some rust specific optimizations, bug fixes, and tweaks. So definitely Sugiyama plus the others mentioned in Dagre's docs. I've tried hard to mimic the layouts of Dagre - I even ported almost all of the tests - but due to some of my changes the layouts are not always the same. I plan to write more layout algorithms and use more idiomatic rust patterns to aid future layout expansion. PerformanceSince it is based on Dagre, you can expect the same performance curve. For small graphs (~20 nodes), Vizdom will perform slower than Dagre because of the WASM data marshaling that must be done, but for medium/large (50+ nodes) Vizdom can be roughly 10x faster. I have not compared it against d3-dag. |
Beta Was this translation helpful? Give feedback.
Hey @senritsu, thanks for asking!
tl;dr - it's a rough port of Dagre to rust with some rust specific optimizations, bug fixes, and tweaks. So definitely Sugiyama plus the others mentioned in Dagre's docs.
I've tried hard to mimic the layouts of Dagre - I even ported almost all of the tests - but due to some of my changes the layouts are not always the same.
I plan to write more layout algorithms and use more idiomatic rust patterns to aid future layout expansion.
Performance
Since it is based on Dagre, you can expect the same performance curve. For small graphs (~20 nodes), Vizdom will perform slower than Dagre because of the WASM data marshaling that must be done, but for medium/large (5…