Commit 3960b025 authored by Cyprien Borée's avatar Cyprien Borée

Increment filtered_sequences_calls and filtered_sequences_nb in filter.cpp

For more informations see #3259.
parent 1f21fa21
#include "filter.h"
FilterWithACAutomaton::FilterWithACAutomaton(BioReader &origin, string seed){
this->filtered_sequences_nb = 0;
this->filtered_sequences_calls = 0;
buildACAutomatonToFilterBioReader(origin, seed);
}
......@@ -61,7 +63,9 @@ BioReader FilterWithACAutomaton::filterBioReaderWithACAutomaton(
BioReader result;
map<KmerAffect, int> mapAho;
this->filtered_sequences_calls += 1;
if(!automaton || !indexes || kmer_threshold < 0){
this->filtered_sequences_nb += origin.size();
return origin;
}
mapAho = automaton->getMultiResults(seq);
......@@ -101,6 +105,7 @@ BioReader FilterWithACAutomaton::filterBioReaderWithACAutomaton(
previousOccurences = element.second;
}
}
this->filtered_sequences_nb += (result.size () == 0) ? origin.size() : result.size();
return (result.size() == 0) ? origin : result;
}
......
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