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:
parent
b59d62927e
commit
73d41bfa24
|
|
@ -98,22 +98,24 @@ public class VariantAnnotatorEngine {
|
|||
|
||||
HashSet<Class> classes = new HashSet<Class>();
|
||||
// get the classes from the provided groups (interfaces)
|
||||
for ( String group : annotationGroupsToUse ) {
|
||||
Class interfaceClass = classMap.get(group);
|
||||
if ( interfaceClass == null )
|
||||
interfaceClass = classMap.get(group + "Annotation");
|
||||
if ( interfaceClass == null )
|
||||
throw new StingException("Class " + group + " is not found; please check that you have specified the class name correctly");
|
||||
classes.addAll(PackageUtils.getClassesImplementingInterface(interfaceClass));
|
||||
}
|
||||
// get the specific classes provided
|
||||
for ( String annotation : annotationsToUse ) {
|
||||
Class annotationClass = classMap.get(annotation);
|
||||
if ( annotationClass == null )
|
||||
annotationClass = classMap.get(annotation + "Annotation");
|
||||
if ( annotationClass == null )
|
||||
throw new StingException("Class " + annotation + " is not found; please check that you have specified the class name correctly");
|
||||
classes.add(annotationClass);
|
||||
if ( annotationGroupsToUse.size() != 1 || ! annotationGroupsToUse.get(0).toLowerCase().equals("none") ) {
|
||||
for ( String group : annotationGroupsToUse ) {
|
||||
Class interfaceClass = classMap.get(group);
|
||||
if ( interfaceClass == null )
|
||||
interfaceClass = classMap.get(group + "Annotation");
|
||||
if ( interfaceClass == null )
|
||||
throw new StingException("Class " + group + " is not found; please check that you have specified the class name correctly");
|
||||
classes.addAll(PackageUtils.getClassesImplementingInterface(interfaceClass));
|
||||
}
|
||||
// get the specific classes provided
|
||||
for ( String annotation : annotationsToUse ) {
|
||||
Class annotationClass = classMap.get(annotation);
|
||||
if ( annotationClass == null )
|
||||
annotationClass = classMap.get(annotation + "Annotation");
|
||||
if ( annotationClass == null )
|
||||
throw new StingException("Class " + annotation + " is not found; please check that you have specified the class name correctly");
|
||||
classes.add(annotationClass);
|
||||
}
|
||||
}
|
||||
|
||||
// get the instances
|
||||
|
|
|
|||
|
|
@ -1,16 +1,23 @@
|
|||
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.ReferenceContext;
|
||||
import org.broadinstitute.sting.gatk.refdata.RefMetaDataTracker;
|
||||
import org.broadinstitute.sting.gatk.walkers.LocusWalker;
|
||||
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.
|
||||
* Simplest example of a locus walker.
|
||||
*/
|
||||
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) {
|
||||
return 1;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue