-
Notifications
You must be signed in to change notification settings - Fork 14
Add famst crate: Fast Approximate Minimum Spanning Tree #93
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
Open
+1,326
−0
Open
Changes from all commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
6d04e9d
Add famst crate: Fast Approximate Minimum Spanning Tree
jorendorff c09952f
Fix O(n2) initialization bug in NN-Descent
jorendorff 4ad3eb2
Unify duplicate loops in extract_mst
jorendorff 9249548
Remove unnecessary edge deduplication in extract_mst
jorendorff c14f0cb
Unify n==0 and n==1 cases, remove debug println
jorendorff 4ccefd9
Add tests for empty and single-point inputs
jorendorff 60d85f2
Add test for k >= n case
jorendorff e37f359
Manual tweaks.
jorendorff b3a257b
Replace HashSets with sorted Vecs for memory efficiency
jorendorff 12c98c9
Refactor AnnGraph to use single flat allocation
jorendorff 2561f99
Make internal types private
jorendorff 4ec0063
Switch to 32-bit types for memory efficiency
jorendorff 2940252
extract nn_descent into separate file
aneubeck 2d42e40
refactor a bit more
aneubeck 4590627
use NodeId type everywhere
aneubeck 7f8ee78
Update lib.rs
aneubeck ea848b5
improve find_components a bit
aneubeck 0014f86
more simplifications
aneubeck dfad6d7
fix tests
aneubeck 2375b36
start using rayon
aneubeck 9b45210
introduce new marker
aneubeck a8af2c6
Update lib.rs
aneubeck d4e68c7
rewrite reverse edge computation
aneubeck 5477533
Update nn_descent.rs
aneubeck 34b6e1f
Use more cache-friendly loop
aneubeck ca7b074
slightly faster parallel version (but it seem like a single threaded ...
aneubeck c8c1689
fastest version so far
aneubeck 8eb4090
Update nn_descent.rs
aneubeck 4de8ce9
Update lib.rs
aneubeck File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,13 @@ | ||
| [package] | ||
| name = "famst" | ||
| version = "0.1.0" | ||
| edition = "2024" | ||
| description = "Fast Approximate Minimum Spanning Tree (FAMST) algorithm" | ||
| license = "MIT" | ||
|
|
||
| [dependencies] | ||
| rand = { version = "0.8", features = ["small_rng"] } | ||
| rayon = "1" | ||
|
|
||
| [dev-dependencies] | ||
| rand = "0.8" |
Oops, something went wrong.
Oops, something went wrong.
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.