Skip to content

Commit 181ce15

Browse files
committed
Update all VariantAnnotator steps to use DISCVRseq wrapper
1 parent e81073c commit 181ce15

File tree

3 files changed

+6
-30
lines changed

3 files changed

+6
-30
lines changed

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/util/VariantAnnotatorWrapper.java

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
package org.labkey.sequenceanalysis.run.util;
22

33
import org.apache.logging.log4j.Logger;
4-
import org.apache.logging.log4j.LogManager;
54
import org.labkey.api.pipeline.PipelineJobException;
6-
import org.labkey.api.sequenceanalysis.run.AbstractGatkWrapper;
5+
import org.labkey.api.sequenceanalysis.run.AbstractDiscvrSeqWrapper;
76

87
import java.io.File;
98
import java.util.ArrayList;
@@ -12,7 +11,7 @@
1211
/**
1312
* Created by bimber on 8/8/2014.
1413
*/
15-
public class VariantAnnotatorWrapper extends AbstractGatkWrapper
14+
public class VariantAnnotatorWrapper extends AbstractDiscvrSeqWrapper
1615
{
1716
public VariantAnnotatorWrapper(Logger log)
1817
{
@@ -21,20 +20,19 @@ public VariantAnnotatorWrapper(Logger log)
2120

2221
public void execute(File referenceFasta, File inputVcf, File outputVcf, List<String> options) throws PipelineJobException
2322
{
24-
getLogger().info("Running GATK VariantAnnotator");
23+
getLogger().info("Running DiscvrVariantAnnotator");
2524

2625
ensureDictionary(referenceFasta);
2726

2827
List<String> args = new ArrayList<>(getBaseArgs());
29-
args.add("-T");
30-
args.add("VariantAnnotator");
28+
args.add("DiscvrVariantAnnotator");
3129
args.add("-R");
3230
args.add(referenceFasta.getPath());
3331

3432
args.add("-V");
3533
args.add(inputVcf.getPath());
3634

37-
args.add("-o");
35+
args.add("-O");
3836
args.add(outputVcf.getPath());
3937

4038
if (options != null)

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/variant/GenotypeConcordanceStep.java

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -100,16 +100,9 @@ public Output processVariants(File inputVCF, File outputDirectory, ReferenceGeno
100100
options.add("-A");
101101
options.add("GenotypeConcordanceBySite");
102102

103-
options.add("-resource:GT_SOURCE");
103+
options.add("-rg");
104104
options.add(refVCF.getPath());
105105

106-
Integer threads = SequencePipelineService.get().getMaxThreads(getPipelineCtx().getLogger());
107-
if (threads != null)
108-
{
109-
options.add("-nt");
110-
options.add(String.valueOf(Math.min(threads, 8)));
111-
}
112-
113106
if (intervals != null)
114107
{
115108
intervals.forEach(interval -> {

SequenceAnalysis/src/org/labkey/sequenceanalysis/run/variant/VariantAnnotatorStep.java

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -88,13 +88,6 @@ public Output processVariants(File inputVCF, File outputDirectory, ReferenceGeno
8888
options.add("MinorAlleleFrequency");
8989
}
9090

91-
Integer threads = SequencePipelineService.get().getMaxThreads(getPipelineCtx().getLogger());
92-
if (threads != null)
93-
{
94-
options.add("-nt");
95-
options.add(String.valueOf(Math.min(threads, 8)));
96-
}
97-
9891
if (intervals != null)
9992
{
10093
intervals.forEach(interval -> {
@@ -103,14 +96,6 @@ public Output processVariants(File inputVCF, File outputDirectory, ReferenceGeno
10396
});
10497
}
10598

106-
//TODO: allow annotation using fields from another VCF:
107-
/**
108-
-resource:indian "$INDIAN_SUBSET" \
109-
-E indian.AF \
110-
-resource:chinese "$CHINESE_SUBSET" \
111-
-E chinese.AF \
112-
*/
113-
11499
getWrapper().execute(genome.getWorkingFastaFile(), inputVCF, outputVcf, options);
115100
if (!outputVcf.exists())
116101
{

0 commit comments

Comments
 (0)