Merge branch 'master' of ssh://gsa4.broadinstitute.org/humgen/gsa-scr1/gsa-engineering/git/stable
This commit is contained in:
commit
84cd23f891
|
|
@ -274,6 +274,38 @@ public class GenomeAnalysisEngine {
|
||||||
//return result;
|
//return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// TODO -- Let's move this to a utility class in unstable - but which one?
|
||||||
|
// **************************************************************************************
|
||||||
|
// * Handle Deprecated Walkers *
|
||||||
|
// **************************************************************************************
|
||||||
|
|
||||||
|
// Mapping from walker name to major version number where the walker first disappeared
|
||||||
|
private static Map<String, String> deprecatedGATKWalkers = new HashMap<String, String>();
|
||||||
|
static {
|
||||||
|
deprecatedGATKWalkers.put("CountCovariates", "2.0");
|
||||||
|
deprecatedGATKWalkers.put("TableRecalibration", "2.0");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Utility method to check whether a given walker has been deprecated in a previous GATK release
|
||||||
|
*
|
||||||
|
* @param walkerName the walker class name (not the full package) to check
|
||||||
|
*/
|
||||||
|
public static boolean isDeprecatedWalker(final String walkerName) {
|
||||||
|
return deprecatedGATKWalkers.containsKey(walkerName);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Utility method to check whether a given walker has been deprecated in a previous GATK release
|
||||||
|
*
|
||||||
|
* @param walkerName the walker class name (not the full package) to check
|
||||||
|
*/
|
||||||
|
public static String getDeprecatedMajorVersionNumber(final String walkerName) {
|
||||||
|
return deprecatedGATKWalkers.get(walkerName);
|
||||||
|
}
|
||||||
|
|
||||||
|
// **************************************************************************************
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Retrieves an instance of the walker based on the walker name.
|
* Retrieves an instance of the walker based on the walker name.
|
||||||
*
|
*
|
||||||
|
|
@ -287,6 +319,9 @@ public class GenomeAnalysisEngine {
|
||||||
if ( isGATKLite() && GATKLiteUtils.isAvailableOnlyInFullGATK(walkerName) ) {
|
if ( isGATKLite() && GATKLiteUtils.isAvailableOnlyInFullGATK(walkerName) ) {
|
||||||
e = new UserException.NotSupportedInGATKLite("the " + walkerName + " walker is available only in the full version of the GATK");
|
e = new UserException.NotSupportedInGATKLite("the " + walkerName + " walker is available only in the full version of the GATK");
|
||||||
}
|
}
|
||||||
|
else if ( isDeprecatedWalker(walkerName) ) {
|
||||||
|
e = new UserException.DeprecatedWalker(walkerName, getDeprecatedMajorVersionNumber(walkerName));
|
||||||
|
}
|
||||||
throw e;
|
throw e;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -316,9 +316,9 @@ public class UserException extends ReviewedStingException {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public static class MissingWalker extends UserException {
|
public static class DeprecatedWalker extends UserException {
|
||||||
public MissingWalker(String walkerName, String message) {
|
public DeprecatedWalker(String walkerName, String version) {
|
||||||
super(String.format("Walker %s is not available: %s", walkerName, message));
|
super(String.format("Walker %s is no longer available in the GATK; it has been deprecated since version %s", walkerName, version));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -347,6 +347,7 @@ class DataProcessingPipeline extends QScript {
|
||||||
this.knownSites ++= qscript.dbSNP
|
this.knownSites ++= qscript.dbSNP
|
||||||
this.covariate ++= Seq("ReadGroupCovariate", "QualityScoreCovariate", "CycleCovariate", "ContextCovariate")
|
this.covariate ++= Seq("ReadGroupCovariate", "QualityScoreCovariate", "CycleCovariate", "ContextCovariate")
|
||||||
this.input_file :+= inBam
|
this.input_file :+= inBam
|
||||||
|
this.disable_indel_quals = true
|
||||||
this.out = outRecalFile
|
this.out = outRecalFile
|
||||||
if (!defaultPlatform.isEmpty) this.default_platform = defaultPlatform
|
if (!defaultPlatform.isEmpty) this.default_platform = defaultPlatform
|
||||||
if (!qscript.intervalString.isEmpty) this.intervalsString ++= Seq(qscript.intervalString)
|
if (!qscript.intervalString.isEmpty) this.intervalsString ++= Seq(qscript.intervalString)
|
||||||
|
|
@ -359,7 +360,6 @@ class DataProcessingPipeline extends QScript {
|
||||||
case class recal (inBam: File, inRecalFile: File, outBam: File) extends PrintReads with CommandLineGATKArgs {
|
case class recal (inBam: File, inRecalFile: File, outBam: File) extends PrintReads with CommandLineGATKArgs {
|
||||||
this.input_file :+= inBam
|
this.input_file :+= inBam
|
||||||
this.BQSR = inRecalFile
|
this.BQSR = inRecalFile
|
||||||
this.disable_indel_quals = true
|
|
||||||
this.baq = CalculationMode.CALCULATE_AS_NECESSARY
|
this.baq = CalculationMode.CALCULATE_AS_NECESSARY
|
||||||
this.out = outBam
|
this.out = outBam
|
||||||
if (!qscript.intervalString.isEmpty) this.intervalsString ++= Seq(qscript.intervalString)
|
if (!qscript.intervalString.isEmpty) this.intervalsString ++= Seq(qscript.intervalString)
|
||||||
|
|
|
||||||
|
|
@ -166,6 +166,7 @@ class PacbioProcessingPipeline extends QScript {
|
||||||
this.knownSites :+= dbSNP
|
this.knownSites :+= dbSNP
|
||||||
this.covariate ++= List("ReadGroupCovariate", "QualityScoreCovariate", "CycleCovariate", "ContextCovariate")
|
this.covariate ++= List("ReadGroupCovariate", "QualityScoreCovariate", "CycleCovariate", "ContextCovariate")
|
||||||
this.input_file :+= inBam
|
this.input_file :+= inBam
|
||||||
|
this.disable_indel_quals = true
|
||||||
this.out = outRecalFile
|
this.out = outRecalFile
|
||||||
this.analysisName = queueLogDir + outRecalFile + ".covariates"
|
this.analysisName = queueLogDir + outRecalFile + ".covariates"
|
||||||
this.jobName = queueLogDir + outRecalFile + ".covariates"
|
this.jobName = queueLogDir + outRecalFile + ".covariates"
|
||||||
|
|
@ -178,7 +179,6 @@ class PacbioProcessingPipeline extends QScript {
|
||||||
this.input_file :+= inBam
|
this.input_file :+= inBam
|
||||||
this.BQSR = inRecalFile
|
this.BQSR = inRecalFile
|
||||||
this.out = outBam
|
this.out = outBam
|
||||||
this.disable_indel_quals = true
|
|
||||||
this.isIntermediate = false
|
this.isIntermediate = false
|
||||||
this.analysisName = queueLogDir + outBam + ".recalibration"
|
this.analysisName = queueLogDir + outBam + ".recalibration"
|
||||||
this.jobName = queueLogDir + outBam + ".recalibration"
|
this.jobName = queueLogDir + outBam + ".recalibration"
|
||||||
|
|
|
||||||
|
|
@ -41,7 +41,7 @@ class DataProcessingPipelineTest {
|
||||||
" -D " + BaseTest.publicTestDir + "exampleDBSNP.vcf",
|
" -D " + BaseTest.publicTestDir + "exampleDBSNP.vcf",
|
||||||
" -test ",
|
" -test ",
|
||||||
" -p " + projectName).mkString
|
" -p " + projectName).mkString
|
||||||
spec.fileMD5s += testOut -> "0f0b32e94640a8d548b4c1134ad4c075"
|
spec.fileMD5s += testOut -> "021db3a52ee40d9193895213aaa05dd5"
|
||||||
PipelineTest.executeTest(spec)
|
PipelineTest.executeTest(spec)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -60,7 +60,7 @@ class DataProcessingPipelineTest {
|
||||||
" -bwa /home/unix/carneiro/bin/bwa",
|
" -bwa /home/unix/carneiro/bin/bwa",
|
||||||
" -bwape ",
|
" -bwape ",
|
||||||
" -p " + projectName).mkString
|
" -p " + projectName).mkString
|
||||||
spec.fileMD5s += testOut -> "6b4f13d22b45d7d617ee959fdc278ed2"
|
spec.fileMD5s += testOut -> "94e32ee974aa15d05ee7d3e99f2f8c8f"
|
||||||
PipelineTest.executeTest(spec)
|
PipelineTest.executeTest(spec)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -40,7 +40,7 @@ class PacbioProcessingPipelineTest {
|
||||||
" -blasr ",
|
" -blasr ",
|
||||||
" -test ",
|
" -test ",
|
||||||
" -D " + BaseTest.publicTestDir + "exampleDBSNP.vcf").mkString
|
" -D " + BaseTest.publicTestDir + "exampleDBSNP.vcf").mkString
|
||||||
spec.fileMD5s += testOut -> "2f2026882a2850bb14a858524158d5a8"
|
spec.fileMD5s += testOut -> "8b5f9e8e1ba5bd686e3084eaeea23889"
|
||||||
PipelineTest.executeTest(spec)
|
PipelineTest.executeTest(spec)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue