comparison imagej2_bunwarpj_elastic_transform.xml @ 1:39b2bc251b2f draft

"planemo upload for repository https://github.com/bgruening/galaxytools/tree/master/tools/image_processing/imagej2 commit 2afb24f3c81d625312186750a714d702363012b5"
author imgteam
date Mon, 28 Sep 2020 17:00:25 +0000
parents 301f24849032
children 55bf135d6b0c
comparison
equal deleted inserted replaced
0:301f24849032 1:39b2bc251b2f
1 <?xml version='1.0' encoding='UTF-8'?> 1 <tool id="imagej2_bunwarpj_elastic_transform" name="Apply elastic transformation" version="@WRAPPER_VERSION@.1">
2 <tool id="imagej2_bunwarpj_elastic_transform" name="Apply elastic transformation" version="@WRAPPER_VERSION@.0">
3 <description>with bUnwarpJ</description> 2 <description>with bUnwarpJ</description>
4 <macros> 3 <macros>
5 <import>imagej2_macros.xml</import> 4 <import>imagej2_macros.xml</import>
6 </macros> 5 </macros>
7 <expand macro="fiji_requirements" /> 6 <expand macro="fiji_requirements"/>
8 <command> 7 <command detect_errors="exit_code"><![CDATA[
9 <![CDATA[ 8 #import os
10 python $__tool_directory__/imagej2_bunwarpj_elastic_transform.py 9 #set error_log = 'output_log.txt'
11 --target_image "$target_image" 10 touch '$error_log' &&
12 --target_image_format $target_image.ext 11
13 --source_image "$source_image" 12 ## ImageJ2 requires file extensions to be valid image data types.
14 --source_image_format $source_image.ext 13 #set source_sans_ext = $os.path.splitext($os.path.basename($source_image.file_name))[0]
15 --elastic_transformation $elastic_transformation 14 #set source_with_ext = '.'.join([source_sans_ext, $source_image.ext])
16 --source_out "$source_out" 15 ln -s '$source_image.file_name' '$source_with_ext' &&
17 --source_out_datatype $source_out_datatype 16 #set target_sans_ext = $os.path.splitext($os.path.basename($target_image.file_name))[0]
18 --jython_script $__tool_directory__/imagej2_bunwarpj_elastic_transform_jython_script.py 17 #set target_with_ext = '.'.join([target_sans_ext, $target_image.ext])
19 ]]> 18 ln -s '$target_image.file_name' '$target_with_ext' &&
20 </command> 19
20 bunwarpj -elastic_transform
21 '$target_with_ext'
22 '$source_with_ext'
23 '$elastic_transformation'
24 '$source_out'
25 &>'$error_log';
26 if [[ $? -ne 0 ]]; then
27 cat '$error_log' >&2;
28 fi
29 ]]></command>
21 <inputs> 30 <inputs>
22 <param format="bmp,eps,gif,jpg,pcx,pgm,png,psd,tiff" name="target_image" type="data" label="Target image"/> 31 <expand macro="param_target_image"/>
23 <param format="bmp,eps,gif,jpg,pcx,pgm,png,psd,tiff" name="source_image" type="data" label="Source image"/> 32 <expand macro="param_source_image"/>
24 <!-- Support for a bUnwarpJ elastic transformation datatype should be added to Galaxy --> 33 <!-- Support for a bUnwarpJ elastic transformation datatype should be added to Galaxy -->
25 <param format="txt" name="elastic_transformation" type="data" label="Elastic transformation" help="As saved by bUnwarpJ in elastic format"/> 34 <param format="txt" name="elastic_transformation" type="data" label="Elastic transformation" help="As saved by bUnwarpJ in elastic format"/>
26 <param name="source_out_datatype" type="select" label="Save registered source image as format"> 35 <param name="source_out_datatype" type="select" label="Save registered source image as format">
27 <expand macro="image_datatypes" /> 36 <expand macro="image_datatypes"/>
28 </param> 37 </param>
29 </inputs> 38 </inputs>
30 <outputs> 39 <outputs>
31 <data name="source_out" format="png" label="${tool.name} on ${on_string}: Registered source image"> 40 <data name="source_out" format="png">
32 <actions> 41 <actions>
33 <action type="format"> 42 <action type="format">
34 <option type="from_param" name="source_out_datatype" /> 43 <option type="from_param" name="source_out_datatype"/>
35 </action> 44 </action>
36 </actions> 45 </actions>
37 </data> 46 </data>
38 </outputs> 47 </outputs>
39 <tests> 48 <tests>
40 <test> 49 <test>
41 <param name="target_image" value="dotblot.jpg" /> 50 <expand macro="test_target_source_images"/>
42 <param name="source_image" value="blobs.gif" /> 51 <param name="elastic_transformation" value="blobs_direct_transf.txt"/>
43 <param name="elastic_transformation" value="blobs_direct_transf.txt" /> 52 <output name="source_out" file="elastic_trans_registered_source1.png" compare="sim_size"/>
44 <param name="source_out_datatype" value="png" />
45 <output name="source_out" file="elastic_trans_registered_source1.png" compare="sim_size" />
46 </test> 53 </test>
47 </tests> 54 </tests>
48 <help> 55 <help>
49 **What it does** 56 **What it does**
50 57
55 tool. 62 tool.
56 63
57 ]]> 64 ]]>
58 65
59 </help> 66 </help>
60 <expand macro="bunwarpj_citations" /> 67 <expand macro="bunwarpj_citations"/>
61 </tool> 68 </tool>