-
Notifications
You must be signed in to change notification settings - Fork 259
feat: expose voronoi to python #833
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
base: develop
Are you sure you want to change the base?
feat: expose voronoi to python #833
Conversation
Try to avoid re-formatting the |
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.
Only a few comments, not an exhaustive review.
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.
Not a full review yet, I haven't checked the unit test and the Python side in detail. From a bird's eye view the Python side looks good.
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.
Pull Request Overview
This pull request exposes a new Voronoi community detection algorithm to Python.
- Adds new test cases in tests/test_decomposition.py to validate the Voronoi clustering implementation.
- Implements the _community_voronoi function in src/igraph/community.py with detailed documentation.
- Updates the Python API and C extension bindings in src/igraph/init.py and src/_igraph/graphobject.c respectively.
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
File | Description |
---|---|
tests/test_decomposition.py | Introduces tests for the community_voronoi method using multiple graph scenarios. |
src/igraph/community.py | Implements the Voronoi clustering algorithm with comprehensive documentation. |
src/igraph/init.py | Exposes the new community_voronoi function through the public API. |
src/_igraph/graphobject.c | Adds the C extension binding for community_voronoi, handling Python–C argument conversion and result packaging. |
I think |
Co-authored-by: Szabolcs Horvát <[email protected]>
I used Cody for the functions.