Skip to content

Commit

Permalink
Simplified and sped KBestHaplotypeFinder by replacing recursion with …
Browse files Browse the repository at this point in the history
…Dijkstra's algorithm
  • Loading branch information
davidbenjamin committed Dec 27, 2018
1 parent b928029 commit 2834e09
Show file tree
Hide file tree
Showing 19 changed files with 113 additions and 1,626 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ private Collection<Path<V,E>> likelyErrorChains(final List<Path<V, E>> chains, f

chains.stream().filter(c -> isChainPossibleVariant(c, graph))
.sorted(Comparator.comparingDouble((ToDoubleFunction<Path<V, E>>) chainLogOdds::get)
.reversed().thenComparingInt(Path::getScore))
.reversed().thenComparingInt(Path::length))
.skip(maxUnprunedVariants)
.forEach(result::add);

Expand Down

This file was deleted.

This file was deleted.

Loading

0 comments on commit 2834e09

Please sign in to comment.