Added a little bit of hack to get the header back to the walker by initialization time, which was before sharding in the last version.

git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@516 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
aaron 2009-04-23 21:07:11 +00:00
parent 0208d201c7
commit 635bfd8604
1 changed files with 9 additions and 2 deletions

View File

@ -103,8 +103,8 @@ public class MicroManager {
throw new RuntimeException( ex );
}
walker.initialize();
Object accumulator = ((LocusWalker<?,?>)walker).reduceInit();
boolean walkerInitialized = false;
Object accumulator = null;
for(Shard shard: shardStrategy) {
// CloseableIterator<SAMRecord> readShard = null;
@ -121,6 +121,13 @@ public class MicroManager {
// set the sam header of the traversal engine
traversalEngine.setSAMHeader(readShard.getMergedHeader());
if (!walkerInitialized) {
walker.initialize();
accumulator = ((LocusWalker<?,?>)walker).reduceInit();
walkerInitialized = true;
}
System.err.println(traversalEngine.getSAMHeader().getSequenceDictionary().toString());
accumulator = traversalEngine.traverse( walker, shard, referenceProvider, locusProvider, accumulator );
readShard.close();