-
Notifications
You must be signed in to change notification settings - Fork 4
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
MRG: fix performance regression in manysearch
by removing unnecessary downsampling
#464
Conversation
manysearch
manysearch
manysearch
manysearch
by removing unnecessary downsampling
@bluegenes ready for review & merge! |
bump :) |
// avoid calculating details unless there is overlap | ||
let overlap = query | ||
.minhash | ||
.count_common(against_mh, true) |
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.
ah, count_common handles downsampling only if needed. Didn't realized downsample_scaled
always downsampled, even if not needed!
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.
yep!
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.
lgtm
Tackles #463
This PR adjusts
manysearch
so that downsampling is only done on sketches when actually needed. Prior to this, thedownsample_max_hash/downsample_scaled
code was running on sketches even when there was no need.This PR also adds
--ignore-abundance
tomanysearch
which optionally turns off potentially expensive abundance estimation (which in practice is not that expensive, apparently; see #463).Fixes #466