-
Notifications
You must be signed in to change notification settings - Fork 338
[REVIEW] Fix louvain #870
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
Merged
Merged
[REVIEW] Fix louvain #870
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) Code cleanup, a bit more modularization 2) Fix python bindings to work with new code 3) Now that Louvain works, debug ECG issues
Contributor
|
Please update the changelog in order to start CI tests. View the gpuCI docs here. |
Codecov Report
@@ Coverage Diff @@
## branch-0.14 #870 +/- ##
===============================================
+ Coverage 47.66% 47.81% +0.15%
===============================================
Files 44 44
Lines 1328 1328
===============================================
+ Hits 633 635 +2
+ Misses 695 693 -2
Continue to review full report at Codecov.
|
BradReesWork
approved these changes
May 27, 2020
afender
approved these changes
May 27, 2020
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR refactors the implementation of Louvain. The old implementation did not really implement Louvain. It computed modularity (almost correctly) but then ignored the modularity computation when computing the clustering at each level of algorithm.
The new implementation is partially serial. The portion of the algorithm that attempts to compute delta modularity for each vertex will operate on the vertices in serial. All other aspects of the algorithm have been parallelized. Serializing this portion of the algorithm allows us to compare results with networkx and other serial implementations to validate that the results are correct.
There is some parallelism in that step. While we operate on the vertices in serial, we do a parallel computation (using only one warp) so that computing the delta modularity will get 1 warp worth of parallelism.
It can definitely be improved with more parallelism, but doing this and guaranteeing convergence is hard, it seemed like getting something correct and faster than serial CPU code would be a good first step.
Closes #509
Closes #668
With correct Louvain scores, this PR also fixes the ECG that was disabled in PR #823 and deletes some code now obsolete that was referenced by the old Louvain implementation.