comparison osra.xml @ 4:aeb1f7daa7c2 draft

planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/chemicaltoolbox/osra commit 74daed54894d9769a251a2ca6a46d96b7a27e461
author bgruening
date Thu, 09 Nov 2017 03:41:42 -0500
parents d2490712b67d
children b2edf498e8fb
comparison
equal deleted inserted replaced
3:e44dda38e6ae 4:aeb1f7daa7c2
1 <tool id="ctb_osra" name="Molecule recognition" version="0.3"> 1 <tool id="ctb_osra" name="Molecule recognition" version="2.1.0">
2 <description>in Images or PDF documents (OSRA)</description> 2 <description>in Images or PDF documents (OSRA)</description>
3 <requirements> 3 <requirements>
4 <requirement type="package" version="2.0.0">osra</requirement> 4 <requirement type="package" version="2.1.0">osra</requirement>
5 <requirement type="package" version="2.3.2">openbabel</requirement>
6 <requirement type="package" version="1.3.18">graphicsmagick</requirement>
7 </requirements> 5 </requirements>
8 <command interpreter='python'> 6 <command detect_errors="aggressive">
9 <![CDATA[ 7 <![CDATA[
10 ## OSRA_DATA_FILES is set during the toolshed Installation 8 osra
11 ## if it is not set, use the standard configuration and hope the best 9 -f $oformat
12 osra.py -f $oformat $infile 10 '$infile'
13 -l \$OSRA_DATA_FILES/spelling.txt -a \$OSRA_DATA_FILES/superatom.txt 11 -l `which osra | xargs dirname`/../share/spelling.txt
12 -a `which osra | xargs dirname`/../share/superatom.txt
14 13
15 ## further additions of OSRA parameter should go after -l and -a 14 $confidence
16 ## because -l and -a can be removed by the python wrapper 15 $adaptive
17 16 $thinning
18 $confidence 17 > '$outfile'
19 $adaptive
20 $thinning
21
22 > $outfile
23 ]]> 18 ]]>
24 </command> 19 </command>
25 <inputs> 20 <inputs>
26 <param name="infile" type="data" format="png,pdf" label="Image or PDF with molecules"/> 21 <param name="infile" type="data" format="pdf" label="PDF with molecules"/>
27 <param name="oformat" type="select" label="Output molecule format"> 22 <param name="oformat" type="select" label="Output molecule format">
28 <option value="can">SMILES</option> 23 <option value="can">SMILES</option>
29 <option value="sdf">SDF</option> 24 <option value="sdf">SDF</option>
30 </param> 25 </param>
31 <param name="confidence" type="boolean" label="Print out confidence estimate (-p)" truevalue="-p" falsevalue="" checked="true" /> 26 <param name="confidence" type="boolean" label="Print out confidence estimate" help=" (-p)"
32 <param name="adaptive" type="boolean" label="Adaptive thresholding pre-processing, useful for low light/low contrast images (-i)" truevalue="-i" falsevalue="" checked="false" /> 27 truevalue="-p" falsevalue="" checked="true" />
33 <param name="thinning" type="boolean" label="Additional thinning/scaling down of low quality documents (-j)" truevalue="-j" falsevalue="" checked="false" /> 28 <param name="adaptive" type="boolean" label="Adaptive thresholding pre-processing, useful for low light/low contrast images" help="(-i)"
29 truevalue="-i" falsevalue="" checked="false" />
30 <param name="thinning" type="boolean" label="Additional thinning/scaling down of low quality documents" help="(-j)"
31 truevalue="-j" falsevalue="" checked="false" />
34 32
35 </inputs> 33 </inputs>
36 <outputs> 34 <outputs>
37 <data name="outfile" type="data" format="sdf"> 35 <data name="outfile" format="sdf">
38 <change_format> 36 <change_format>
39 <when input="oformat" value="can" format="smi"/> 37 <when input="oformat" value="can" format="smi"/>
40 </change_format> 38 </change_format>
41 </data> 39 </data>
42 </outputs> 40 </outputs>
43 <tests> 41 <tests>
44 <test> 42 <test>
45 <param name="infile" ftype="png" value="CID_2244.png"/> 43 <param name="infile" value="CID_2244.pdf" ftype="pdf"/>
46 <param name="oformat" value="sdf"/> 44 <param name="oformat" value="sdf"/>
47 <output name="outfile" ftype="sdf" file="osra_on_CID2244.sdf"/> 45 <output name="outfile" ftype="sdf" file="osra_on_CID2244.sdf"/>
48 </test> 46 </test>
49 <test> 47 <!--test>
50 <param name="infile" ftype="png" value="2008001635_153_chem.png"/> 48 PNGs producing a core-dump in osra
49 <param name="infile" value="2008001635_153_chem.png"/>
51 <param name="oformat" value="can"/> 50 <param name="oformat" value="can"/>
52 <output name="outfile" ftype="sdf" file="2008001635_153_chem.smi"/> 51 <output name="outfile" ftype="smi" file="2008001635_153_chem.smi"/>
53 </test> 52 </test-->
54
55 </tests> 53 </tests>
56 <help> 54 <help>
57 <![CDATA[ 55 <![CDATA[
58 56
59 .. class:: infomark 57 .. class:: infomark
62 60
63 OSRA_ (Optical Structure Recognition Application) is a utility designed to convert graphical representations of chemical structures into SMILES or SDF. It generates the SMILES or SDF representation of any molecular structure image within a document which is parseable by GraphicMagick. 61 OSRA_ (Optical Structure Recognition Application) is a utility designed to convert graphical representations of chemical structures into SMILES or SDF. It generates the SMILES or SDF representation of any molecular structure image within a document which is parseable by GraphicMagick.
64 62
65 .. _OSRA: http://cactus.nci.nih.gov/osra/ 63 .. _OSRA: http://cactus.nci.nih.gov/osra/
66 64
67 -----
68
69 .. class:: infomark
70
71 **Cite**
72
73 Igor V Filippov and Marc C Nicklaus - `Optical Structure Recognition Software To Recover Chemical Information: OSRA, An Open Source Solution`_
74
75 .. _`Optical Structure Recognition Software To Recover Chemical Information: OSRA, An Open Source Solution`: http://pubs.acs.org/doi/abs/10.1021/ci800067r 65 .. _`Optical Structure Recognition Software To Recover Chemical Information: OSRA, An Open Source Solution`: http://pubs.acs.org/doi/abs/10.1021/ci800067r
76 ]]> 66 ]]>
77 </help> 67 </help>
68 <citations>
69 <citation type="bibtex">
70 @inproceedings{filippov2010improvements,
71 title={Improvements in Optical Structure Recognition Application},
72 author={Filippov, Igor V and Nicklaus, Marc C and Kinney, John},
73 booktitle={Document Analysis Systems Workshop},
74 year={2010}
75 }
76 </citation>
77 </citations>
78 </tool> 78 </tool>