diff icqsol_coarsen_shape.xml @ 0:6ff7cf6ec553 draft default tip

Uploaded
author iuc
date Tue, 23 Aug 2016 14:56:49 -0400
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/icqsol_coarsen_shape.xml	Tue Aug 23 14:56:49 2016 -0400
@@ -0,0 +1,57 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<tool id="icqsol_coarsen_shape" name="Coarsen shape" version="@WRAPPER_VERSION@.0">
+    <description></description>
+    <macros>
+        <import>icqsol_macros.xml</import>
+    </macros>
+    <expand macro="requirements" />
+    <command>
+        <![CDATA[
+            python $__tool_directory__/icqsol_coarsen_shape.py
+            --input "$input"
+            --input_file_format_and_type $input.ext
+            --input_dataset_type $input.metadata.dataset_type
+            --min_cell_area $min_cell_area
+            --output "$output"
+            --output_vtk_type $output_vtk_type
+        ]]>
+    </command>
+    <inputs>
+        <param name="input" type="data" format="plyascii,plybinary,vtkascii,vtkbinary" label="Shape">
+            <validator type="dataset_ok_validator" />
+        </param>
+        <param name="min_cell_area" type="float" value="0.5" label="Minimum cell area" help="Coarsen shape by ensuring that cell area are bigger than a given tolerance (except at the edge of the domain).">
+            <validator type="in_range" min="0" exclude_min="true" />
+        </param>
+        <expand macro="output_vtk_type_params" />
+    </inputs>
+    <outputs>
+        <data name="output" format="vtkascii" label="${tool.name} ${on_string} Min cell area: ${min_cell_area}">
+            <actions>
+                <action type="format">
+                    <option type="from_param" name="output_vtk_type" />
+                </action>
+            </actions>
+        </data>
+    </outputs>
+    <tests>
+        <test>
+            <param name="input" value="box_refined_with_surface_field.vtkascii" ftype="vtkascii" />
+            <param name="input_file_format_and_type" value="vtkascii" />
+            <param name="input_dataset_type" value="POLYDATA" />
+            <param name="min_cell_area" value="0.5" />
+            <output name="output" file="box_coarsened.vtkascii" ftype="vtkascii" />
+            <param name="output_vtk_type" value="vtkascii" />
+        </test>
+    </tests>
+    <help>
+**What it does**
+
+Coarsens a shape by ensuring that cells are larger than a given tolerance, resulting in a less detailed shape.
+
+* **Shape** - Shape to be coarsened.
+* **Minimum cell area** - The shape's cells that have area smaller than this number will be merged.
+
+    </help>
+    <expand macro="citations" />
+</tool>