comparison GNPSExport.xml @ 5:87a970d1514b draft default tip

planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit 5c080b1e2b99f1c88f4557e9fec8c45c9d23b906
author galaxyp
date Fri, 14 Jun 2024 21:33:13 +0000
parents 2da14ae3844a
children
comparison
equal deleted inserted replaced
4:2da14ae3844a 5:87a970d1514b
1 <?xml version='1.0' encoding='UTF-8'?>
2 <!--This is a configuration file for the integration of a tools into Galaxy (https://galaxyproject.org/). This file was automatically generated using CTDConverter.--> 1 <!--This is a configuration file for the integration of a tools into Galaxy (https://galaxyproject.org/). This file was automatically generated using CTDConverter.-->
3 <!--Proposed Tool Section: [File Handling]--> 2 <!--Proposed Tool Section: [File Converter]-->
4 <tool id="GNPSExport" name="GNPSExport" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="21.05"> 3 <tool id="GNPSExport" name="GNPSExport" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="21.05">
5 <description>Tool to export representative consensus MS/MS scan per consensusElement into a .MGF file format. 4 <description>Tool to export representative consensus MS/MS scan per consensusElement into a .MGF file format</description>
6 See the documentation on https://ccms-ucsd.github.io/GNPSDocumentation/featurebasedmolecularnetworking-with-openms</description>
7 <macros> 5 <macros>
8 <token name="@EXECUTABLE@">GNPSExport</token> 6 <token name="@EXECUTABLE@">GNPSExport</token>
9 <import>macros.xml</import> 7 <import>macros.xml</import>
10 </macros> 8 </macros>
11 <expand macro="requirements"/> 9 <expand macro="requirements"/>
14 @EXT_FOO@ 12 @EXT_FOO@
15 #import re 13 #import re
16 14
17 ## Preprocessing 15 ## Preprocessing
18 mkdir in_cm && 16 mkdir in_cm &&
19 ln -s '$in_cm' 'in_cm/${re.sub("[^\w\-_]", "_", $in_cm.element_identifier)}.$gxy2omsext($in_cm.ext)' && 17 cp '$in_cm' 'in_cm/${re.sub("[^\w\-_]", "_", $in_cm.element_identifier)}.$gxy2omsext($in_cm.ext)' &&
20 mkdir in_mzml_cond.in_mzml && 18 mkdir in_mzml_cond.in_mzml &&
21 #if $in_mzml_cond.in_mzml_select == "no" 19 #if $in_mzml_cond.in_mzml_select == "no"
22 mkdir ${' '.join(["'in_mzml_cond.in_mzml/%s'" % (i) for i, f in enumerate($in_mzml_cond.in_mzml) if f])} && 20 mkdir ${' '.join(["'in_mzml_cond.in_mzml/%s'" % (i) for i, f in enumerate($in_mzml_cond.in_mzml) if f])} &&
23 ${' '.join(["ln -s '%s' 'in_mzml_cond.in_mzml/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($in_mzml_cond.in_mzml) if f])} 21 ${' '.join(["cp '%s' 'in_mzml_cond.in_mzml/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($in_mzml_cond.in_mzml) if f])}
24 #else 22 #else
25 ln -s '$in_mzml_cond.in_mzml' 'in_mzml_cond.in_mzml/${re.sub("[^\w\-_]", "_", $in_mzml_cond.in_mzml.element_identifier)}.$gxy2omsext($in_mzml_cond.in_mzml.ext)' && 23 cp '$in_mzml_cond.in_mzml' 'in_mzml_cond.in_mzml/${re.sub("[^\w\-_]", "_", $in_mzml_cond.in_mzml.element_identifier)}.$gxy2omsext($in_mzml_cond.in_mzml.ext)' &&
26 #end if 24 #end if
27 mkdir out && 25 mkdir out &&
26 mkdir out_quantification &&
27 #if "out_pairs_FLAG" in str($OPTIONAL_OUTPUTS).split(',')
28 mkdir out_pairs &&
29 #end if
30 #if "out_meta_values_FLAG" in str($OPTIONAL_OUTPUTS).split(',')
31 mkdir out_meta_values &&
32 #end if
28 33
29 ## Main program call 34 ## Main program call
30 35
31 set -o pipefail && 36 set -o pipefail &&
32 @EXECUTABLE@ -write_ctd ./ && 37 @EXECUTABLE@ -write_ctd ./ &&
40 #else 45 #else
41 'in_mzml_cond.in_mzml/${re.sub("[^\w\-_]", "_", $in_mzml_cond.in_mzml.element_identifier)}.$gxy2omsext($in_mzml_cond.in_mzml.ext)' 46 'in_mzml_cond.in_mzml/${re.sub("[^\w\-_]", "_", $in_mzml_cond.in_mzml.element_identifier)}.$gxy2omsext($in_mzml_cond.in_mzml.ext)'
42 #end if 47 #end if
43 -out 48 -out
44 'out/output.${gxy2omsext("mgf")}' 49 'out/output.${gxy2omsext("mgf")}'
50 -out_quantification
51 'out_quantification/output.${gxy2omsext("txt")}'
52 #if "out_pairs_FLAG" in str($OPTIONAL_OUTPUTS).split(',')
53 -out_pairs
54 'out_pairs/output.${gxy2omsext("csv")}'
55 #end if
56 #if "out_meta_values_FLAG" in str($OPTIONAL_OUTPUTS).split(',')
57 -out_meta_values
58 'out_meta_values/output.${gxy2omsext("tabular")}'
59 #end if
60 #if len(str($OPTIONAL_OUTPUTS).split(',')) == 0
61 | tee '$stdout'
62 #end if
45 63
46 ## Postprocessing 64 ## Postprocessing
47 && mv 'out/output.${gxy2omsext("mgf")}' '$out' 65 && mv 'out/output.${gxy2omsext("mgf")}' '$out'
66 && mv 'out_quantification/output.${gxy2omsext("txt")}' '$out_quantification'
67 #if "out_pairs_FLAG" in str($OPTIONAL_OUTPUTS).split(',')
68 && mv 'out_pairs/output.${gxy2omsext("csv")}' '$out_pairs'
69 #end if
70 #if "out_meta_values_FLAG" in str($OPTIONAL_OUTPUTS).split(',')
71 && mv 'out_meta_values/output.${gxy2omsext("tabular")}' '$out_meta_values'
72 #end if
48 #if "ctd_out_FLAG" in $OPTIONAL_OUTPUTS 73 #if "ctd_out_FLAG" in $OPTIONAL_OUTPUTS
49 && mv '@EXECUTABLE@.ctd' '$ctd_out' 74 && mv '@EXECUTABLE@.ctd' '$ctd_out'
50 #end if]]></command> 75 #end if]]></command>
51 <configfiles> 76 <configfiles>
52 <inputs name="args_json" data_style="paths"/> 77 <inputs name="args_json" data_style="paths"/>
53 <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile> 78 <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile>
54 </configfiles> 79 </configfiles>
55 <inputs> 80 <inputs>
56 <param argument="-in_cm" type="data" format="consensusxml" optional="false" label="Input consensusXML file containing only consensusElements with &quot;peptide&quot; annotations" help=" select consensusxml data sets(s)"/> 81 <param argument="-in_cm" type="data" format="consensusxml" label="Input consensusXML file containing only consensusElements with &quot;peptide&quot; annotations" help=" select consensusxml data sets(s)"/>
57 <conditional name="in_mzml_cond"> 82 <conditional name="in_mzml_cond">
58 <param name="in_mzml_select" type="select" label="Run tool in batch mode for -in_mzml"> 83 <param name="in_mzml_select" type="select" label="Run tool in batch mode for -in_mzml">
59 <option value="no">No: process all datasets jointly</option> 84 <option value="no">No: process all datasets jointly</option>
60 <option value="yes">Yes: process each dataset in an independent job</option> 85 <option value="yes">Yes: process each dataset in an independent job</option>
61 </param> 86 </param>
62 <when value="no"> 87 <when value="no">
63 <param argument="-in_mzml" type="data" format="mzml" multiple="true" optional="false" label="Original mzml files containing the ms2 spectra (aka peptide annotation)" help="Must be in order that the consensusXML file maps the original mzML files select mzml data sets(s)"/> 88 <param argument="-in_mzml" type="data" format="mzml" multiple="true" label="Original mzml files containing the ms2 spectra (aka peptide annotation)" help="Must be in order that the consensusXML file maps the original mzML files select mzml data sets(s)"/>
64 </when> 89 </when>
65 <when value="yes"> 90 <when value="yes">
66 <param argument="-in_mzml" type="data" format="mzml" multiple="false" optional="false" label="Original mzml files containing the ms2 spectra (aka peptide annotation)" help="Must be in order that the consensusXML file maps the original mzML files select mzml data sets(s)"/> 91 <param argument="-in_mzml" type="data" format="mzml" label="Original mzml files containing the ms2 spectra (aka peptide annotation)" help="Must be in order that the consensusXML file maps the original mzML files select mzml data sets(s)"/>
67 </when> 92 </when>
68 </conditional> 93 </conditional>
69 <param argument="-output_type" type="select" optional="true" label="specificity of mgf output information" help=""> 94 <param argument="-output_type" type="select" label="specificity of mgf output information" help="">
70 <option value="merged_spectra">merged_spectra</option> 95 <option value="merged_spectra">merged_spectra</option>
71 <option value="most_intense" selected="true">most_intense</option> 96 <option value="most_intense" selected="true">most_intense</option>
72 <expand macro="list_string_san" name="output_type"/> 97 <expand macro="list_string_san" name="output_type"/>
73 </param> 98 </param>
74 <param argument="-peptide_cutoff" type="integer" optional="true" min="-1" value="5" label="Number of most intense peptides to consider per consensus element; '-1' to consider all identifications" help=""/> 99 <param argument="-peptide_cutoff" type="integer" min="-1" value="5" label="Number of most intense peptides to consider per consensus element; '-1' to consider all identifications" help=""/>
75 <param argument="-ms2_bin_size" type="float" optional="true" min="0.0" value="0.019999999552965" label="Bin size (Da) for fragment ions when merging ms2 scans" help=""/> 100 <param argument="-ms2_bin_size" type="float" min="0.0" value="0.019999999552965" label="Bin size (Da) for fragment ions when merging ms2 scans" help=""/>
76 <section name="merged_spectra" title="Options for exporting mgf file with merged spectra per consensusElement" help="" expanded="false"> 101 <section name="merged_spectra" title="Options for exporting mgf file with merged spectra per consensusElement" help="" expanded="false">
77 <param name="cos_similarity" argument="-merged_spectra:cos_similarity" type="float" optional="true" min="0.0" value="0.9" label="Cosine similarity threshold for merged_spectra output" help=""/> 102 <param name="cos_similarity" argument="-merged_spectra:cos_similarity" type="float" min="0.0" value="0.9" label="Cosine similarity threshold for merged_spectra output" help=""/>
78 </section> 103 </section>
79 <expand macro="adv_opts_macro"> 104 <expand macro="adv_opts_macro">
80 <param argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overrides tool-specific checks" help=""/> 105 <param argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overrides tool-specific checks" help=""/>
81 <param argument="-test" type="hidden" optional="true" value="False" label="Enables the test mode (needed for internal use only)" help=""> 106 <param argument="-test" type="hidden" value="False" label="Enables the test mode (needed for internal use only)" help="" optional="true">
82 <expand macro="list_string_san" name="test"/> 107 <expand macro="list_string_san" name="test"/>
83 </param> 108 </param>
84 </expand> 109 </expand>
85 <param name="OPTIONAL_OUTPUTS" type="select" optional="true" multiple="true" label="Optional outputs"> 110 <param name="OPTIONAL_OUTPUTS" type="select" optional="true" multiple="true" label="Optional outputs">
111 <option value="out_pairs_FLAG">out_pairs (Output supplementary pairs table for IIMN)</option>
112 <option value="out_meta_values_FLAG">out_meta_values (Output meta value file)</option>
86 <option value="ctd_out_FLAG">Output used ctd (ini) configuration file</option> 113 <option value="ctd_out_FLAG">Output used ctd (ini) configuration file</option>
87 </param> 114 </param>
88 </inputs> 115 </inputs>
89 <outputs> 116 <outputs>
90 <data name="out" label="${tool.name} on ${on_string}: out" format="mgf"/> 117 <data name="out" label="${tool.name} on ${on_string}: out" format="mgf"/>
118 <data name="out_quantification" label="${tool.name} on ${on_string}: out_quantification" format="txt"/>
119 <data name="out_pairs" label="${tool.name} on ${on_string}: out_pairs" format="csv">
120 <filter>OPTIONAL_OUTPUTS is not None and "out_pairs_FLAG" in OPTIONAL_OUTPUTS</filter>
121 </data>
122 <data name="out_meta_values" label="${tool.name} on ${on_string}: out_meta_values" format="tabular">
123 <filter>OPTIONAL_OUTPUTS is not None and "out_meta_values_FLAG" in OPTIONAL_OUTPUTS</filter>
124 </data>
91 <data name="ctd_out" format="xml" label="${tool.name} on ${on_string}: ctd"> 125 <data name="ctd_out" format="xml" label="${tool.name} on ${on_string}: ctd">
92 <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter> 126 <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter>
93 </data> 127 </data>
94 </outputs> 128 </outputs>
95 <tests><!-- TOPP_GNPSExport_1 --> 129 <tests>
96 <test expect_num_outputs="2"> 130 <!-- TOPP_GNPSExport_1 -->
131 <test expect_num_outputs="3">
97 <section name="adv_opts"> 132 <section name="adv_opts">
98 <param name="force" value="false"/> 133 <param name="force" value="false"/>
99 <param name="test" value="true"/> 134 <param name="test" value="true"/>
100 </section> 135 </section>
101 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/> 136 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/>
102 <conditional name="in_mzml_cond"> 137 <conditional name="in_mzml_cond">
103 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/> 138 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/>
104 </conditional> 139 </conditional>
105 <output name="out" file="GNPSExport_1_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/> 140 <output name="out" value="GNPSExport_1_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/>
141 <output name="out_quantification" value="GNPSExport_1_out_quant.txt" compare="sim_size" delta_frac="0.7" ftype="txt"/>
106 <param name="output_type" value="most_intense"/> 142 <param name="output_type" value="most_intense"/>
107 <param name="peptide_cutoff" value="10"/> 143 <param name="peptide_cutoff" value="10"/>
108 <param name="ms2_bin_size" value="2.0"/> 144 <param name="ms2_bin_size" value="2.0"/>
109 <section name="merged_spectra"> 145 <section name="merged_spectra">
110 <param name="cos_similarity" value="0.85"/> 146 <param name="cos_similarity" value="0.85"/>
113 <output name="ctd_out" ftype="xml"> 149 <output name="ctd_out" ftype="xml">
114 <assert_contents> 150 <assert_contents>
115 <is_valid_xml/> 151 <is_valid_xml/>
116 </assert_contents> 152 </assert_contents>
117 </output> 153 </output>
154 <assert_stdout>
155 <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
156 </assert_stdout>
118 </test> 157 </test>
119 <!-- TOPP_GNPSExport_2 --> 158 <!-- TOPP_GNPSExport_2 -->
120 <test expect_num_outputs="2"> 159 <test expect_num_outputs="3">
121 <section name="adv_opts"> 160 <section name="adv_opts">
122 <param name="force" value="false"/> 161 <param name="force" value="false"/>
123 <param name="test" value="true"/> 162 <param name="test" value="true"/>
124 </section> 163 </section>
125 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/> 164 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/>
126 <conditional name="in_mzml_cond"> 165 <conditional name="in_mzml_cond">
127 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/> 166 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/>
128 </conditional> 167 </conditional>
129 <output name="out" file="GNPSExport_2_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/> 168 <output name="out" value="GNPSExport_2_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/>
169 <output name="out_quantification" value="GNPSExport_2_out_quant.tmp" compare="sim_size" delta_frac="0.7" ftype="txt"/>
130 <param name="output_type" value="merged_spectra"/> 170 <param name="output_type" value="merged_spectra"/>
131 <param name="peptide_cutoff" value="10"/> 171 <param name="peptide_cutoff" value="10"/>
132 <param name="ms2_bin_size" value="2.0"/> 172 <param name="ms2_bin_size" value="2.0"/>
133 <section name="merged_spectra"> 173 <section name="merged_spectra">
134 <param name="cos_similarity" value="0.85"/> 174 <param name="cos_similarity" value="0.85"/>
137 <output name="ctd_out" ftype="xml"> 177 <output name="ctd_out" ftype="xml">
138 <assert_contents> 178 <assert_contents>
139 <is_valid_xml/> 179 <is_valid_xml/>
140 </assert_contents> 180 </assert_contents>
141 </output> 181 </output>
182 <assert_stdout>
183 <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
184 </assert_stdout>
142 </test> 185 </test>
143 <!-- TOPP_GNPSExport_3 --> 186 <!-- TOPP_GNPSExport_3 -->
144 <test expect_num_outputs="2"> 187 <test expect_num_outputs="3">
145 <section name="adv_opts"> 188 <section name="adv_opts">
146 <param name="force" value="false"/> 189 <param name="force" value="false"/>
147 <param name="test" value="true"/> 190 <param name="test" value="true"/>
148 </section> 191 </section>
149 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/> 192 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/>
150 <conditional name="in_mzml_cond"> 193 <conditional name="in_mzml_cond">
151 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/> 194 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/>
152 </conditional> 195 </conditional>
153 <output name="out" file="GNPSExport_3_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/> 196 <output name="out" value="GNPSExport_3_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/>
197 <output name="out_quantification" value="GNPSExport_3_out_quant.tmp" compare="sim_size" delta_frac="0.7" ftype="txt"/>
154 <param name="output_type" value="most_intense"/> 198 <param name="output_type" value="most_intense"/>
155 <param name="peptide_cutoff" value="10"/> 199 <param name="peptide_cutoff" value="10"/>
156 <param name="ms2_bin_size" value="0.02"/> 200 <param name="ms2_bin_size" value="0.02"/>
157 <section name="merged_spectra"> 201 <section name="merged_spectra">
158 <param name="cos_similarity" value="0.85"/> 202 <param name="cos_similarity" value="0.85"/>
161 <output name="ctd_out" ftype="xml"> 205 <output name="ctd_out" ftype="xml">
162 <assert_contents> 206 <assert_contents>
163 <is_valid_xml/> 207 <is_valid_xml/>
164 </assert_contents> 208 </assert_contents>
165 </output> 209 </output>
210 <assert_stdout>
211 <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
212 </assert_stdout>
213 </test>
214 <!-- TOPP_GNPSExport_4 -->
215 <test expect_num_outputs="5">
216 <section name="adv_opts">
217 <param name="force" value="false"/>
218 <param name="test" value="true"/>
219 </section>
220 <param name="in_cm" value="GNPSExport_cons2.consensusXML"/>
221 <conditional name="in_mzml_cond">
222 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/>
223 </conditional>
224 <output name="out" value="GNPSExport_4_out.tmp" compare="sim_size" delta_frac="0.7" ftype="mgf"/>
225 <output name="out_quantification" value="GNPSExport_4_out_quant.txt" compare="sim_size" delta_frac="0.7" ftype="txt"/>
226 <output name="out_pairs" value="GNPSExport_4_out_pairs.csv" compare="sim_size" delta_frac="0.7" ftype="csv"/>
227 <output name="out_meta_values" value="GNPSExport_4_out_meta_values.tsv" compare="sim_size" delta_frac="0.7" ftype="tabular"/>
228 <param name="output_type" value="most_intense"/>
229 <param name="peptide_cutoff" value="5"/>
230 <param name="ms2_bin_size" value="0.019999999552965"/>
231 <section name="merged_spectra">
232 <param name="cos_similarity" value="0.9"/>
233 </section>
234 <param name="OPTIONAL_OUTPUTS" value="ctd_out_FLAG,out_pairs_FLAG,out_meta_values_FLAG"/>
235 <output name="ctd_out" ftype="xml">
236 <assert_contents>
237 <is_valid_xml/>
238 </assert_contents>
239 </output>
240 <assert_stdout>
241 <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
242 </assert_stdout>
166 </test> 243 </test>
167 </tests> 244 </tests>
168 <help><![CDATA[Tool to export representative consensus MS/MS scan per consensusElement into a .MGF file format. 245 <help><![CDATA[Tool to export representative consensus MS/MS scan per consensusElement into a .MGF file format.
169 See the documentation on https://ccms-ucsd.github.io/GNPSDocumentation/featurebasedmolecularnetworking-with-openms 246 See the documentation on https://ccms-ucsd.github.io/GNPSDocumentation/featurebasedmolecularnetworking-with-openms
170 247
171 248
172 For more information, visit http://www.openms.de/doxygen/release/2.8.0/html/TOPP_GNPSExport.html]]></help> 249 For more information, visit https://openms.de/doxygen/release/3.1.0/html/TOPP_GNPSExport.html]]></help>
173 <expand macro="references"/> 250 <expand macro="references"/>
174 </tool> 251 </tool>