# HG changeset patch
# User artbio
# Date 1591698219 14400
# Node ID f55d45b0c6d1fb100fc4fddf401b1a7296f56b12
# Parent d09254e37c68fd4065c9ab0c7f01367c3f39d251
"planemo upload for repository https://github.com/ARTbio/tools-artbio/tree/master/tools/manta commit 86427647db100383faa432008b58e768b56ac416"
diff -r d09254e37c68 -r f55d45b0c6d1 customConfigManta.py
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/customConfigManta.py Tue Jun 09 06:23:39 2020 -0400
@@ -0,0 +1,80 @@
+import argparse
+
+
+def Parser():
+ the_parser = argparse.ArgumentParser()
+ the_parser.add_argument(
+ '--minCandidateVariantSize', type=int, default=8,
+ help="Run Manta reporting for all SVs/indels at or above this size")
+ the_parser.add_argument(
+ '--rnaMinCandidateVariantSize', type=int, default=1000,
+ help="Separate option (to provide different default) used for \
+ runs in RNA-mode")
+ the_parser.add_argument(
+ '--minEdgeObservations', type=int, default=3,
+ help="Remove all edges from the graph unless they're supported \
+ by this many 'observations'")
+ the_parser.add_argument(
+ '--graphNodeMaxEdgeCount', type=int, default=10,
+ help="If both nodes of an edge have an edge count higher than this, \
+ then skip evaluation of the edge")
+ the_parser.add_argument(
+ '--minCandidateSpanningCount', type=int, default=3,
+ help="Run discovery and candidate reporting for all SVs/indels with \
+ at least this many spanning support observations")
+ the_parser.add_argument(
+ '--minScoredVariantSize', type=int, default=50,
+ help="After candidate identification, only score and report \
+ SVs/indels at or above this size")
+ the_parser.add_argument(
+ '--minDiploidVariantScore', type=int, default=10,
+ help="minimum VCF QUAL score for a variant to be included in \
+ the diploid vcf")
+ the_parser.add_argument(
+ '--minPassDiploidVariantScore', type=int, default=20,
+ help="VCF QUAL score below which a variant is marked as \
+ filtered in the diploid vcf")
+ the_parser.add_argument(
+ '--minPassDiploidGTScore', type=int, default=15,
+ help="minimum genotype quality score below which single samples \
+ are filtered for a variant in the diploid vcf")
+ the_parser.add_argument(
+ '--minSomaticScore', type=int, default=10,
+ help="minimum VCF QUAL score for a variant to be included in the \
+ diploid vcf")
+ the_parser.add_argument(
+ '--minPassSomaticScore', type=int, default=30,
+ help="somatic quality scores below this level are filtered in the \
+ somatic vcf")
+ the_parser.add_argument(
+ '--enableRemoteReadRetrievalForInsertionsInGermlineCallingModes',
+ type=int, default=1,
+ help="includes tumor-normal subtraction and tumor-only calling")
+ the_parser.add_argument(
+ '--enableRemoteReadRetrievalForInsertionsInCancerCallingModes',
+ type=int, default=0,
+ help="GermlineCallingModes includes all other calling modes")
+ the_parser.add_argument(
+ '--useOverlapPairEvidence', type=int, default=0,
+ help="Set 1 if an overlapping read pair will be considered as \
+ evidence. Set to 0 to skip overlapping read pairs")
+ args = the_parser.parse_args()
+ return args
+
+
+if __name__ == "__main__":
+ args = Parser()
+ # recover arguments as a dictionary with keys = argument name and values
+ # are argument values
+ argsDict = args.__dict__
+ ini_lines = []
+ # implement first, hard-coded ini lines
+ ini_lines.append('[manta]')
+ ini_lines.append('referenceFasta = /dummy/path/to/genome.fa')
+ # implement the rest of the ini lines for the argsDict
+ for argument in argsDict:
+ ini_lines.append("%s = %s" % (argument, str(argsDict[argument])))
+ # print ini_lines in configManta.py.ini
+ handler = open('configManta.py.ini', 'w')
+ for line in ini_lines:
+ handler.write("%s\n" % line)
diff -r d09254e37c68 -r f55d45b0c6d1 customized.ini
--- a/customized.ini Mon Jun 08 03:11:56 2020 -0400
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,58 +0,0 @@
-
-#
-# This section contains all configuration settings for the top-level manta workflow,
-#
-[manta]
-
-referenceFasta = /illumina/development/Isis/Genomes/Homo_sapiens/UCSC/hg19/Sequence/WholeGenomeFasta/genome.fa
-
-# Run discovery and candidate reporting for all SVs/indels at or above this size
-# Separate option (to provide different default) used for runs in RNA-mode
-minCandidateVariantSize = 8
-rnaMinCandidateVariantSize = 1000
-
-# Remove all edges from the graph unless they're supported by this many 'observations'.
-# Note that one supporting read pair or split read usually equals one observation, but evidence is sometimes downweighted.
-minEdgeObservations = 3
-
-# If both nodes of an edge have an edge count higher than this, then skip evaluation of the edge.
-# Set to 0 to turn this filtration off
-graphNodeMaxEdgeCount = 10
-
-# Run discovery and candidate reporting for all SVs/indels with at least this
-# many spanning support observations
-minCandidateSpanningCount = 3
-
-# After candidate identification, only score and report SVs/indels at or above this size:
-minScoredVariantSize = 50
-
-# minimum VCF "QUAL" score for a variant to be included in the diploid vcf:
-minDiploidVariantScore = 10
-
-# VCF "QUAL" score below which a variant is marked as filtered in the diploid vcf:
-minPassDiploidVariantScore = 20
-
-# minimum genotype quality score below which single samples are filtered for a variant in the diploid vcf:
-minPassDiploidGTScore = 15
-
-# somatic quality scores below this level are not included in the somatic vcf:
-minSomaticScore = 10
-
-# somatic quality scores below this level are filtered in the somatic vcf:
-minPassSomaticScore = 30
-
-# Remote read retrieval is used ot improve the assembly of putative insertions by retrieving any mate reads in remote
-# locations with poor mapping quality, which pair to confidently mapping reads near the insertion locus. These reads
-# can help to fully assemble longer insertions, under certain circumstances this feature can add a very large runtime
-# burden. For instance, given the very high chimeric pair rates found in degraded FFPE samples, the runtime of the read
-# retrieval process can be unpredicable. For this reason the feature is disabled by default for somatic variant calling.
-# This feature can be enabled/disabled separately for germline and cancer calling below.
-#
-# Here "CancerCallingModes" includes tumor-normal subtraction and tumor-only calling. "GermlineCallingModes" includes
-# all other calling modes.
-enableRemoteReadRetrievalForInsertionsInGermlineCallingModes = 1
-enableRemoteReadRetrievalForInsertionsInCancerCallingModes = 0
-
-# Set if an overlapping read pair will be considered as evidence
-# Set to 0 to skip overlapping read pairs
-useOverlapPairEvidence = 0
diff -r d09254e37c68 -r f55d45b0c6d1 manta.xml
--- a/manta.xml Mon Jun 08 03:11:56 2020 -0400
+++ b/manta.xml Tue Jun 09 06:23:39 2020 -0400
@@ -24,26 +24,27 @@
ln -s '$bam_input.tumor_bam_file.metadata.bam_index' tumor.bai &&
#end if
- #if str( $set_configuration.set_configuration_switch ) == "Customized":
- sed -i 's/minCandidateVariantSize = 8/minCandidateVariantSize = $set_configuration.minCandidateVariantSize/' ./configManta.py.ini &&
- sed -i 's/rnaMinCandidateVariantSize = 1000/rnaMinCandidateVariantSize = $set_configuration.rnaMinCandidateVariantSize/' ./configManta.py.ini &&
- sed -i 's/minEdgeObservations = 3/minEdgeObservations = $set_configuration.minEdgeObservations/' ./configManta.py.ini &&
- sed -i 's/graphNodeMaxEdgeCount = 10/graphNodeMaxEdgeCount = $set_configuration.graphNodeMaxEdgeCount/' ./configManta.py.ini &&
- sed -i 's/minCandidateSpanningCount = 3/minCandidateSpanningCount = $set_configuration.minCandidateSpanningCount/' ./configManta.py.ini &&
- sed -i 's/minScoredVariantSize = 50/minScoredVariantSize = $set_configuration.minScoredVariantSize/' ./configManta.py.ini &&
- sed -i 's/minDiploidVariantScore = 10/minDiploidVariantScore = $set_configuration.minDiploidVariantScore/' ./configManta.py.ini &&
- sed -i 's/minPassDiploidVariantScore = 20/minPassDiploidVariantScore = $set_configuration.minPassDiploidVariantScore/' ./configManta.py.ini &&
- sed -i 's/minPassDiploidGTScore = 15/minPassDiploidGTScore = $set_configuration.minPassDiploidGTScore/' ./configManta.py.ini &&
- sed -i 's/minSomaticScore = 10/minSomaticScore = $set_configuration.minSomaticScore/' ./configManta.py.ini &&
- sed -i 's/minPassSomaticScore = 30/minPassSomaticScore = $set_configuration.minPassSomaticScore/' ./configManta.py.ini &&
- sed -i 's/enableRemoteReadRetrievalForInsertionsInGermlineCallingModes = 1/enableRemoteReadRetrievalForInsertionsInGermlineCallingModes = $set_configuration.enableRemoteReadRetrievalForInsertionsInGermlineCallingModes/' ./configManta.py.ini &&
- sed -i 's/enableRemoteReadRetrievalForInsertionsInCancerCallingModes = 0/enableRemoteReadRetrievalForInsertionsInCancerCallingModes = $set_configuration.enableRemoteReadRetrievalForInsertionsInCancerCallingModes/' ./configManta.py.ini &&
- sed -i 's/useOverlapPairEvidence = 0/useOverlapPairEvidence = $set_configuration.useOverlapPairEvidence/' ./configManta.py.ini &&
- #end if
-
#if str( $set_configuration.set_configuration_switch ) == "Custom_config_file":
cp '$set_configuration.CustomConfigFile' ./configManta.py.ini &&
#end if
+ #if str( $set_configuration.set_configuration_switch ) == "Customized":
+ rm ./configManta.py.ini &&
+ python $__tool_directory__/customConfigManta.py
+ --minCandidateVariantSize '$set_configuration.minCandidateVariantSize'
+ --rnaMinCandidateVariantSize '$set_configuration.rnaMinCandidateVariantSize'
+ --minEdgeObservations '$set_configuration.minEdgeObservations'
+ --graphNodeMaxEdgeCount '$set_configuration.graphNodeMaxEdgeCount'
+ --minCandidateSpanningCount '$set_configuration.minCandidateSpanningCount'
+ --minScoredVariantSize '$set_configuration.minScoredVariantSize'
+ --minDiploidVariantScore '$set_configuration.minDiploidVariantScore'
+ --minPassDiploidVariantScore '$set_configuration.minPassDiploidVariantScore'
+ --minPassDiploidGTScore '$set_configuration.minPassDiploidGTScore'
+ --minSomaticScore '$set_configuration.minSomaticScore'
+ --minPassSomaticScore '$set_configuration.minPassSomaticScore'
+ --enableRemoteReadRetrievalForInsertionsInGermlineCallingModes '$set_configuration.enableRemoteReadRetrievalForInsertionsInGermlineCallingModes'
+ --enableRemoteReadRetrievalForInsertionsInCancerCallingModes '$set_configuration.enableRemoteReadRetrievalForInsertionsInCancerCallingModes'
+ --useOverlapPairEvidence '$set_configuration.useOverlapPairEvidence' &&
+ #end if
configManta.py --referenceFasta='${reference_fasta_filename}'
--config='./configManta.py.ini'
@@ -53,51 +54,39 @@
--bam='normal.bam'
--tumorBam='tumor.bam'
#end if
- --runDir='${run_dir}'
- --scanSizeMb=${advanced.scanSizeMb}
- --callMemMb=${advanced.callMemMb} &&
+ --runDir='${run_dir}'
+ --scanSizeMb=${advanced.scanSizeMb}
+ --callMemMb=${advanced.callMemMb} &&
- ln -s -f '${run_dir}/runWorkflow.py' '${run_manta_workflow}' &&
- ln -s -f './configManta.py.ini' '${set_conf_file}' &&
python2 '${run_dir}/runWorkflow.py' -m local -j \${GALAXY_SLOTS:-4}
]]>
-
-
+
-
-
-
-
-
-
-
-
-
@@ -126,42 +115,32 @@
-
-
-
-
-
+
+
-
-
-
- runworkflow_file_check == True
-
-
-
+
config_file_check == True
-
+
candidateSV_check == True
-
+
candidateSmallIndels_check == True
-
+
diploidSV_check == True
-
- somaticSV_check == True
+
+ bam_input['bam_input_selector'] == 'tumor_bam'
-
@@ -172,11 +151,22 @@
-
-
-
+
+
-
+
+
+
+
+
+
+
+
+
+
+
+
+
@@ -185,7 +175,8 @@
-
+
+
@@ -196,7 +187,8 @@
-
+
+
@@ -207,10 +199,10 @@
-
+
+
-
-
+
-
+ ]]>
10.1093/bioinformatics/btv710
-
diff -r d09254e37c68 -r f55d45b0c6d1 manta_macros.xml
--- a/manta_macros.xml Mon Jun 08 03:11:56 2020 -0400
+++ b/manta_macros.xml Tue Jun 09 06:23:39 2020 -0400
@@ -1,7 +1,7 @@
1.6
- @VERSION@+galaxy6
+ @VERSION@+galaxy7