Bugfix for counting of applied filters

-- Because LocusWalkers have multiple filtering streams, each counting filtering independent, and the close() function set calling setFilter on the global result, not on the private counter, which is incorporated into the global (thereby incrementing the counts of each filter).
-- [delivers #52667213]
This commit is contained in:
Mark DePristo 2013-07-01 21:09:48 -04:00
parent c3d59d890d
commit 9df58314ab
1 changed files with 2 additions and 2 deletions

View File

@ -115,10 +115,10 @@ public class CountingFilteringIterator implements CloseableIterator<SAMRecord> {
public void close() {
CloserUtil.close(iterator);
for ( final CountingReadFilter filter : filters )
privateRuntimeMetrics.setFilterCount(filter.readFilter.getClass().getSimpleName(), filter.counter);
// update the global metrics with all the data we collected here
globalRuntimeMetrics.incrementMetrics(privateRuntimeMetrics);
for ( final CountingReadFilter filter : filters )
globalRuntimeMetrics.setFilterCount(filter.readFilter.getClass().getSimpleName(), filter.counter);
}
/**