-
-
Notifications
You must be signed in to change notification settings - Fork 3.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Arf layout #5910
Arf layout #5910
Conversation
Small remark. Tests seem to be failing on test not relating to this PR. Local pytests pass for the changed files. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I hope these comments are helpful. I went through the code this time. And I found the numpy indexing and multiplying out arrays using newaxis to be somewhat difficult to grok... But hopefully you can help me some.
The tests don't contain any test that the values produced are specific values.
Do you have any cases where you know what the values should be?
The comments were helpful. I incorporated many changes and fixed and or added where necessary. I shared your feeling about numpy's broadcast system. It allows for neatly writing complex operations while obfuscating the operations. Using
I can't recall that the paper provides bounds or proofs of convergence. I believe the author argued that there are no objective markers for what makes a good layout and as such I can't provide an absolute test case other than a known heuristic that converges. The paper uses a few measures to determine the "success" of different test graphs. Are you looking for a particular case which has a known solution? One trivial example may be an empty graph that is approximated by a circle. Something like example
|
I was thinking more simple than the circle and hub layout obtained from an empty graph (which is nice for testing repulsion but not for attraction). I was thinking more like 3 nodes, 1 edge. Or even 2 nodes, 1 edge. But I'm leaning toward worrying about testing of all the spring-based layouts in another PR. This introduces new layout methods to the same level of testing that we are providing for the other layouts. It looks like the only test that is failing now is the |
Should be ok now. I would also be in favor of having a separate test suite part as a PR that would test the currently present force layouts. If you want I can have a poke at it and draft up the PR for testing the force layouts along the lines we discussed here and in #5311. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That would be great if you could put together a PR to take on the task of testing the force layouts.
Thanks!
* added arf_layout * reference to docstring and comparison to spring layout * rebase to origin main * black re-format * Left aligned docstring text * Cleaned up computation and update variables to new docstring * Updated naming tests. Added input check on arf_layout parameter `a` * Fixed Linter issues for py38 target * Fixed Linter issues for target p38 * linter issue fixed
* added arf_layout * reference to docstring and comparison to spring layout * rebase to origin main * black re-format * Left aligned docstring text * Cleaned up computation and update variables to new docstring * Updated naming tests. Added input check on arf_layout parameter `a` * Fixed Linter issues for py38 target * Fixed Linter issues for target p38 * linter issue fixed
Implements arf layout (Geipel 2006) which provides improvements over the traditional spring layout.
Short description
Example:
Plotting code