Commit ab5ca697 authored by Mikaël Salson's avatar Mikaël Salson

Merge branch 'feature-a/2138-backtrack-only-when-improving' into 'dev'

core/segment.cpp: backtrack only when the score is improving, even for 'local' (D)

See merge request !693
parents 7f426d91 f5ff934a
Pipeline #147564 failed with stages
in 1 minute and 6 seconds
......@@ -895,12 +895,9 @@ void align_against_collection(string &read, BioReader &rep, int forbidden_rep_id
int score = dp.compute(onlyBottomTriangle, BOTTOM_TRIANGLE_SHIFT);
if (local==true){
dp.backtrack();
}
if (score > best_score)
{
{
dp.backtrack();
best_score = score ;
best_best_i = dp.best_i ;
best_best_j = dp.best_j ;
......@@ -908,9 +905,6 @@ void align_against_collection(string &read, BioReader &rep, int forbidden_rep_id
best_first_j = dp.first_j ;
box->ref_nb = r ;
box->ref_label = rep.label(r) ;
if (!local)
dp.backtrack();
box->marked_pos = dp.marked_pos_i ;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment