diff AccurateMassSearch.xml @ 17:31e674c86840 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:41:27 +0000
parents 532cf3ddcc91
children
line wrap: on
line diff
--- a/AccurateMassSearch.xml	Thu Dec 01 19:05:06 2022 +0000
+++ b/AccurateMassSearch.xml	Fri Jun 14 21:41:27 2024 +0000
@@ -1,8 +1,7 @@
-<?xml version='1.0' encoding='UTF-8'?>
 <!--This is a configuration file for the integration of a tools into Galaxy (https://galaxyproject.org/). This file was automatically generated using CTDConverter.-->
-<!--Proposed Tool Section: [Utilities]-->
+<!--Proposed Tool Section: [Metabolite Identification]-->
 <tool id="AccurateMassSearch" name="AccurateMassSearch" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="21.05">
-  <description>Match MS signals to molecules from a database by mass.</description>
+  <description>Match MS signals to molecules from a database by mass</description>
   <macros>
     <token name="@EXECUTABLE@">AccurateMassSearch</token>
     <import>macros.xml</import>
@@ -15,35 +14,35 @@
 
 ## Preprocessing
 mkdir in &&
-ln -s '$in' 'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)' &&
+cp '$in' 'in/${re.sub("[^\w\-_]", "_", $in.element_identifier)}.$gxy2omsext($in.ext)' &&
 mkdir out &&
 #if "out_annotation_FLAG" in str($OPTIONAL_OUTPUTS).split(',')
   mkdir out_annotation &&
 #end if
 #if $positive_adducts:
   mkdir positive_adducts &&
-  ln -s '$positive_adducts' 'positive_adducts/${re.sub("[^\w\-_]", "_", $positive_adducts.element_identifier)}.$gxy2omsext($positive_adducts.ext)' &&
+  cp '$positive_adducts' 'positive_adducts/${re.sub("[^\w\-_]", "_", $positive_adducts.element_identifier)}.$gxy2omsext($positive_adducts.ext)' &&
 #end if
 #if $negative_adducts:
   mkdir negative_adducts &&
-  ln -s '$negative_adducts' 'negative_adducts/${re.sub("[^\w\-_]", "_", $negative_adducts.element_identifier)}.$gxy2omsext($negative_adducts.ext)' &&
+  cp '$negative_adducts' 'negative_adducts/${re.sub("[^\w\-_]", "_", $negative_adducts.element_identifier)}.$gxy2omsext($negative_adducts.ext)' &&
 #end if
 #if $db.mapping_cond.mapping:
   mkdir db.mapping_cond.mapping &&
   #if $db.mapping_cond.mapping_select == "no"
   mkdir ${' '.join(["'db.mapping_cond.mapping/%s'" % (i) for i, f in enumerate($db.mapping_cond.mapping) if f])} && 
-  ${' '.join(["ln -s '%s' 'db.mapping_cond.mapping/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($db.mapping_cond.mapping) if f])}
+  ${' '.join(["cp '%s' 'db.mapping_cond.mapping/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($db.mapping_cond.mapping) if f])}
   #else
-  ln -s '$db.mapping_cond.mapping' 'db.mapping_cond.mapping/${re.sub("[^\w\-_]", "_", $db.mapping_cond.mapping.element_identifier)}.$gxy2omsext($db.mapping_cond.mapping.ext)' &&
+  cp '$db.mapping_cond.mapping' 'db.mapping_cond.mapping/${re.sub("[^\w\-_]", "_", $db.mapping_cond.mapping.element_identifier)}.$gxy2omsext($db.mapping_cond.mapping.ext)' &&
   #end if
 #end if
 #if $db.struct_cond.struct:
   mkdir db.struct_cond.struct &&
   #if $db.struct_cond.struct_select == "no"
   mkdir ${' '.join(["'db.struct_cond.struct/%s'" % (i) for i, f in enumerate($db.struct_cond.struct) if f])} && 
-  ${' '.join(["ln -s '%s' 'db.struct_cond.struct/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($db.struct_cond.struct) if f])}
+  ${' '.join(["cp '%s' 'db.struct_cond.struct/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($db.struct_cond.struct) if f])}
   #else
-  ln -s '$db.struct_cond.struct' 'db.struct_cond.struct/${re.sub("[^\w\-_]", "_", $db.struct_cond.struct.element_identifier)}.$gxy2omsext($db.struct_cond.struct.ext)' &&
+  cp '$db.struct_cond.struct' 'db.struct_cond.struct/${re.sub("[^\w\-_]", "_", $db.struct_cond.struct.element_identifier)}.$gxy2omsext($db.struct_cond.struct.ext)' &&
   #end if
 #end if
 
@@ -102,8 +101,8 @@
     <configfile name="hardcoded_json"><![CDATA[{"log": "log.txt", "threads": "\${GALAXY_SLOTS:-1}", "no_progress": true}]]></configfile>
   </configfiles>
   <inputs>
-    <param argument="-in" type="data" format="consensusxml,featurexml" optional="false" label="featureXML or consensusXML file" help=" select consensusxml,featurexml data sets(s)"/>
-    <param name="out_annotation_type" type="select" optional="false" label="File type of output out_annotation (A copy of the input file, annotated with matching hits from the database.)">
+    <param argument="-in" type="data" format="consensusxml,featurexml" label="featureXML or consensusXML file" help=" select consensusxml,featurexml data sets(s)"/>
+    <param name="out_annotation_type" type="select" label="File type of output out_annotation (A copy of the input file, annotated with matching hits from the database.)">
       <option value="featureXML">featurexml</option>
       <option value="consensusXML">consensusxml</option>
       <option value="oms">sqlite (oms)</option>
@@ -120,7 +119,7 @@
           <param name="mapping" argument="-db:mapping" type="data" format="tabular" multiple="true" optional="true" label="Database input file(s), containing three tab-separated columns of mass, formula, identifie" help="If 'mass' is 0, it is re-computed from the molecular sum formula. By default CHEMISTRY/HMDBMappingFile.tsv in OpenMS/share is used! If empty, the default will be used select tabular data sets(s)"/>
         </when>
         <when value="yes">
-          <param name="mapping" argument="-db:mapping" type="data" format="tabular" multiple="false" optional="true" label="Database input file(s), containing three tab-separated columns of mass, formula, identifie" help="If 'mass' is 0, it is re-computed from the molecular sum formula. By default CHEMISTRY/HMDBMappingFile.tsv in OpenMS/share is used! If empty, the default will be used select tabular data sets(s)"/>
+          <param name="mapping" argument="-db:mapping" type="data" format="tabular" optional="true" label="Database input file(s), containing three tab-separated columns of mass, formula, identifie" help="If 'mass' is 0, it is re-computed from the molecular sum formula. By default CHEMISTRY/HMDBMappingFile.tsv in OpenMS/share is used! If empty, the default will be used select tabular data sets(s)"/>
         </when>
       </conditional>
       <conditional name="struct_cond">
@@ -132,18 +131,18 @@
           <param name="struct" argument="-db:struct" type="data" format="tabular" multiple="true" optional="true" label="Database input file(s), containing four tab-separated columns of identifier, name, SMILES, INCHI.The identifier should match with mapping file" help="SMILES and INCHI are reported in the output, but not used otherwise. By default CHEMISTRY/HMDB2StructMapping.tsv in OpenMS/share is used! If empty, the default will be used select tabular data sets(s)"/>
         </when>
         <when value="yes">
-          <param name="struct" argument="-db:struct" type="data" format="tabular" multiple="false" optional="true" label="Database input file(s), containing four tab-separated columns of identifier, name, SMILES, INCHI.The identifier should match with mapping file" help="SMILES and INCHI are reported in the output, but not used otherwise. By default CHEMISTRY/HMDB2StructMapping.tsv in OpenMS/share is used! If empty, the default will be used select tabular data sets(s)"/>
+          <param name="struct" argument="-db:struct" type="data" format="tabular" optional="true" label="Database input file(s), containing four tab-separated columns of identifier, name, SMILES, INCHI.The identifier should match with mapping file" help="SMILES and INCHI are reported in the output, but not used otherwise. By default CHEMISTRY/HMDB2StructMapping.tsv in OpenMS/share is used! If empty, the default will be used select tabular data sets(s)"/>
         </when>
       </conditional>
     </section>
     <section name="algorithm" title="Algorithm parameters section" help="" expanded="false">
-      <param name="mass_error_value" argument="-algorithm:mass_error_value" type="float" optional="true" value="5.0" label="Tolerance allowed for accurate mass search" help=""/>
-      <param name="mass_error_unit" argument="-algorithm:mass_error_unit" type="select" optional="true" label="Unit of mass error (ppm or Da)" help="">
+      <param name="mass_error_value" argument="-algorithm:mass_error_value" type="float" value="5.0" label="Tolerance allowed for accurate mass search" help=""/>
+      <param name="mass_error_unit" argument="-algorithm:mass_error_unit" type="select" label="Unit of mass error (ppm or Da)" help="">
         <option value="ppm" selected="true">ppm</option>
         <option value="Da">Da</option>
         <expand macro="list_string_san" name="mass_error_unit"/>
       </param>
-      <param name="ionization_mode" argument="-algorithm:ionization_mode" type="select" optional="true" label="Positive or negative ionization mode" help="If 'auto' is used, the first feature of the input map must contain the meta-value 'scan_polarity'. If its missing, the tool will exit with error">
+      <param name="ionization_mode" argument="-algorithm:ionization_mode" type="select" label="Positive or negative ionization mode" help="If 'auto' is used, the first feature of the input map must contain the meta-value 'scan_polarity'. If its missing, the tool will exit with error">
         <option value="positive" selected="true">positive</option>
         <option value="negative">negative</option>
         <option value="auto">auto</option>
@@ -152,7 +151,7 @@
       <param name="isotopic_similarity" argument="-algorithm:isotopic_similarity" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Computes a similarity score for each hit (only if the feature exhibits at least two isotopic mass traces)" help=""/>
       <param name="use_feature_adducts" argument="-algorithm:use_feature_adducts" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Whether to filter AMS candidates mismatching available feature adduct annotation" help=""/>
       <param name="keep_unidentified_masses" argument="-algorithm:keep_unidentified_masses" type="boolean" truevalue="true" falsevalue="false" checked="true" label="Keep features that did not yield any DB hit" help=""/>
-      <param name="id_format" argument="-algorithm:id_format" type="select" optional="true" label="Use legacy (ProteinID/PeptideID based storage of metabolomics data) with mzTab-v1.0.0 as output format or novel Identification Data (ID) with mzTab-v2.0.0-M as output format (ID and its MzTab-M output is currently only support for featureXML files)" help="">
+      <param name="id_format" argument="-algorithm:id_format" type="select" label="Use legacy (ProteinID/PeptideID based storage of metabolomics data) with mzTab-v1.0.0 as output format or novel Identification Data (ID) with mzTab-v2.0.0-M as output format (ID and its MzTab-M output is currently only support for featureXML files)" help="">
         <option value="legacy" selected="true">legacy</option>
         <option value="ID">ID</option>
         <expand macro="list_string_san" name="id_format"/>
@@ -163,7 +162,7 @@
     </section>
     <expand macro="adv_opts_macro">
       <param argument="-force" type="boolean" truevalue="true" falsevalue="false" checked="false" label="Overrides tool-specific checks" help=""/>
-      <param argument="-test" type="hidden" optional="true" value="False" label="Enables the test mode (needed for internal use only)" help="">
+      <param argument="-test" type="hidden" value="False" label="Enables the test mode (needed for internal use only)" help="" optional="true">
         <expand macro="list_string_san" name="test"/>
       </param>
     </expand>
@@ -185,14 +184,15 @@
       <filter>OPTIONAL_OUTPUTS is not None and "ctd_out_FLAG" in OPTIONAL_OUTPUTS</filter>
     </data>
   </outputs>
-  <tests><!-- UTILS_AccurateMassSearch_1 -->
+  <tests>
+    <!-- TOPP_AccurateMassSearch_1 -->
     <test expect_num_outputs="2">
       <section name="adv_opts">
         <param name="force" value="false"/>
         <param name="test" value="true"/>
       </section>
       <param name="in" value="ConsensusMapNormalizer_input.consensusXML"/>
-      <output name="out" file="AccurateMassSearch_1_output.tmp.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
+      <output name="out" value="AccurateMassSearch_1_output.csv" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
       <param name="positive_adducts" value="CHEMISTRY/PositiveAdducts.tsv" ftype="tabular"/>
       <param name="negative_adducts" value="CHEMISTRY/NegativeAdducts.tsv" ftype="tabular"/>
       <section name="db">
@@ -221,17 +221,20 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
-    <!-- UTILS_AccurateMassSearch_2 -->
+    <!-- TOPP_AccurateMassSearch_2 -->
     <test expect_num_outputs="3">
       <section name="adv_opts">
         <param name="force" value="false"/>
         <param name="test" value="true"/>
       </section>
       <param name="in" value="AccurateMassSearch_2_input.featureXML"/>
-      <output name="out" file="AccurateMassSearch_2_output.tmp.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
+      <output name="out" value="AccurateMassSearch_2_output.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
       <param name="out_annotation_type" value="featureXML"/>
-      <output name="out_annotation" file="AccurateMassSearch_2_output.tmp.featureXML" compare="sim_size" delta_frac="0.7" ftype="featurexml"/>
+      <output name="out_annotation" value="AccurateMassSearch_2_output.featureXML" compare="sim_size" delta_frac="0.7" ftype="featurexml"/>
       <param name="positive_adducts" value="AMS_PositiveAdducts.tsv" ftype="tabular"/>
       <param name="negative_adducts" value="AMS_NegativeAdducts.tsv" ftype="tabular"/>
       <section name="db">
@@ -260,17 +263,20 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
-    <!-- UTILS_AccurateMassSearch_3 -->
+    <!-- TOPP_AccurateMassSearch_3 -->
     <test expect_num_outputs="3">
       <section name="adv_opts">
         <param name="force" value="false"/>
         <param name="test" value="true"/>
       </section>
       <param name="in" value="AccurateMassSearch_2_input.featureXML"/>
-      <output name="out" file="AccurateMassSearch_3_output.tmp.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
+      <output name="out" value="AccurateMassSearch_3_output.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
       <param name="out_annotation_type" value="featureXML"/>
-      <output name="out_annotation" file="AccurateMassSearch_2_output.tmp.featureXML" compare="sim_size" delta_frac="0.7" ftype="featurexml"/>
+      <output name="out_annotation" value="AccurateMassSearch_2_output.featureXML" compare="sim_size" delta_frac="0.7" ftype="featurexml"/>
       <param name="positive_adducts" value="AMS_PositiveAdducts.tsv" ftype="tabular"/>
       <param name="negative_adducts" value="AMS_NegativeAdducts.tsv" ftype="tabular"/>
       <section name="db">
@@ -299,17 +305,20 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
-    <!-- UTILS_AccurateMassSearch_5 -->
+    <!-- TOPP_AccurateMassSearch_5 -->
     <test expect_num_outputs="3">
       <section name="adv_opts">
         <param name="force" value="false"/>
         <param name="test" value="true"/>
       </section>
       <param name="in" value="AccurateMassSearch_2_input.featureXML"/>
-      <output name="out" file="AccurateMassSearch_5_output.tmp.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
+      <output name="out" value="AccurateMassSearch_5_output.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
       <param name="out_annotation_type" value="oms"/>
-      <output name="out_annotation" file="AccurateMassSearch_5_output.tmp.oms" compare="sim_size" delta_frac="0.7" ftype="sqlite"/>
+      <output name="out_annotation" value="AccurateMassSearch_5_output.tmp.oms" compare="sim_size" delta_frac="0.7" ftype="sqlite"/>
       <param name="positive_adducts" value="AMS_PositiveAdducts.tsv" ftype="tabular"/>
       <param name="negative_adducts" value="AMS_NegativeAdducts.tsv" ftype="tabular"/>
       <section name="db">
@@ -338,17 +347,20 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
-    <!-- UTILS_AccurateMassSearch_6 -->
+    <!-- TOPP_AccurateMassSearch_6 -->
     <test expect_num_outputs="3">
       <section name="adv_opts">
         <param name="force" value="false"/>
         <param name="test" value="true"/>
       </section>
       <param name="in" value="AccurateMassSearch_2_input.featureXML"/>
-      <output name="out" file="AccurateMassSearch_6_output.tmp.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
+      <output name="out" value="AccurateMassSearch_6_output.mzTab" compare="sim_size" delta_frac="0.7" ftype="mztab"/>
       <param name="out_annotation_type" value="featureXML"/>
-      <output name="out_annotation" file="AccurateMassSearch_6_output.tmp.featureXML" compare="sim_size" delta_frac="0.7" ftype="featurexml"/>
+      <output name="out_annotation" value="AccurateMassSearch_6_output.featureXML" compare="sim_size" delta_frac="0.7" ftype="featurexml"/>
       <param name="positive_adducts" value="AMS_PositiveAdducts.tsv" ftype="tabular"/>
       <param name="negative_adducts" value="AMS_NegativeAdducts.tsv" ftype="tabular"/>
       <section name="db">
@@ -377,11 +389,14 @@
           <is_valid_xml/>
         </assert_contents>
       </output>
+      <assert_stdout>
+        <has_text_matching expression="@EXECUTABLE@ took .* \(wall\), .* \(CPU\), .* \(system\), .* \(user\)(; Peak Memory Usage: 32 MB)?."/>
+      </assert_stdout>
     </test>
   </tests>
   <help><![CDATA[Match MS signals to molecules from a database by mass.
 
 
-For more information, visit http://www.openms.de/doxygen/release/2.8.0/html/UTILS_AccurateMassSearch.html]]></help>
+For more information, visit https://openms.de/doxygen/release/3.1.0/html/TOPP_AccurateMassSearch.html]]></help>
   <expand macro="references"/>
 </tool>