comparison rrparser.xml @ 4:b97690ee00e7 draft default tip

planemo upload for repository https://github.com/galaxyproject/tools-iuc/tree/master/tools/rrparser commit 09b98dbaa3afe569a76577ab668dde6b4ee54b24
author iuc
date Mon, 14 Apr 2025 18:29:54 +0000
parents e5b1f1d99918
children
comparison
equal deleted inserted replaced
3:e5b1f1d99918 4:b97690ee00e7
1 <tool id="rrparser" name="RRules Parser" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="21.09"> 1 <tool id="rrparser" name="RRules Parser" version="@TOOL_VERSION@+galaxy@VERSION_SUFFIX@" profile="24.2" license="MIT">
2 <description>Retrieve the reaction rules from RetroRules</description> 2 <description>Retrieve the reaction rules from RetroRules</description>
3 <macros> 3 <macros>
4 <token name="@VERSION_SUFFIX@">0</token> 4 <token name="@VERSION_SUFFIX@">1</token>
5 <token name="@TOOL_VERSION@">2.7.0</token> 5 <token name="@TOOL_VERSION@">2.7.0</token>
6 </macros> 6 </macros>
7 <requirements> 7 <requirements>
8 <requirement type="package" version="@TOOL_VERSION@">rrparser</requirement> 8 <requirement type="package" version="@TOOL_VERSION@">rrparser</requirement>
9 </requirements> 9 </requirements>
18 --rule-type '$rules.type' 18 --rule-type '$rules.type'
19 #else: 19 #else:
20 --rules_file '$rules.file' 20 --rules_file '$rules.file'
21 --input-format '$rules.input_format' 21 --input-format '$rules.input_format'
22 #end if 22 #end if
23 --diameters '$diameters' 23 --diameters '$adv.diameters'
24 --output-format csv 24 --output-format csv
25 --rules-dir "\${TMPDIR:-.}" 25 --rules-dir "\${TMPDIR:-.}"
26 #if str($compress) == "true": 26 #if str($adv.compress) == "true":
27 --outfile '$out_rules'.csv.gz 27 --outfile '$out_rules'.csv.gz
28 && mv '$out_rules'.csv.gz '$out_rules' 28 && mv '$out_rules'.csv.gz '$out_rules'
29 #else: 29 #else:
30 --outfile '$out_rules' 30 --outfile '$out_rules'
31 #end if
32 #if str($adv.input_conditional_ec.input_type) == "in"
33 --ec '$adv.input_conditional_ec.input_ec_in'
34 #end if
35 #if str($adv.input_conditional_ec.input_type) == "out"
36 --ecx '$adv.input_conditional_ec.input_ec_out'
37 #end if
38 #if $adv.input_scores_file
39 --scores '$adv.input_scores_file'
31 #end if 40 #end if
32 ]]></command> 41 ]]></command>
33 <inputs> 42 <inputs>
34 <conditional name="rules"> 43 <conditional name="rules">
35 <param name="type" type="select" label="Rule Type" help="Return the rules that are in reverse, forward, both direction or from an input user file"> 44 <param name="type" type="select" label="Rule Type" help="Return the rules that are in reverse, forward, both direction or from an input user file">
47 <option value="csv" selected="True">csv</option> 56 <option value="csv" selected="True">csv</option>
48 <option value="tsv">tsv</option> 57 <option value="tsv">tsv</option>
49 </param> 58 </param>
50 </when> 59 </when>
51 </conditional> 60 </conditional>
52 <param argument="--diameters" type="select" display="checkboxes" multiple="True" label="Select the diameters of the reactions rules" help=" Diameter of the sphere including the atoms around the reacting center (default is including all values: 2,4,6,8,10,12,14,16). The higher is the diameter, the more specific are the rules"> 61 <section name="adv" title="Advanced Options" expanded="false" >
53 <option selected="true" value="2">2</option> 62 <param name="compress" type="boolean" checked="false" label="Compress output" />
54 <option selected="true" value="4">4</option> 63 <param name="input_scores_file" type="data" format="csv" optional="True" label="Score File" help="Filename containing rules names and scores" />
55 <option selected="true" value="6">6</option> 64 <conditional name="input_conditional_ec">
56 <option selected="true" value="8">8</option> 65 <param name="input_type" type="select" label="Filter based on EC number">
57 <option selected="true" value="10">10</option> 66 <option value="no" selected="True">No</option>
58 <option selected="true" value="12">12</option> 67 <option value="in">EC numbers to keep</option>
59 <option selected="true" value="14">14</option> 68 <option value="out">EC numbers to remove</option>
60 <option selected="true" value="16">16</option> 69 </param>
61 </param> 70 <when value="no" />
62 <param name="compress" type="boolean" checked="false" label="Compress output" /> 71 <when value="in">
72 <param name="input_ec_in" type="data" format="txt" label="File containing EC numbers to remove" help="EC numbers on one line separated by a comma">
73 <sanitizer invalid_char="">
74 <valid initial="string.ascii_letters,string.digits">
75 <add value="," />
76 <add value="." />
77 </valid>
78 </sanitizer>
79 </param>
80 </when>
81 <when value="out">
82 <param name="input_ec_out" type="data" format="txt" label="File containing EC numbers to remove" help="EC numbers on one line separated by a comma">
83 <sanitizer invalid_char="">
84 <valid initial="string.ascii_letters,string.digits">
85 <add value="," />
86 <add value="." />
87 </valid>
88 </sanitizer>
89 </param>
90 </when>
91 </conditional>
92 <param argument="--diameters" type="select" display="checkboxes" multiple="True" label="Select the diameters of the reactions rules" help=" Diameter of the sphere including the atoms around the reacting center (default is including all values: 2,4,6,8,10,12,14,16). The higher is the diameter, the more specific are the rules">
93 <option selected="true" value="2">2</option>
94 <option selected="true" value="4">4</option>
95 <option selected="true" value="6">6</option>
96 <option selected="true" value="8">8</option>
97 <option selected="true" value="10">10</option>
98 <option selected="true" value="12">12</option>
99 <option selected="true" value="14">14</option>
100 <option selected="true" value="16">16</option>
101 </param>
102 </section>
103
63 </inputs> 104 </inputs>
64 <outputs> 105 <outputs>
65 <data name="out_rules" format="csv" label="${tool.name}(${rules.type}, d=$diameters)" > 106 <data name="out_rules" format="csv" label="${tool.name}(${rules.type}, d=$diameters)" >
66 <change_format> 107 <change_format>
67 <when input="compress" format="tar" value="true"/> 108 <when input="compress" format="tar" value="true"/>
73 <!-- test 1: check if identical outputs are produced with default parameters--> 114 <!-- test 1: check if identical outputs are produced with default parameters-->
74 <output name="out_rules" md5="54806bd44f7a8414e78439e3bb99e6d8"/> 115 <output name="out_rules" md5="54806bd44f7a8414e78439e3bb99e6d8"/>
75 </test> 116 </test>
76 <test> 117 <test>
77 <!-- test 2: check if identical outputs are produced with diameters=2,4,6--> 118 <!-- test 2: check if identical outputs are produced with diameters=2,4,6-->
78 <param name="diameters" value="2,4,6"/> 119 <section name="adv">
120 <param name="diameters" value="2,4,6"/>
121 </section>
79 <output name="out_rules" md5="12a55e1a3c7822a35ed799afa59b2aa2"/> 122 <output name="out_rules" md5="12a55e1a3c7822a35ed799afa59b2aa2"/>
80 </test> 123 </test>
81 <test> 124 <test>
82 <!-- test 3: check if identical outputs are produced with csv input rules file--> 125 <!-- test 3: check if identical outputs are produced with csv input rules file-->
83 <conditional name="rules"> 126 <conditional name="rules">
84 <param name="type" value="rules-file"/> 127 <param name="type" value="rules-file"/>
85 <param name="file" value="rules_in.csv" /> 128 <param name="file" value="rules_in.csv" />
86 </conditional> 129 </conditional>
87 <output name="out_rules" file="rules_out.csv" ftype="csv" compare="diff"/> 130 <output name="out_rules" file="rules_out.csv" ftype="csv" compare="diff"/>
131 </test>
132 <test>
133 <!-- test 4 -->
134 <conditional name="rules">
135 <param name="type" value="rules-file"/>
136 <param name="file" value="rules_in.csv" />
137 </conditional>
138 <section name="adv">
139 <conditional name="input_conditional_ec">
140 <param name="input_type" value="in"/>
141 <param name="input_ec_in" value="ec.txt"/>
142 </conditional>
143 </section>
144 <output name="out_rules" file="test.4.output.csv" ftype="csv" compare="diff"/>
145 </test>
146 <test>
147 <!-- python -m rrparser -rules_file rules_in.csv -input-format csv -ecx ec.txt -diameters 2,4,6,8,10,12,14,16 -output-format csv -outfile test.5.output.csv -->
148 <conditional name="rules">
149 <param name="type" value="rules-file"/>
150 <param name="file" value="rules_in.csv" />
151 </conditional>
152 <section name="adv">
153 <conditional name="input_conditional_ec">
154 <param name="input_type" value="out"/>
155 <param name="input_ec_out" value="ec.txt"/>
156 </conditional>
157 </section>
158 <output name="out_rules" file="test.5.output.csv" ftype="csv" compare="diff"/>
159 </test>
160 <test>
161 <!-- python -m rrparser -rules_file rules_in.csv -input-format csv -diameters 2,4,6,8,10,12,14,16 -output-format csv -outfile rules_scores.csv -scores scores.csv -->
162 <conditional name="rules">
163 <param name="type" value="rules-file"/>
164 <param name="file" value="rules_in.csv" />
165 </conditional>
166 <section name="adv" >
167 <param name="input_scores_file" value="scores.csv" />
168 </section>
169 <output name="out_rules" file="rules_scores.csv" ftype="csv" compare="diff"/>
88 </test> 170 </test>
89 </tests> 171 </tests>
90 <help><![CDATA[ 172 <help><![CDATA[
91 RRulesParser 173 RRulesParser
92 ============ 174 ============
93 175
94 Retrieve the reaction rules from `RetroRules <https://retrorules.org/>`_ extracted from public databases and expressed in the community-standard SMARTS (SMILES arbitrary target specification) format, augmented by a rule representation at different levels of specificity (the atomic environment around the reaction center). 176 Retrieve the reaction rules from `RetroRules <https://retrorules.org/>`_ extracted from public databases and expressed in the community-standard SMARTS (SMILES arbitrary target specification) format, augmented by a rule representation at different levels of specificity (the atomic environment around the reaction center).
95 177
96 The generated output is a file containing reaction rules which are generic descriptions of chemical reactions that can be used in retrosynthesis workflows (e.g. Retrosynthesis KNIME Workflow) in order to enumerate all possible biosynthetic routes connecting a target molecule to its precursors. 178 The generated output is a file containing reaction rules which are generic descriptions of chemical reactions that can be used in retrosynthesis workflows (e.g. `Retrosynthesis KNIME Workflow <https://www.myexperiment.org/workflows/4987.html>`_) in order to enumerate all possible biosynthetic routes connecting a target molecule to its precursors.
97 179
98 Input 180 Input
99 ----- 181 -----
100 182
101 * **Rule Type**: (string) Return the rules that are in reverse, forward, both direction or from an input user file 183 * **Rule Type**: (string) Return the rules that are in reverse, forward, both direction or from an input user file
102 * **rules-file**: (string) Filename of reaction rules provided in csv or tsv format. 184 * **rules-file**: (string) Filename of reaction rules provided in csv or tsv format.
103 * **input_format**: (string) input file format (csv: default, tsv) 185 * **input_format**: (string) input file format (csv: default, tsv)
104 * **diameters**: (integer list) diameter of the sphere including the atoms around the reacting center (default is including all values: 2,4,6,8,10,12,14,16). The higher is the diameter, the more specific are the rules 186 * **diameters**: (integer list) diameter of the sphere including the atoms around the reacting center (default is including all values: 2,4,6,8,10,12,14,16). The higher is the diameter, the more specific are the rules
187 * **EC numbers to filter**: retain or remove some EC numbers. A file is expected containing EC numbers separated by a comma on the first line.
188 * **Scores file**: file containing rules names and scores
105 189
106 Ouput 190 Ouput
107 ----- 191 -----
108 192
109 * **out_rules**: (string): file containing the parsed reactions rules (default=csv). It will be zipped if *Compress output* is set to yes. 193 * **out_rules**: (string): file containing the parsed reactions rules (default=csv). It will be zipped if *Compress output* is set to yes.
110
111 Version
112 -------
113
114 v2.6.0
115
116 Authors
117 -------
118
119 * **Thomas Duigou**
120 * Melchior du Lac
121 * Joan Hérisson
122
123 License
124 -------
125
126 This project is licensed under the MIT License - see the `LICENSE <https://github.com/brsynth/RRParser/blob/master/LICENSE>`_ file for details
127
128 Acknowledgments
129 ---------------
130
131 * Joan Hérisson
132
133 ]]></help> 194 ]]></help>
195 <creator>
196 <organization name="BioRetroSynth" url="https://github.com/brsynth"/>
197 </creator>
134 <citations> 198 <citations>
135 <citation type="doi">10.1093/nar/gky940 </citation> 199 <citation type="doi">10.1093/nar/gky940</citation>
136 </citations> 200 </citations>
137 </tool> 201 </tool>