Skip to content
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

speed up flagging with ItervalTree #78

Open
keiranmraine opened this issue Jul 20, 2019 · 0 comments
Open

speed up flagging with ItervalTree #78

keiranmraine opened this issue Jul 20, 2019 · 0 comments
Assignees

Comments

@keiranmraine
Copy link
Contributor

keiranmraine commented Jul 20, 2019

Most of the flagging code is looking for simple "hit" lookups in tabix files. This can be handled in exactly the same way as the input generation speed up.

Will have additional advantages as current code wraps each query with an eval which is expensive:

my $ret = eval{
my $iter = $vcf_flagging_unmatched_normals_tabix->query_full($CHROM,$from,$to);
return $PASS if(!defined $iter); # no valid entries (chromosome not in index) so must pass
while($iter->next){
return $FAIL;
}
return $PASS;
};
if($@) {
die $@;
}

Should be able to hide this in the reuse_unmatched_normals_tabix and reuse_repeats_tabix functions. Needs to be applied in both FilterRules.pm and FragmentFilterRules.pm.

@keiranmraine keiranmraine self-assigned this Jul 20, 2019
@keiranmraine keiranmraine changed the title WIP: speed up flagging with ItervalTree speed up flagging with ItervalTree Jul 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant