Repository 'icqsol_add_texture'
hg clone https://toolshed.g2.bx.psu.edu/repos/iuc/icqsol_add_texture

Changeset 0:d6bbaddfa5af (2016-08-23)
Commit message:
Uploaded
added:
icqsol_add_texture.py
icqsol_add_texture.xml
icqsol_macros.xml
icqsol_utils.py
test-data/sandstone.jpg
test-data/shaft.vtkascii
test-data/shaft_with_texture.vtkascii
b
diff -r 000000000000 -r d6bbaddfa5af icqsol_add_texture.py
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/icqsol_add_texture.py Tue Aug 23 14:55:34 2016 -0400
b
@@ -0,0 +1,44 @@
+#!/usr/bin/env python
+import argparse
+import shutil
+
+import icqsol_utils
+
+# Parse Command Line.
+parser = argparse.ArgumentParser()
+parser.add_argument('--input', dest='input', help='Shape dataset selected from history')
+parser.add_argument('--input_file_format_and_type', dest='input_file_format_and_type', help='Input file format and type')
+parser.add_argument('--input_dataset_type', dest='input_dataset_type', help='Input dataset_type')
+parser.add_argument('--input_texture', dest='input_texture', help='Image dataset selected from history')
+parser.add_argument('--input_texture_file_format', dest='input_texture_file_format', help='Input texture file format')
+parser.add_argument('--max_edge_length', dest='max_edge_length', type=float, default=float('inf'), help='Maximum edge length')
+parser.add_argument('--output', dest='output', help='Output dataset')
+parser.add_argument('--output_vtk_type', dest='output_vtk_type', help='Output VTK type')
+
+args = parser.parse_args()
+
+input_format, input_file_type = icqsol_utils.get_format_and_type(args.input_file_format_and_type)
+tmp_dir = icqsol_utils.get_temp_dir()
+
+# Instantiate a ShapeManager for loading the input.
+shape_mgr = icqsol_utils.get_shape_manager(input_format, args.input_dataset_type)
+
+# Get the vtk polydata from the input dataset.
+vtk_poly_data = shape_mgr.loadAsVtkPolyData(args.input)
+
+# Apply the texture to the shape's surface.
+vtk_poly_data = shape_mgr.addTextureToVtkPolyData(vtk_poly_data,
+                                                  texture_file=args.input_texture,
+                                                  max_edge_length=args.max_edge_length,
+                                                  texture_file_format=args.input_texture_file_format)
+
+# Define the output file format and type (the output_format can only be 'vtk').
+output_format, output_file_type = icqsol_utils.get_format_and_type(args.output_vtk_type)
+tmp_output_path = icqsol_utils.get_temporary_file_path(tmp_dir, output_format)
+
+# Make sure the ShapeManager's writer is vtk.
+shape_mgr.setWriter(file_format=icqsol_utils.VTK, vtk_dataset_type=icqsol_utils.POLYDATA)
+
+# Save the output.
+shape_mgr.saveVtkPolyData(vtk_poly_data=vtk_poly_data, file_name=tmp_output_path, file_type=output_file_type)
+shutil.move(tmp_output_path, args.output)
b
diff -r 000000000000 -r d6bbaddfa5af icqsol_add_texture.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/icqsol_add_texture.xml Tue Aug 23 14:55:34 2016 -0400
[
@@ -0,0 +1,74 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<tool id="icqsol_add_texture" name="Add texture" version="@WRAPPER_VERSION@.0">
+    <description>to shape</description>
+    <macros>
+        <import>icqsol_macros.xml</import>
+    </macros>
+    <expand macro="requirements" />
+    <command>
+        <![CDATA[
+            python $__tool_directory__/icqsol_add_texture.py
+            --input "$input"
+            --input_file_format_and_type $input.ext
+            --input_dataset_type $input.metadata.dataset_type
+            --input_texture "$input_texture"
+            --input_texture_file_format $input_texture.ext
+            #if $refine_shape_cond.refine_shape == "yes":
+                --max_edge_length $refine_shape_cond.max_edge_length
+            #end if
+            --output "$output"
+            --output_vtk_type $output_vtk_type
+        ]]>
+    </command>
+    <inputs>
+        <param name="input" type="data" format="vtkascii,vtkbinary" label="Shape" help="Format can be vtkascii or vtkbinary." />
+        <param name="input_texture" type="data" format="jpg,png" label="Texture image" help="Format can be jpg or png." />
+        <conditional name="refine_shape_cond">
+            <param name="refine_shape" type="select" label="Refine shape?" help="Points will be added to the shape's edges restricting their length to the maximum.">
+                <option value="no" selected="True">No</option>
+                <option value="yes">Yes</option>
+            </param>
+            <when value="no" />
+            <when value="yes">
+                <param name="max_edge_length" type="float" value="0.1" label="Maximum edge length" help="Refine shape by restricting edges to this length.">
+                    <validator type="in_range" min="0" exclude_min="true" />
+                </param>
+            </when>
+        </conditional>
+        <expand macro="output_vtk_type_params" />
+    </inputs>
+    <outputs>
+        <data name="output" format="vtkascii">
+            <actions>
+                <action type="format">
+                    <option type="from_param" name="output_vtk_type" />
+                </action>
+            </actions>
+        </data>
+    </outputs>
+    <tests>
+        <test>
+            <param name="input" value="shaft.vtkascii" ftype="vtkascii" />
+            <param name="input_file_format_and_type" value="vtkascii" />
+            <param name="input_dataset_type" value="POLYDATA" />
+            <param name="input_texture" value="sandstone.jpg" />
+            <param name="refine_shape" value="yes" />
+            <param name="max_edge_length" value="0.1" />
+            <output name="output" file="shaft_with_texture.vtkascii" ftype="vtkascii" />
+            <param name="output_vtk_type" value="vtkascii" />
+        </test>
+    </tests>
+    <help>
+**What it does**
+
+Adds a texture by applying an image to the surface of a shape.  The shape is projected onto a bounding box
+and the color is selected by flattening the box to fit the image.  Refinement can be applied for a smoother
+result.
+
+* **Shape** - Shape for applying a surface texture.
+* **Maximum edge length** - The shape's edges are smoothed by adding points to its edges that are longer than the defined maximum length.
+* **Texture image** - Image to be applied to the shape's surface to create the texture.
+
+    </help>
+    <expand macro="citations" />
+</tool>
b
diff -r 000000000000 -r d6bbaddfa5af icqsol_macros.xml
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/icqsol_macros.xml Tue Aug 23 14:55:34 2016 -0400
b
@@ -0,0 +1,116 @@
+<?xml version='1.0' encoding='UTF-8'?>
+<macros>
+    <token name="@WRAPPER_VERSION@">1.0</token>
+    <xml name="requirements">
+        <requirements>
+            <requirement type="package" version="0.3.26">icqsol</requirement>
+        </requirements>
+    </xml>
+    <xml name="stdio">
+        <stdio>
+            <exit_code range="1:"/>
+            <exit_code range=":-1"/>
+            <regex match="Error:"/>
+            <regex match="Exception:"/>
+        </stdio>
+    </xml>
+    <!-- TODO: place this in colormaps_conf.xml -->
+    <xml name="color_map_param">
+        <param name="color_map" type="select" label="Color map">
+            <option value="hot" selected="True">Hot</option>
+            <option value="cold">Cold</option>
+            <option value="blackbody">Blackbody</option>
+            <option value="gnu">Gnu</option>
+        </param>
+    </xml>
+    <xml name="output_vtk_type_params">
+        <param name="output_vtk_type" type="select" label="Output file type">
+            <option value="vtkascii" selected="True">Vtk-ascii</option>
+            <option value="vtkbinary">Vtk-binary</option>
+        </param>
+    </xml>
+    <token name="@origin_cmd_args@">
+        --origin_x $create_process_cond.shape_cond.origin_x
+        --origin_y $create_process_cond.shape_cond.origin_y
+        --origin_z $create_process_cond.shape_cond.origin_z
+    </token>
+    <xml name="origin_params">
+        <param name="origin_x" type="float" value="0.0" label="X coordinate of origin" help="Floating point number"/>
+        <param name="origin_y" type="float" value="0.0" label="Y coordinate of origin" help="Floating point number"/>
+        <param name="origin_z" type="float" value="0.0" label="Z coordinate of origin" help="Floating point number"/>
+    </xml>
+    <token name="@lengths_cmd_args@">
+        --length_x $create_process_cond.shape_cond.length_x
+        --length_y $create_process_cond.shape_cond.length_y
+        --length_z $create_process_cond.shape_cond.length_z
+    </token>
+    <xml name="lengths_params">
+        <!-- At least one of these lengths must be greater than zero, but we have no validator for this. -->
+        <param name="length_x" type="float" value="1.0" label="Length in the X direction" help="Floating point number">
+            <validator type="in_range" min="0" exclude_min="false" />
+        </param>
+        <param name="length_y" type="float" value="0.0" label="Length in the Y direction" help="Floating point number">
+            <validator type="in_range" min="0" exclude_min="false" />
+        </param>
+        <param name="length_z" type="float" value="0.0" label="Length in the Z direction" help="Floating point number">
+            <validator type="in_range" min="0" exclude_min="false" />
+        </param>
+    </xml>
+    <xml name="lengths_exclude_min_params">
+        <param name="length_x" type="float" value="1.0" label="Length in the X direction" help="Floating point number">
+            <validator type="in_range" min="0" exclude_min="true" />
+        </param>
+        <param name="length_y" type="float" value="1.0" label="Length in the Y direction" help="Floating point number">
+            <validator type="in_range" min="0" exclude_min="true" />
+        </param>
+        <param name="length_z" type="float" value="1.0" label="Length in the Z direction" help="Floating point number">
+            <validator type="in_range" min="0" exclude_min="true" />
+        </param>
+    </xml>
+    <token name="@radius_cmd_args@">
+        --radius $create_process_cond.shape_cond.radius
+    </token>
+    <xml name="radius_params">
+        <param name="radius" type="float" value="1.0" label="Radius" help="Floating point number">
+            <validator type="in_range" min="0" exclude_min="True" />
+        </param>
+    </xml>
+    <token name="@n_theta_cmd_args@">
+        --n_theta $create_process_cond.shape_cond.n_theta
+    </token>
+    <xml name="n_theta_params">
+        <param name="n_theta" type="integer" value="16" label="Number of slices" help="Controls the tessellation along the longitude direction">
+            <validator type="in_range" min="0" exclude_min="False" />
+        </param>
+    </xml>
+    <token name="@n_phi_cmd_args@">
+        --n_phi $create_process_cond.shape_cond.n_phi
+    </token>
+    <xml name="n_phi_params">
+        <param name="n_phi" type="integer" value="8" label="Number of stacks" help="Controls the tessellation along the latitude direction">
+            <validator type="in_range" min="0" exclude_min="False" />
+        </param>
+    </xml>
+    <xml name="citations">
+        <citations>
+            <citation type="bibtex">
+                @unpublished{None,
+                author = {None},
+                title = {None},
+                year = {None},
+                eprint = {None},
+                url = {https://github.com/gregvonkuster/galaxy-csg}
+            }</citation>
+            <citation type="bibtex">
+                @misc(Schroeder-Martin-Lorensen2006,
+                author = "Will Schroeder and 
+                          Ken Martin and
+                          Bill Lorensen",
+                year = "2006",
+                title = "The Visualization Toolkit (4th ed.)",
+                publisher =  "Kitware",
+                url = "https://en.wikipedia.org/wiki/Special:BookSources/978-1-930934-19-1")
+            </citation>
+        </citations>
+    </xml>
+</macros>
b
diff -r 000000000000 -r d6bbaddfa5af icqsol_utils.py
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/icqsol_utils.py Tue Aug 23 14:55:34 2016 -0400
[
@@ -0,0 +1,86 @@
+import os
+import sys
+import tempfile
+
+from icqsol.shapes.icqShapeManager import ShapeManager
+from icqsol.bem.icqLaplaceSolver import LaplaceSolver
+
+PLY = 'ply'
+POLYDATA = 'POLYDATA'
+VTK = 'vtk'
+
+
+def asbool(val):
+    return str(val).lower() in ['yes', 'true']
+
+
+def get_format_and_type(galaxy_ext):
+    # Define the output file format and type.
+    format = None
+    datatype = None
+    if galaxy_ext in ['vtkascii', 'vtkbinary']:
+        format = VTK
+    elif galaxy_ext in ['plyascii', 'plybinary']:
+        format = PLY
+    if galaxy_ext in ['vtkascii', 'plyascii']:
+        datatype = 'ascii'
+    elif galaxy_ext in ['vtkbinary', 'plybinary']:
+        datatype = 'binary'
+    return format, datatype
+
+
+def get_input_file_path(tmp_dir, input_file, format):
+    """
+    iCqSol uses file extensions (e.g., .ply, .vtk) when reading and
+    writing files, so the Galaxy dataset naming convention of
+    setting all file extensions as .dat must be handled.
+    """
+    file_path = get_temporary_file_path(tmp_dir, format)
+    # Remove the file so we can create a symlink.
+    os.remove(file_path)
+    os.symlink(input_file, file_path)
+    return file_path
+
+
+def get_laplace_solver(shape_data, max_edge_length=float('inf')):
+    return LaplaceSolver(shape_data, max_edge_length=max_edge_length)
+
+
+def get_shape_manager(format=None, dataset_type=None):
+    # Instantiate a ShapeManager.
+    return ShapeManager(file_format=format, vtk_dataset_type=dataset_type)
+
+
+def get_temp_dir(prefix='tmp-vtk-', dir=None):
+    """
+    Return a temporary directory.
+    """
+    return tempfile.mkdtemp(prefix=prefix, dir=dir)
+
+
+def get_tempfilename(dir=None, suffix=None):
+    """
+    Return a temporary file name.
+    """
+    if suffix is None:
+        s = None
+    elif suffix.startswith('.'):
+        s = suffix
+    else:
+        s = '.%s' % suffix
+    fd, name = tempfile.mkstemp(suffix=s, dir=dir)
+    os.close(fd)
+    return name
+
+
+def get_temporary_file_path(tmp_dir, file_extension):
+    """
+    Return the path to a temporary file with a valid VTK format
+    file extension.
+    """
+    return get_tempfilename(tmp_dir, file_extension)
+
+
+def stop_err(msg):
+    sys.stderr.write("%s\n" % msg)
+    sys.exit()
b
diff -r 000000000000 -r d6bbaddfa5af test-data/sandstone.jpg
b
Binary file test-data/sandstone.jpg has changed
b
diff -r 000000000000 -r d6bbaddfa5af test-data/shaft.vtkascii
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/shaft.vtkascii Tue Aug 23 14:55:34 2016 -0400
b
@@ -0,0 +1,103 @@
+# vtk DataFile Version 4.0
+vtk output
+ASCII
+DATASET POLYDATA
+POINTS 66 float
+0 0 0 0 0 -0.1 0 -0.0382683 -0.092388 
+1 0 -0.1 1 -0.0382683 -0.092388 1 0 0 
+0 -0.0707107 -0.0707107 1 -0.0707107 -0.0707107 0 -0.092388 -0.0382683 
+1 -0.092388 -0.0382683 0 -0.1 0 1 -0.1 0 
+0 -0.092388 0.0382683 1 -0.092388 0.0382683 0 -0.0707107 0.0707107 
+1 -0.0707107 0.0707107 0 -0.0382683 0.092388 1 -0.0382683 0.092388 
+0 0 0.1 1 0 0.1 0 0.0382683 0.092388 
+1 0.0382683 0.092388 0 0.0707107 0.0707107 1 0.0707107 0.0707107 
+0 0.092388 0.0382683 1 0.092388 0.0382683 0 0.1 0 
+1 0.1 0 0 0.092388 -0.0382683 1 0.092388 -0.0382683 
+0 0.0707107 -0.0707107 1 0.0707107 -0.0707107 0 0.0382683 -0.092388 
+1 0.0382683 -0.092388 0 0 -0.1 0 -0.0382683 -0.092388 
+1 0 -0.1 1 -0.0382683 -0.092388 0 -0.0707107 -0.0707107 
+1 -0.0707107 -0.0707107 0 -0.092388 -0.0382683 1 -0.092388 -0.0382683 
+0 -0.1 0 1 -0.1 0 0 -0.092388 0.0382683 
+1 -0.092388 0.0382683 0 -0.0707107 0.0707107 1 -0.0707107 0.0707107 
+0 -0.0382683 0.092388 1 -0.0382683 0.092388 0 0 0.1 
+1 0 0.1 0 0.0382683 0.092388 1 0.0382683 0.092388 
+0 0.0707107 0.0707107 1 0.0707107 0.0707107 0 0.092388 0.0382683 
+1 0.092388 0.0382683 0 0.1 0 1 0.1 0 
+0 0.092388 -0.0382683 1 0.092388 -0.0382683 0 0.0707107 -0.0707107 
+1 0.0707107 -0.0707107 0 0.0382683 -0.092388 1 0.0382683 -0.092388 
+
+POLYGONS 48 208
+3 0 1 2 
+4 35 34 3 4 
+3 5 37 36 
+3 0 2 6 
+4 38 35 4 7 
+3 5 39 37 
+3 0 6 8 
+4 40 38 7 9 
+3 5 41 39 
+3 0 8 10 
+4 42 40 9 11 
+3 5 43 41 
+3 0 10 12 
+4 44 42 11 13 
+3 5 45 43 
+3 0 12 14 
+4 46 44 13 15 
+3 5 47 45 
+3 0 14 16 
+4 48 46 15 17 
+3 5 49 47 
+3 0 16 18 
+4 50 48 17 19 
+3 5 51 49 
+3 0 18 20 
+4 52 50 19 21 
+3 5 53 51 
+3 0 20 22 
+4 54 52 21 23 
+3 5 55 53 
+3 0 22 24 
+4 56 54 23 25 
+3 5 57 55 
+3 0 24 26 
+4 58 56 25 27 
+3 5 59 57 
+3 0 26 28 
+4 60 58 27 29 
+3 5 61 59 
+3 0 28 30 
+4 62 60 29 31 
+3 5 63 61 
+3 0 30 32 
+4 64 62 31 33 
+3 5 65 63 
+3 0 32 1 
+4 34 64 33 3 
+3 5 36 65 
+
+POINT_DATA 66
+NORMALS Normals float
+-1 0 0 -1 0 0 -1 0 0 
+0 0 -1 0 -0.382683 -0.92388 1 0 0 
+-1 0 0 0 -0.707107 -0.707107 -1 0 0 
+0 -0.92388 -0.382683 -1 0 0 0 -1 0 
+-1 0 0 0 -0.92388 0.382683 -1 0 0 
+0 -0.707107 0.707107 -1 0 0 0 -0.382683 0.92388 
+-1 0 0 0 0 1 -1 0 0 
+0 0.382683 0.92388 -1 0 0 0 0.707107 0.707107 
+-1 0 0 0 0.92388 0.382683 -1 0 0 
+0 1 0 -1 0 0 0 0.92388 -0.382683 
+-1 0 0 0 0.707107 -0.707107 -1 0 0 
+0 0.382683 -0.92388 0 0 -1 0 -0.382683 -0.92388 
+1 0 0 1 0 0 0 -0.707107 -0.707107 
+1 0 0 0 -0.92388 -0.382683 1 0 0 
+0 -1 0 1 0 0 0 -0.92388 0.382683 
+1 0 0 0 -0.707107 0.707107 1 0 0 
+0 -0.382683 0.92388 1 0 0 0 0 1 
+1 0 0 0 0.382683 0.92388 1 0 0 
+0 0.707107 0.707107 1 0 0 0 0.92388 0.382683 
+1 0 0 0 1 0 1 0 0 
+0 0.92388 -0.382683 1 0 0 0 0.707107 -0.707107 
+1 0 0 0 0.382683 -0.92388 1 0 0 
+
b
diff -r 000000000000 -r d6bbaddfa5af test-data/shaft_with_texture.vtkascii
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/test-data/shaft_with_texture.vtkascii Tue Aug 23 14:55:34 2016 -0400
b
b'@@ -0,0 +1,709 @@\n+# vtk DataFile Version 4.0\n+vtk output\n+ASCII\n+DATASET POLYDATA\n+POINTS 242 float\n+0 0 0 0 0 -0.1 0 -0.0382683 -0.092388 \n+1 0 -0.1 1 -0.0382683 -0.092388 1 0 0 \n+0 -0.0707107 -0.0707107 1 -0.0707107 -0.0707107 0 -0.092388 -0.0382683 \n+1 -0.092388 -0.0382683 0 -0.1 0 1 -0.1 0 \n+0 -0.092388 0.0382683 1 -0.092388 0.0382683 0 -0.0707107 0.0707107 \n+1 -0.0707107 0.0707107 0 -0.0382683 0.092388 1 -0.0382683 0.092388 \n+0 0 0.1 1 0 0.1 0 0.0382683 0.092388 \n+1 0.0382683 0.092388 0 0.0707107 0.0707107 1 0.0707107 0.0707107 \n+0 0.092388 0.0382683 1 0.092388 0.0382683 0 0.1 0 \n+1 0.1 0 0 0.092388 -0.0382683 1 0.092388 -0.0382683 \n+0 0.0707107 -0.0707107 1 0.0707107 -0.0707107 0 0.0382683 -0.092388 \n+1 0.0382683 -0.092388 0 0 -0.1 0 -0.0382683 -0.092388 \n+1 0 -0.1 1 -0.0382683 -0.092388 0 -0.0707107 -0.0707107 \n+1 -0.0707107 -0.0707107 0 -0.092388 -0.0382683 1 -0.092388 -0.0382683 \n+0 -0.1 0 1 -0.1 0 0 -0.092388 0.0382683 \n+1 -0.092388 0.0382683 0 -0.0707107 0.0707107 1 -0.0707107 0.0707107 \n+0 -0.0382683 0.092388 1 -0.0382683 0.092388 0 0 0.1 \n+1 0 0.1 0 0.0382683 0.092388 1 0.0382683 0.092388 \n+0 0.0707107 0.0707107 1 0.0707107 0.0707107 0 0.092388 0.0382683 \n+1 0.092388 0.0382683 0 0.1 0 1 0.1 0 \n+0 0.092388 -0.0382683 1 0.092388 -0.0382683 0 0.0707107 -0.0707107 \n+1 0.0707107 -0.0707107 0 0.0382683 -0.092388 1 0.0382683 -0.092388 \n+0 0 -0.05 0 -0.0191342 -0.046194 0.1 0 -0.1 \n+0.2 0 -0.1 0.3 0 -0.1 0.4 0 -0.1 \n+0.5 0 -0.1 0.6 0 -0.1 0.7 0 -0.1 \n+0.8 0 -0.1 0.9 0 -0.1 0.9 -0.0382683 -0.092388 \n+0.8 -0.0382683 -0.092388 0.7 -0.0382683 -0.092388 0.6 -0.0382683 -0.092388 \n+0.5 -0.0382683 -0.092388 0.4 -0.0382683 -0.092388 0.3 -0.0382683 -0.092388 \n+0.2 -0.0382683 -0.092388 0.1 -0.0382683 -0.092388 1 -0.0191342 -0.046194 \n+1 0 -0.05 0 -0.0353553 -0.0353553 0.9 -0.0707107 -0.0707107 \n+0.8 -0.0707107 -0.0707107 0.7 -0.0707107 -0.0707107 0.6 -0.0707107 -0.0707107 \n+0.5 -0.0707107 -0.0707107 0.4 -0.0707107 -0.0707107 0.3 -0.0707107 -0.0707107 \n+0.2 -0.0707107 -0.0707107 0.1 -0.0707107 -0.0707107 1 -0.0353553 -0.0353553 \n+0 -0.046194 -0.0191342 0.9 -0.092388 -0.0382683 0.8 -0.092388 -0.0382683 \n+0.7 -0.092388 -0.0382683 0.6 -0.092388 -0.0382683 0.5 -0.092388 -0.0382683 \n+0.4 -0.092388 -0.0382683 0.3 -0.092388 -0.0382683 0.2 -0.092388 -0.0382683 \n+0.1 -0.092388 -0.0382683 1 -0.046194 -0.0191342 0 -0.05 0 \n+0.9 -0.1 0 0.8 -0.1 0 0.7 -0.1 0 \n+0.6 -0.1 0 0.5 -0.1 0 0.4 -0.1 0 \n+0.3 -0.1 0 0.2 -0.1 0 0.1 -0.1 0 \n+1 -0.05 0 0 -0.046194 0.0191342 0.9 -0.092388 0.0382683 \n+0.8 -0.092388 0.0382683 0.7 -0.092388 0.0382683 0.6 -0.092388 0.0382683 \n+0.5 -0.092388 0.0382683 0.4 -0.092388 0.0382683 0.3 -0.092388 0.0382683 \n+0.2 -0.092388 0.0382683 0.1 -0.092388 0.0382683 1 -0.046194 0.0191342 \n+0 -0.0353553 0.0353553 0.9 -0.0707107 0.0707107 0.8 -0.0707107 0.0707107 \n+0.7 -0.0707107 0.0707107 0.6 -0.0707107 0.0707107 0.5 -0.0707107 0.0707107 \n+0.4 -0.0707107 0.0707107 0.3 -0.0707107 0.0707107 0.2 -0.0707107 0.0707107 \n+0.1 -0.0707107 0.0707107 1 -0.0353553 0.0353553 0 -0.0191342 0.046194 \n+0.9 -0.0382683 0.092388 0.8 -0.0382683 0.092388 0.7 -0.0382683 0.092388 \n+0.6 -0.0382683 0.092388 0.5 -0.0382683 0.092388 0.4 -0.0382683 0.092388 \n+0.3 -0.0382683 0.092388 0.2 -0.0382683 0.092388 0.1 -0.0382683 0.092388 \n+1 -0.0191342 0.046194 0 0 0.05 0.9 0 0.1 \n+0.8 0 0.1 0.7 0 0.1 0.6 0 0.1 \n+0.5 0 0.1 0.4 0 0.1 0.3 0 0.1 \n+0.2 0 0.1 0.1 0 0.1 1 0 0.05 \n+0 0.0191342 0.046194 0.9 0.0382683 0.092388 0.8 0.0382683 0.092388 \n+0.7 0.0382683 0.092388 0.6 0.0382683 0.092388 0.5 0.0382683 0.092388 \n+0.4 0.0382683 0.092388 0.3 0.0382683 0.092388 0.2 0.0382683 0.092388 \n+0.1 0.0382683 0.092388 1 0.0191342 0.046194 0 0.0353553 0.0353553 \n+0.9 0.0707107 0.0707107 0.8 0.0707107 0.0707107 0.7 0.0707107 0.0707107 \n+0.6 0.0707107 0.0707107 0.5 0.0707107 0.0707107 0.4 0.0707107 0.0707107 \n+0.3 0.0707107 0.0707107 0.2 0.0707107 0.0707107 0.1 0.0707107 0.0707107 \n+1 0.0353553 0.0353553 0 0.046194 0.0191342 0.9 0.092388 0.0382683 \n+0.8 0.092388 0.0382683 0.7 0.092388 0'..b'58776 -0.752339 -1 0 0 \n+0 -0.896538 -0.442967 -1 0 0 0 -0.997809 -0.0661586 \n+-1 0 0 0 -0.947174 0.320722 -1 0 0 \n+0 -0.752339 0.658776 -1 0 0 0 -0.442967 0.896538 \n+-1 0 0 0 -0.0661586 0.997809 -1 0 0 \n+0 0.320722 0.947174 -1 0 0 0 0.658776 0.752339 \n+-1 0 0 0 0.896538 0.442967 -1 0 0 \n+0 0.997809 0.0661586 -1 0 0 0 0.947174 -0.320722 \n+-1 0 0 0 0.752339 -0.658776 -1 0 0 \n+0 0.442967 -0.896538 0 -0.0661586 -0.997809 0 -0.442967 -0.896538 \n+1 0 0 1 0 0 0 -0.752339 -0.658776 \n+1 0 0 0 -0.947174 -0.320722 1 0 0 \n+0 -0.997809 0.0661586 1 0 0 0 -0.896538 0.442967 \n+1 0 0 0 -0.658776 0.752339 1 0 0 \n+0 -0.320722 0.947174 1 0 0 0 0.0661586 0.997809 \n+1 0 0 0 0.442967 0.896538 1 0 0 \n+0 0.752339 0.658776 1 0 0 0 0.947174 0.320722 \n+1 0 0 0 0.997809 -0.0661586 1 0 0 \n+0 0.896538 -0.442967 1 0 0 0 0.658776 -0.752339 \n+1 0 0 0 0.320722 -0.947174 1 0 0 \n+-1 0 0 -1 0 0 0 -5.06436e-09 -1 \n+0 -5.06436e-09 -1 0 -5.06436e-09 -1 0 -5.06436e-09 -1 \n+0 -5.06436e-09 -1 0 -5.06436e-09 -1 0 -5.06436e-09 -1 \n+0 -5.06436e-09 -1 0 -5.06436e-09 -1 0 -0.382683 -0.92388 \n+0 -0.382683 -0.92388 0 -0.382683 -0.92388 0 -0.382683 -0.92388 \n+0 -0.382683 -0.92388 0 -0.382683 -0.92388 0 -0.382683 -0.92388 \n+0 -0.382683 -0.92388 0 -0.382683 -0.92388 1 0 0 \n+1 0 0 -1 0 0 0 -0.707107 -0.707107 \n+0 -0.707107 -0.707107 0 -0.707107 -0.707107 0 -0.707107 -0.707107 \n+0 -0.707107 -0.707107 0 -0.707107 -0.707107 0 -0.707107 -0.707107 \n+0 -0.707107 -0.707107 0 -0.707107 -0.707107 1 0 0 \n+-1 0 0 0 -0.92388 -0.382683 0 -0.92388 -0.382683 \n+0 -0.92388 -0.382683 0 -0.92388 -0.382683 0 -0.92388 -0.382683 \n+0 -0.92388 -0.382683 0 -0.92388 -0.382683 0 -0.92388 -0.382683 \n+0 -0.92388 -0.382683 1 0 0 -1 0 0 \n+0 -1 -5.06436e-09 0 -1 -5.06436e-09 0 -1 -5.06436e-09 \n+0 -1 -5.06436e-09 0 -1 -5.06436e-09 0 -1 -5.06436e-09 \n+0 -1 -5.06436e-09 0 -1 -5.06436e-09 0 -1 -5.06436e-09 \n+1 0 0 -1 0 0 0 -0.92388 0.382683 \n+0 -0.92388 0.382683 0 -0.92388 0.382683 0 -0.92388 0.382683 \n+0 -0.92388 0.382683 0 -0.92388 0.382683 0 -0.92388 0.382683 \n+0 -0.92388 0.382683 0 -0.92388 0.382683 1 0 0 \n+-1 0 0 0 -0.707107 0.707107 0 -0.707107 0.707107 \n+0 -0.707107 0.707107 0 -0.707107 0.707107 0 -0.707107 0.707107 \n+0 -0.707107 0.707107 0 -0.707107 0.707107 0 -0.707107 0.707107 \n+0 -0.707107 0.707107 1 0 0 -1 0 0 \n+0 -0.382683 0.92388 0 -0.382683 0.92388 0 -0.382683 0.92388 \n+0 -0.382683 0.92388 0 -0.382683 0.92388 0 -0.382683 0.92388 \n+0 -0.382683 0.92388 0 -0.382683 0.92388 0 -0.382683 0.92388 \n+1 0 0 -1 0 0 0 -5.06436e-09 1 \n+0 -5.06436e-09 1 0 -5.06436e-09 1 0 -5.06436e-09 1 \n+0 -5.06436e-09 1 0 -5.06436e-09 1 0 -5.06436e-09 1 \n+0 -5.06436e-09 1 0 -5.06436e-09 1 1 0 0 \n+-1 0 0 0 0.382683 0.92388 0 0.382683 0.92388 \n+0 0.382683 0.92388 0 0.382683 0.92388 0 0.382683 0.92388 \n+0 0.382683 0.92388 0 0.382683 0.92388 0 0.382683 0.92388 \n+0 0.382683 0.92388 1 0 0 -1 0 0 \n+0 0.707107 0.707107 0 0.707107 0.707107 0 0.707107 0.707107 \n+0 0.707107 0.707107 0 0.707107 0.707107 0 0.707107 0.707107 \n+0 0.707107 0.707107 0 0.707107 0.707107 0 0.707107 0.707107 \n+1 0 0 -1 0 0 0 0.92388 0.382683 \n+0 0.92388 0.382683 0 0.92388 0.382683 0 0.92388 0.382683 \n+0 0.92388 0.382683 0 0.92388 0.382683 0 0.92388 0.382683 \n+0 0.92388 0.382683 0 0.92388 0.382683 1 0 0 \n+-1 0 0 0 1 5.06436e-09 0 1 5.06436e-09 \n+0 1 5.06436e-09 0 1 5.06436e-09 0 1 5.06436e-09 \n+0 1 5.06436e-09 0 1 5.06436e-09 0 1 5.06436e-09 \n+0 1 5.06436e-09 1 0 0 -1 0 0 \n+0 0.92388 -0.382683 0 0.92388 -0.382683 0 0.92388 -0.382683 \n+0 0.92388 -0.382683 0 0.92388 -0.382683 0 0.92388 -0.382683 \n+0 0.92388 -0.382683 0 0.92388 -0.382683 0 0.92388 -0.382683 \n+1 0 0 -1 0 0 0 0.707107 -0.707107 \n+0 0.707107 -0.707107 0 0.707107 -0.707107 0 0.707107 -0.707107 \n+0 0.707107 -0.707107 0 0.707107 -0.707107 0 0.707107 -0.707107 \n+0 0.707107 -0.707107 0 0.707107 -0.707107 1 0 0 \n+-1 0 0 0 0.382683 -0.92388 0 0.382683 -0.92388 \n+0 0.382683 -0.92388 0 0.382683 -0.92388 0 0.382683 -0.92388 \n+0 0.382683 -0.92388 0 0.382683 -0.92388 0 0.382683 -0.92388 \n+0 0.382683 -0.92388 1 0 0 \n'