CountLoci nows writes out to a file for Queue status tracking. VariantAnnotatorEngine has a special group None that doesn't add any annotations; useful for those who are testing UG performance

git-svn-id: file:///humgen/gsa-scr1/gsa-engineering/svn_contents/trunk@4202 348d0f76-0448-11de-a6fe-93d51630548a
This commit is contained in:
depristo 2010-09-03 12:52:33 +00:00
parent b59d62927e
commit 73d41bfa24
2 changed files with 25 additions and 16 deletions

View File

@ -98,6 +98,7 @@ public class VariantAnnotatorEngine {
HashSet<Class> classes = new HashSet<Class>(); HashSet<Class> classes = new HashSet<Class>();
// get the classes from the provided groups (interfaces) // get the classes from the provided groups (interfaces)
if ( annotationGroupsToUse.size() != 1 || ! annotationGroupsToUse.get(0).toLowerCase().equals("none") ) {
for ( String group : annotationGroupsToUse ) { for ( String group : annotationGroupsToUse ) {
Class interfaceClass = classMap.get(group); Class interfaceClass = classMap.get(group);
if ( interfaceClass == null ) if ( interfaceClass == null )
@ -115,6 +116,7 @@ public class VariantAnnotatorEngine {
throw new StingException("Class " + annotation + " is not found; please check that you have specified the class name correctly"); throw new StingException("Class " + annotation + " is not found; please check that you have specified the class name correctly");
classes.add(annotationClass); classes.add(annotationClass);
} }
}
// get the instances // get the instances
requestedInfoAnnotations = new ArrayList<InfoFieldAnnotation>(); requestedInfoAnnotations = new ArrayList<InfoFieldAnnotation>();

View File

@ -1,16 +1,23 @@
package org.broadinstitute.sting.gatk.walkers.qc; package org.broadinstitute.sting.gatk.walkers.qc;
import net.sf.samtools.SAMFileWriter;
import org.broadinstitute.sting.commandline.Output;
import org.broadinstitute.sting.gatk.contexts.AlignmentContext; import org.broadinstitute.sting.gatk.contexts.AlignmentContext;
import org.broadinstitute.sting.gatk.contexts.ReferenceContext; import org.broadinstitute.sting.gatk.contexts.ReferenceContext;
import org.broadinstitute.sting.gatk.refdata.RefMetaDataTracker; import org.broadinstitute.sting.gatk.refdata.RefMetaDataTracker;
import org.broadinstitute.sting.gatk.walkers.LocusWalker; import org.broadinstitute.sting.gatk.walkers.LocusWalker;
import org.broadinstitute.sting.gatk.walkers.TreeReducible; import org.broadinstitute.sting.gatk.walkers.TreeReducible;
import java.io.PrintStream;
/** /**
* Walks over the input data set, calculating the total number of covered loci for diagnostic purposes. * Walks over the input data set, calculating the total number of covered loci for diagnostic purposes.
* Simplest example of a locus walker. * Simplest example of a locus walker.
*/ */
public class CountLociWalker extends LocusWalker<Integer, Long> implements TreeReducible<Long> { public class CountLociWalker extends LocusWalker<Integer, Long> implements TreeReducible<Long> {
@Output(doc="Write count to this file instead of STDOUT")
PrintStream out;
public Integer map(RefMetaDataTracker tracker, ReferenceContext ref, AlignmentContext context) { public Integer map(RefMetaDataTracker tracker, ReferenceContext ref, AlignmentContext context) {
return 1; return 1;
} }