comparison GNPSExport.xml @ 4:2da14ae3844a draft

planemo upload for repository https://github.com/galaxyproteomics/tools-galaxyp/tree/master/tools/openms commit 3d1e5f37fd16524a415f707772eeb7ead848c5e3
author galaxyp
date Thu, 01 Dec 2022 18:57:27 +0000
parents 2dabae2814df
children 87a970d1514b
comparison
equal deleted inserted replaced
3:d5cb5af21850 4:2da14ae3844a
1 <?xml version='1.0' encoding='UTF-8'?> 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.--> 2 <!--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: []--> 3 <!--Proposed Tool Section: [File Handling]-->
4 <tool id="GNPSExport" name="GNPSExport" version="@TOOL_VERSION@+galaxy@GALAXY_VERSION@" profile="20.05"> 4 <tool id="GNPSExport" name="GNPSExport" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="21.05">
5 <description>Tool to export consensus features into MGF format</description> 5 <description>Tool to export representative consensus MS/MS scan per consensusElement into a .MGF file format.
6 See the documentation on https://ccms-ucsd.github.io/GNPSDocumentation/featurebasedmolecularnetworking-with-openms</description>
6 <macros> 7 <macros>
7 <token name="@EXECUTABLE@">GNPSExport</token> 8 <token name="@EXECUTABLE@">GNPSExport</token>
8 <import>macros.xml</import> 9 <import>macros.xml</import>
9 <import>macros_autotest.xml</import>
10 <import>macros_test.xml</import>
11 </macros> 10 </macros>
12 <expand macro="requirements"/> 11 <expand macro="requirements"/>
13 <expand macro="stdio"/> 12 <expand macro="stdio"/>
14 <command detect_errors="exit_code"><![CDATA[@QUOTE_FOO@ 13 <command detect_errors="exit_code"><![CDATA[@QUOTE_FOO@
15 @EXT_FOO@ 14 @EXT_FOO@
16 #import re 15 #import re
17 16
18 ## Preprocessing 17 ## Preprocessing
19 mkdir in_cm && 18 mkdir in_cm &&
20 ln -s '$in_cm' 'in_cm/${re.sub("[^\w\-_]", "_", $in_cm.element_identifier)}.$gxy2omsext($in_cm.ext)' && 19 ln -s '$in_cm' 'in_cm/${re.sub("[^\w\-_]", "_", $in_cm.element_identifier)}.$gxy2omsext($in_cm.ext)' &&
21 mkdir in_mzml && 20 mkdir in_mzml_cond.in_mzml &&
22 ${ ' '.join(["ln -s '%s' 'in_mzml/%s.%s' &&" % (_, re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $in_mzml if _]) } 21 #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])} &&
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])}
24 #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)' &&
26 #end if
23 mkdir out && 27 mkdir out &&
24 28
25 ## Main program call 29 ## Main program call
26 30
27 set -o pipefail && 31 set -o pipefail &&
29 python3 '$__tool_directory__/fill_ctd.py' '@EXECUTABLE@.ctd' '$args_json' '$hardcoded_json' && 33 python3 '$__tool_directory__/fill_ctd.py' '@EXECUTABLE@.ctd' '$args_json' '$hardcoded_json' &&
30 @EXECUTABLE@ -ini @EXECUTABLE@.ctd 34 @EXECUTABLE@ -ini @EXECUTABLE@.ctd
31 -in_cm 35 -in_cm
32 'in_cm/${re.sub("[^\w\-_]", "_", $in_cm.element_identifier)}.$gxy2omsext($in_cm.ext)' 36 'in_cm/${re.sub("[^\w\-_]", "_", $in_cm.element_identifier)}.$gxy2omsext($in_cm.ext)'
33 -in_mzml 37 -in_mzml
34 ${' '.join(["'in_mzml/%s.%s'"%(re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $in_mzml if _])} 38 #if $in_mzml_cond.in_mzml_select == "no"
39 ${' '.join(["'in_mzml_cond.in_mzml/%s/%s.%s'"%(i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($in_mzml_cond.in_mzml) if f])}
40 #else
41 '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
35 -out 43 -out
36 'out/output.${gxy2omsext("mgf")}' 44 'out/output.${gxy2omsext("mgf")}'
37 45
38 ## Postprocessing 46 ## Postprocessing
39 && mv 'out/output.${gxy2omsext("mgf")}' '$out' 47 && mv 'out/output.${gxy2omsext("mgf")}' '$out'
43 <configfiles> 51 <configfiles>
44 <inputs name="args_json" data_style="paths"/> 52 <inputs name="args_json" data_style="paths"/>
45 <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile> 53 <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile>
46 </configfiles> 54 </configfiles>
47 <inputs> 55 <inputs>
48 <param name="in_cm" argument="-in_cm" type="data" format="consensusxml" optional="false" label="input file containing consensus elements with 'peptide' annotations" help=" select consensusxml data sets(s)"/> 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)"/>
49 <param name="in_mzml" argument="-in_mzml" type="data" format="mzml" multiple="true" optional="false" label="original mzml files containing ms/ms spectrum information" help=" select mzml data sets(s)"/> 57 <conditional name="in_mzml_cond">
50 <param name="output_type" argument="-output_type" display="radio" type="select" optional="false" label="specificity of mgf output information" help=""> 58 <param name="in_mzml_select" type="select" label="Run tool in batch mode for -in_mzml">
51 <option value="full_spectra" selected="true">full_spectra</option> 59 <option value="no">No: process all datasets jointly</option>
60 <option value="yes">Yes: process each dataset in an independent job</option>
61 </param>
62 <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)"/>
64 </when>
65 <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)"/>
67 </when>
68 </conditional>
69 <param argument="-output_type" type="select" optional="true" label="specificity of mgf output information" help="">
52 <option value="merged_spectra">merged_spectra</option> 70 <option value="merged_spectra">merged_spectra</option>
53 <expand macro="list_string_san"/> 71 <option value="most_intense" selected="true">most_intense</option>
72 <expand macro="list_string_san" name="output_type"/>
54 </param> 73 </param>
55 <param name="precursor_mz_tolerance" argument="-precursor_mz_tolerance" type="float" optional="true" value="0.0001" label="Tolerance mz window for precursor selection" help=""/> 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=""/>
56 <param name="precursor_rt_tolerance" argument="-precursor_rt_tolerance" type="float" optional="true" value="5.0" label="Tolerance rt window for precursor selection" 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=""/>
57 <section name="merged_spectra" title="Options for exporting mgf file with merged spectra per feature" help="" expanded="false"> 76 <section name="merged_spectra" title="Options for exporting mgf file with merged spectra per consensusElement" help="" expanded="false">
58 <param name="cos_similarity" argument="-merged_spectra:cos_similarity" type="float" optional="true" value="0.95" label="Cosine similarity threshold for merged_spectra output" help=""/> 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=""/>
59 </section> 78 </section>
60 <expand macro="adv_opts_macro"> 79 <expand macro="adv_opts_macro">
61 <param name="force" argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overrides tool-specific checks" help=""/> 80 <param argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overrides tool-specific checks" help=""/>
62 <param name="test" argument="-test" type="hidden" optional="true" value="False" label="Enables the test mode (needed for internal use only)" help=""> 81 <param argument="-test" type="hidden" optional="true" value="False" label="Enables the test mode (needed for internal use only)" help="">
63 <expand macro="list_string_san"/> 82 <expand macro="list_string_san" name="test"/>
64 </param> 83 </param>
65 </expand> 84 </expand>
66 <param name="OPTIONAL_OUTPUTS" type="select" optional="true" multiple="true" label="Optional outputs"> 85 <param name="OPTIONAL_OUTPUTS" type="select" optional="true" multiple="true" label="Optional outputs">
67 <option value="ctd_out_FLAG">Output used ctd (ini) configuration file</option> 86 <option value="ctd_out_FLAG">Output used ctd (ini) configuration file</option>
68 </param> 87 </param>
71 <data name="out" label="${tool.name} on ${on_string}: out" format="mgf"/> 90 <data name="out" label="${tool.name} on ${on_string}: out" format="mgf"/>
72 <data name="ctd_out" format="xml" label="${tool.name} on ${on_string}: ctd"> 91 <data name="ctd_out" format="xml" label="${tool.name} on ${on_string}: ctd">
73 <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter> 92 <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter>
74 </data> 93 </data>
75 </outputs> 94 </outputs>
76 <tests> 95 <tests><!-- TOPP_GNPSExport_1 -->
77 <expand macro="autotest_GNPSExport"/> 96 <test expect_num_outputs="2">
78 <expand macro="manutest_GNPSExport"/> 97 <section name="adv_opts">
98 <param name="force" value="false"/>
99 <param name="test" value="true"/>
100 </section>
101 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/>
102 <conditional name="in_mzml_cond">
103 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/>
104 </conditional>
105 <output name="out" file="GNPSExport_1_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/>
106 <param name="output_type" value="most_intense"/>
107 <param name="peptide_cutoff" value="10"/>
108 <param name="ms2_bin_size" value="2.0"/>
109 <section name="merged_spectra">
110 <param name="cos_similarity" value="0.85"/>
111 </section>
112 <param name="OPTIONAL_OUTPUTS" value="ctd_out_FLAG"/>
113 <output name="ctd_out" ftype="xml">
114 <assert_contents>
115 <is_valid_xml/>
116 </assert_contents>
117 </output>
118 </test>
119 <!-- TOPP_GNPSExport_2 -->
120 <test expect_num_outputs="2">
121 <section name="adv_opts">
122 <param name="force" value="false"/>
123 <param name="test" value="true"/>
124 </section>
125 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/>
126 <conditional name="in_mzml_cond">
127 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/>
128 </conditional>
129 <output name="out" file="GNPSExport_2_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/>
130 <param name="output_type" value="merged_spectra"/>
131 <param name="peptide_cutoff" value="10"/>
132 <param name="ms2_bin_size" value="2.0"/>
133 <section name="merged_spectra">
134 <param name="cos_similarity" value="0.85"/>
135 </section>
136 <param name="OPTIONAL_OUTPUTS" value="ctd_out_FLAG"/>
137 <output name="ctd_out" ftype="xml">
138 <assert_contents>
139 <is_valid_xml/>
140 </assert_contents>
141 </output>
142 </test>
143 <!-- TOPP_GNPSExport_3 -->
144 <test expect_num_outputs="2">
145 <section name="adv_opts">
146 <param name="force" value="false"/>
147 <param name="test" value="true"/>
148 </section>
149 <param name="in_cm" value="GNPSExport_cons1.consensusXML"/>
150 <conditional name="in_mzml_cond">
151 <param name="in_mzml" value="GNPSExport_mzml1.mzML,GNPSExport_mzml2.mzML"/>
152 </conditional>
153 <output name="out" file="GNPSExport_3_out.mgf" compare="sim_size" delta_frac="0.7" ftype="mgf"/>
154 <param name="output_type" value="most_intense"/>
155 <param name="peptide_cutoff" value="10"/>
156 <param name="ms2_bin_size" value="0.02"/>
157 <section name="merged_spectra">
158 <param name="cos_similarity" value="0.85"/>
159 </section>
160 <param name="OPTIONAL_OUTPUTS" value="ctd_out_FLAG"/>
161 <output name="ctd_out" ftype="xml">
162 <assert_contents>
163 <is_valid_xml/>
164 </assert_contents>
165 </output>
166 </test>
79 </tests> 167 </tests>
80 <help><![CDATA[Tool to export consensus features into MGF format 168 <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
81 170
82 ]]></help> 171
172 For more information, visit http://www.openms.de/doxygen/release/2.8.0/html/TOPP_GNPSExport.html]]></help>
83 <expand macro="references"/> 173 <expand macro="references"/>
84 </tool> 174 </tool>