changeset 1:6ade12d94f9a draft

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tool_collections/samtools/samtools_view commit c7bb87a32997810fd9f28572fc5af628c8c4ffa3
author iuc
date Tue, 25 Sep 2018 04:21:24 -0400
parents 00d1f08bdcdc
children 02afb5ea2fce
files macros.xml samtools_view.xml
diffstat 2 files changed, 18 insertions(+), 10 deletions(-) [+]
line wrap: on
line diff
--- a/macros.xml	Wed Sep 19 08:21:51 2018 -0400
+++ b/macros.xml	Tue Sep 25 04:21:24 2018 -0400
@@ -67,6 +67,13 @@
         ##compute the number of ADDITIONAL threads to be used by samtools (-@)
         addthreads=\${GALAXY_SLOTS:-1} && (( addthreads-- )) &&
     ]]></token>
+
+    <token name="@ADDMEMORY@"><![CDATA[
+        ##compute the number of memory available to samtools sort (-m)
+        ##use only 75% of available: https://github.com/samtools/samtools/issues/831
+        addmemory=\${GALAXY_MEMORY_MB_PER_SLOT:-768} && 
+        ((addmemory=addmemory*75/100)) &&
+    ]]></token>
     <xml name="flag_options">
         <option value="1">read is paired</option>
         <option value="2">read is mapped in a proper pair</option>
--- a/samtools_view.xml	Wed Sep 19 08:21:51 2018 -0400
+++ b/samtools_view.xml	Tue Sep 25 04:21:24 2018 -0400
@@ -83,7 +83,10 @@
         #if $reffa!=None:
             -T '$reffa'
             -t '$reffai'
-        #else:
+        #end if
+
+        ##currently reference based CRAM is disabled (see https://github.com/galaxyproject/tools-iuc/pull/1963)
+        #if $outtype=='cram':
             --output-fmt-option no_ref
         #end if
 
@@ -189,10 +192,10 @@
         </conditional>
         <conditional name="addref_cond">
             <param name="addref_select" type="select" label="Reference data">
-		    <help>Reference data as fasta(.gz). Required for SAM input without @SQ headers and useful/required for writing CRAM output (see help).</help>
+                <help>Reference data as fasta(.gz). Required for SAM input without @SQ headers and useful/required for writing CRAM output (see help).</help>
                 <option value="no" selected="True">No, see help (-output-fmt-option no_ref)</option>
-		<option value="history">Use a genome/index from the history (-t/-T)</option>
-		<option value="cached">Use a built-in genome (-t/-T)</option>
+                <option value="history">Use a genome/index from the history (-t/-T)</option>
+                <option value="cached">Use a built-in genome (-t/-T)</option>
             </param>
             <when value="no"/>
             <when value="history">
@@ -398,14 +401,12 @@
 .. class:: infomark 
 
 samtools view allows to specify a reference sequence. This is required for SAM input with missing @SQ headers (which include sequence names, length, md5, etc) and useful (and sometimes necessary) for CRAM input and output. In the following the use of reference sequence in the CRAM format is detailed. 
-CRAM is (primarily) a reference-based compressed format, i.e. only differences between the stored sequences and the reference are stored. As a consequence the reference that was used to generate the alignemnts is always needed in order to interpret the alignments (a checksum stored in the CRAM file is used to verify that the only the correct sequence can be used), i.e. the CRAM file on its own is not useful per default. This allows for a more space efficient storage compared to BAM. But it is also possible to use CRAM without a reference with the disadvantage that the reference is stored explicitely (as in SAM and BAM). 
-
-The Galaxy tool allows both possibilities using the "reference data" option:
+CRAM is (intended as a primarily) a reference-based compressed format, i.e. only differences between the stored sequences and the reference are stored. As a consequence the reference that was used to generate the alignemnts is always needed in order to interpret the alignments (a checksum stored in the CRAM file is used to verify that the only the correct sequence can be used), i.e. the CRAM file on its own is not useful per default. This allows for a more space efficient storage compared to BAM. 
+But it is also possible to use CRAM without a reference with the disadvantage that the reference is stored explicitely (as in SAM and BAM). 
 
-- the default ("no reference") 
-- reference data can be chosen from history or built in genomes can be used
+The Galaxy tool **currently generates only CRAM without reference sequence**.
 
-The reference data required for reading/writing reference based CRAM.
+For reference based CRAM input the correct refernce sequence needs to be specified.
 
 **Filtering alignments**