From 61c93bdbf42e5f35ab8648d65fbba8cf1bf8e5e9 Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Thu, 12 May 2016 08:54:34 +0200 Subject: [PATCH 1/3] adjusted help message for automated documentation --- processing/pre/abq_addUserOutput.py | 2 +- processing/pre/geom_addPrimitive.py | 2 +- processing/pre/geom_canvas.py | 2 +- processing/pre/geom_clean.py | 2 +- processing/pre/geom_fromMinimalSurface.py | 2 +- processing/pre/geom_fromOsteonGeometry.py | 2 +- processing/pre/geom_fromTable.py | 2 +- processing/pre/geom_fromVoronoiTessellation.py | 4 ++-- processing/pre/geom_grainGrowth.py | 2 +- processing/pre/geom_pack.py | 2 +- processing/pre/geom_rescale.py | 2 +- processing/pre/geom_rotate.py | 2 +- processing/pre/geom_toTable.py | 2 +- processing/pre/marc_addUserOutput.py | 2 +- 14 files changed, 15 insertions(+), 15 deletions(-) diff --git a/processing/pre/abq_addUserOutput.py b/processing/pre/abq_addUserOutput.py index de53fec9b..4528537d9 100755 --- a/processing/pre/abq_addUserOutput.py +++ b/processing/pre/abq_addUserOutput.py @@ -49,7 +49,7 @@ def ParseOutputFormat(filename,what,me): return format -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog [option(s)] Abaqus.Inputfile(s)', description = """ Transfer the output variables requested in the material.config to properly labelled user defined variables within the Abaqus input file (*.inp). diff --git a/processing/pre/geom_addPrimitive.py b/processing/pre/geom_addPrimitive.py index 05bcbed1d..8976a9e3d 100755 --- a/processing/pre/geom_addPrimitive.py +++ b/processing/pre/geom_addPrimitive.py @@ -27,7 +27,7 @@ mappings = { 'microstructures': lambda x: int(x), } -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog option(s) [geomfile(s)]', description = """ Positions a geometric object within the (three-dimensional) canvas of a spectral geometry description. Depending on the sign of the dimension parameters, these objects can be boxes, cylinders, or ellipsoids. diff --git a/processing/pre/geom_canvas.py b/processing/pre/geom_canvas.py index d5b11b6bb..4b482d641 100755 --- a/processing/pre/geom_canvas.py +++ b/processing/pre/geom_canvas.py @@ -13,7 +13,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN # -------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog option(s) [geomfile(s)]', description = """ Changes the (three-dimensional) canvas of a spectral geometry description. Grid can be given as absolute or relative values, e.g. 16 16 16 or 2x 0.5x 32. diff --git a/processing/pre/geom_clean.py b/processing/pre/geom_clean.py index 05d14cb79..1409a1366 100755 --- a/processing/pre/geom_clean.py +++ b/processing/pre/geom_clean.py @@ -18,7 +18,7 @@ def mostFrequent(arr): # MAIN #-------------------------------------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog option(s) [geomfile(s)]', description = """ Smooth geometry by selecting most frequent microstructure index within given stencil at each location. """, version=scriptID) diff --git a/processing/pre/geom_fromMinimalSurface.py b/processing/pre/geom_fromMinimalSurface.py index 5cc3c09ac..1c4fc2eaa 100755 --- a/processing/pre/geom_fromMinimalSurface.py +++ b/processing/pre/geom_fromMinimalSurface.py @@ -21,7 +21,7 @@ surface = { 'diamond': lambda x,y,z: math.cos(x-y)*math.cos(z)+math.sin(x+y)*math.sin(z), } -parser = OptionParser(option_class=damask.extendableOption, usage='%prog', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog [option(s)] [geomfile]', description = """ Generate a geometry file of a bicontinuous structure of given type. """, version = scriptID) diff --git a/processing/pre/geom_fromOsteonGeometry.py b/processing/pre/geom_fromOsteonGeometry.py index 4492d7291..9a24b3e2d 100755 --- a/processing/pre/geom_fromOsteonGeometry.py +++ b/processing/pre/geom_fromOsteonGeometry.py @@ -13,7 +13,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN # -------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog [options]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog [option(s)] [geomfile]', description = """ Generate a geometry file of an osteon enclosing the Harvesian canal and separated by interstitial tissue. The osteon phase is lamellar with a twisted plywood structure. Its fiber orientation is oscillating by +/- amplitude within one period. diff --git a/processing/pre/geom_fromTable.py b/processing/pre/geom_fromTable.py index df89ecd83..91b4c2670 100755 --- a/processing/pre/geom_fromTable.py +++ b/processing/pre/geom_fromTable.py @@ -15,7 +15,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN # -------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog option(s) [ASCIItable(s)]', description = """ Generate geometry description and material configuration from position, phase, and orientation (or microstructure) data. """, version = scriptID) diff --git a/processing/pre/geom_fromVoronoiTessellation.py b/processing/pre/geom_fromVoronoiTessellation.py index 23999e877..903124385 100755 --- a/processing/pre/geom_fromVoronoiTessellation.py +++ b/processing/pre/geom_fromVoronoiTessellation.py @@ -104,8 +104,8 @@ def laguerreTessellation(undeformed, coords, weights, grains, nonperiodic = Fals # MAIN # -------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ -Generate geometry description and material configuration by standard Voronoi tessellation of given seeds file. +parser = OptionParser(option_class=damask.extendableOption, usage='%prog option(s) [seedfile(s)]', description = """ +Generate geometry description and material configuration by tessellation of given seeds file. """, version = scriptID) diff --git a/processing/pre/geom_grainGrowth.py b/processing/pre/geom_grainGrowth.py index 0fd97e36a..6e4a7fc37 100755 --- a/processing/pre/geom_grainGrowth.py +++ b/processing/pre/geom_grainGrowth.py @@ -14,7 +14,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN #-------------------------------------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog [option(s)] [geomfile(s)]', description = """ Smoothens out interface roughness by simulated curvature flow. This is achieved by the diffusion of each initially sharply bounded grain volume within the periodic domain up to a given distance 'd' voxels. diff --git a/processing/pre/geom_pack.py b/processing/pre/geom_pack.py index c9b03f83b..324141aaa 100755 --- a/processing/pre/geom_pack.py +++ b/processing/pre/geom_pack.py @@ -13,7 +13,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN #-------------------------------------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog [geomfile(s)]', description = """ compress geometry files with ranges "a to b" and/or multiples "n of x". """, version = scriptID) diff --git a/processing/pre/geom_rescale.py b/processing/pre/geom_rescale.py index e37853e6b..2c779f3d3 100755 --- a/processing/pre/geom_rescale.py +++ b/processing/pre/geom_rescale.py @@ -13,7 +13,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN #-------------------------------------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [geomfile(s)]', description = """ Scales a geometry description independently in x, y, and z direction in terms of grid and/or size. Either absolute values or relative factors (like "0.25x") can be used. diff --git a/processing/pre/geom_rotate.py b/processing/pre/geom_rotate.py index 5788df60a..bb6acd35c 100755 --- a/processing/pre/geom_rotate.py +++ b/processing/pre/geom_rotate.py @@ -14,7 +14,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN #-------------------------------------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [file[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog options [geomfile(s)]', description = """ Rotates spectral geometry description. """, version=scriptID) diff --git a/processing/pre/geom_toTable.py b/processing/pre/geom_toTable.py index ff9cb653a..e858049d1 100755 --- a/processing/pre/geom_toTable.py +++ b/processing/pre/geom_toTable.py @@ -14,7 +14,7 @@ scriptID = ' '.join([scriptName,damask.version]) # MAIN #-------------------------------------------------------------------------------------------------- -parser = OptionParser(option_class=damask.extendableOption, usage='%prog [geomfile[s]]', description = """ +parser = OptionParser(option_class=damask.extendableOption, usage='%prog [geomfile(s)]', description = """ Translate geom description into ASCIItable containing 1/2/3_pos and microstructure. """, version = scriptID) diff --git a/processing/pre/marc_addUserOutput.py b/processing/pre/marc_addUserOutput.py index 8e86dbf8d..026029470 100755 --- a/processing/pre/marc_addUserOutput.py +++ b/processing/pre/marc_addUserOutput.py @@ -55,7 +55,7 @@ def ParseOutputFormat(filename,what,me): format['outputs'].append([output,length]) return format -parser = OptionParser(option_class=damask.extendableOption, usage='%prog [options] Marc.inputfile(s)', description=""" +parser = OptionParser(option_class=damask.extendableOption, usage='%prog [option(s)] Marc.Inputfile(s)', description=""" Transfer the output variables requested in the material.config to properly labelled user defined variables within the Marc input file (*.dat). From fa5ebdd46be9a8da7a2bd8b01ab8b0a53bb6c063 Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Fri, 13 May 2016 09:28:54 +0200 Subject: [PATCH 2/3] added correct metavar --- processing/post/mentat_colorMap.py | 33 +++++---- processing/post/postResults.py | 90 +++++++++++++----------- processing/post/vtk2ang.py | 29 +++++--- processing/post/vtk_addPointcloudData.py | 6 +- processing/post/vtk_rectilinearGrid.py | 1 + processing/pre/OIMlinear2linearODF.py | 3 +- processing/pre/geom_grainGrowth.py | 2 +- processing/pre/marc_addUserOutput.py | 10 ++- processing/pre/table_fromOIMgrainFile.py | 1 + 9 files changed, 102 insertions(+), 73 deletions(-) diff --git a/processing/post/mentat_colorMap.py b/processing/post/mentat_colorMap.py index e4b1ebeb0..79ea35a39 100755 --- a/processing/post/mentat_colorMap.py +++ b/processing/post/mentat_colorMap.py @@ -68,26 +68,29 @@ Interpolates colors between "lower_hsl" and "upper_hsl". """, version = scriptID) parser.add_option("-i","--inverse", action = "store_true", - dest = "inverse", \ - help = "invert legend [%default]") + dest = "inverse", + help = "invert legend") parser.add_option( "--palette", action = "store_true", - dest = "palette", \ - help = "output plain rgb palette integer values (0-255) [%default]") + dest = "palette", + help = "output plain rgb palette integer values (0-255)") parser.add_option( "--palettef", action = "store_true", - dest = "palettef", \ - help = "output plain rgb palette float values (0.0-1.0) [%default]") -parser.add_option("-p", "--port", type = "int",\ - dest = "port",\ + dest = "palettef", + help = "output plain rgb palette float values (0.0-1.0)") +parser.add_option("-p", "--port", type = "int", + dest = "port", + metavar ='int', help = "Mentat connection port [%default]") -parser.add_option("-b", "--baseindex", type = "int",\ - dest = "baseIdx",\ +parser.add_option("-b", "--baseindex", type = "int", + metavar ='int', + dest = "baseIdx", help = "base index of colormap [%default]") -parser.add_option("-n", "--colorcount", type = "int",\ - dest = "colorcount",\ +parser.add_option("-n", "--colorcount", type = "int", + metavar ='int', + dest = "colorcount", help = "number of colors [%default]") -parser.add_option("-v", "--verbose", action="store_true",\ - dest = "verbose",\ - help = "write Mentat command stream also to STDOUT [%default]") +parser.add_option("-v", "--verbose", action="store_true", + dest = "verbose", + help = "write Mentat command stream also to STDOUT") parser.set_defaults(port = 40007) parser.set_defaults(baseIdx = 32) diff --git a/processing/post/postResults.py b/processing/post/postResults.py index d130e2283..28a2b40ac 100755 --- a/processing/post/postResults.py +++ b/processing/post/postResults.py @@ -643,63 +643,69 @@ of already processed data points for evaluation. """, version = scriptID) -parser.add_option('-i','--info', action='store_true', dest='info', \ - help='list contents of resultfile [%default]') -parser.add_option('-l','--legacy', action='store_true', dest='legacy', \ +parser.add_option('-i','--info', action='store_true', dest='info', + help='list contents of resultfile') +parser.add_option('-l','--legacy', action='store_true', dest='legacy', help='data format of spectral solver is in legacy format (no MPI out)') -parser.add_option('-n','--nodal', action='store_true', dest='nodal', \ - help='data is extrapolated to nodal value [%default]') -parser.add_option( '--prefix', dest='prefix', \ - help='prefix to result file name [%default]') -parser.add_option( '--suffix', dest='suffix', \ - help='suffix to result file name [%default]') -parser.add_option('-d','--dir', dest='dir', \ +parser.add_option('-n','--nodal', action='store_true', dest='nodal', + help='data is extrapolated to nodal value') +parser.add_option( '--prefix', dest='prefix', + metavar='string', + help='prefix to result file name') +parser.add_option( '--suffix', dest='suffix', + metavar='string', + help='suffix to result file name') +parser.add_option('-d','--dir', dest='dir', + metavar='string', help='name of subdirectory to hold output [%default]') -parser.add_option('-s','--split', action='store_true', dest='separateFiles', \ - help='split output per increment [%default]') -parser.add_option('-r','--range', dest='range', type='int', nargs=3, \ +parser.add_option('-s','--split', action='store_true', dest='separateFiles', + help='split output per increment') +parser.add_option('-r','--range', dest='range', type='int', nargs=3, + metavar='int int int', help='range of positions (or increments) to output (start, end, step) [all]') -parser.add_option('--increments', action='store_true', dest='getIncrements', \ - help='switch to increment range [%default]') -parser.add_option('-m','--map', dest='func', \ +parser.add_option('--increments', action='store_true', dest='getIncrements', + help='switch to increment range') +parser.add_option('-m','--map', dest='func', + metavar='string', help='data reduction mapping [%default] out of min, max, avg, avgabs, sum, sumabs or user-lambda') -parser.add_option('-p','--type', dest='filetype', \ +parser.add_option('-p','--type', dest='filetype', + metavar = 'string', help = 'type of result file [auto]') group_material = OptionGroup(parser,'Material identifier') -group_material.add_option('--homogenization', dest='homog', \ - help='homogenization identifier (as string or integer [%default])', metavar='') -group_material.add_option('--crystallite', dest='cryst', \ - help='crystallite identifier (as string or integer [%default])', metavar='') -group_material.add_option('--phase', dest='phase', \ - help='phase identifier (as string or integer [%default])', metavar='') +group_material.add_option('--homogenization', dest='homog', + help='homogenization identifier (as string or integer [%default])', metavar='string') +group_material.add_option('--crystallite', dest='cryst', + help='crystallite identifier (as string or integer [%default])', metavar='string') +group_material.add_option('--phase', dest='phase', + help='phase identifier (as string or integer [%default])', metavar='string') group_special = OptionGroup(parser,'Special outputs') -group_special.add_option('-t','--time', action='store_true', dest='time', \ +group_special.add_option('-t','--time', action='store_true', dest='time', help='output time of increment [%default]') -group_special.add_option('-f','--filter', dest='filter', \ - help='condition(s) to filter results [%default]', metavar='') -group_special.add_option('--separation', action='extend', dest='sep', \ - help='properties to separate results [%default]', metavar='') -group_special.add_option('--sort', action='extend', dest='sort', \ - help='properties to sort results [%default]', metavar='') +group_special.add_option('-f','--filter', dest='filter', + help='condition(s) to filter results [%default]', metavar='string') +group_special.add_option('--separation', action='extend', dest='sep', + help='properties to separate results [%default]', metavar='') +group_special.add_option('--sort', action='extend', dest='sort', + help='properties to sort results [%default]', metavar='') group_general = OptionGroup(parser,'General outputs') -group_general.add_option('--ns', action='extend', dest='nodalScalar', \ - help='nodal scalars to extract', metavar='') -group_general.add_option('--es', action='extend', dest='elemScalar', \ - help='elemental scalars to extract', metavar='') -group_general.add_option('--et', action='extend', dest='elemTensor', \ - help='elemental tensors to extract', metavar='') -group_general.add_option('--ho', action='extend', dest='homogenizationResult', \ - help='homogenization results to extract', metavar='') -group_general.add_option('--cr', action='extend', dest='crystalliteResult', \ - help='crystallite results to extract', metavar='') -group_general.add_option('--co', action='extend', dest='constitutiveResult', \ - help='constitutive results to extract', metavar='') +group_general.add_option('--ns', action='extend', dest='nodalScalar', + help='nodal scalars to extract', metavar='') +group_general.add_option('--es', action='extend', dest='elemScalar', + help='elemental scalars to extract', metavar='') +group_general.add_option('--et', action='extend', dest='elemTensor', + help='elemental tensors to extract', metavar='') +group_general.add_option('--ho', action='extend', dest='homogenizationResult', + help='homogenization results to extract', metavar='') +group_general.add_option('--cr', action='extend', dest='crystalliteResult', + help='crystallite results to extract', metavar='') +group_general.add_option('--co', action='extend', dest='constitutiveResult', + help='constitutive results to extract', metavar='') parser.add_option_group(group_material) parser.add_option_group(group_general) diff --git a/processing/post/vtk2ang.py b/processing/post/vtk2ang.py index 5612003b1..bc8e23097 100755 --- a/processing/post/vtk2ang.py +++ b/processing/post/vtk2ang.py @@ -81,30 +81,39 @@ Builds a ang files from a vtk file. """, version = scriptID) -parser.add_option('--disp','--displacement',dest='dispLabel', \ +parser.add_option('--disp','--displacement',dest='dispLabel', + metavar ='string', help='label of displacements [%default]') -parser.add_option('--euler', dest='eulerLabel', nargs=3, \ +parser.add_option('--euler', dest='eulerLabel', nargs=3, + metavar ='string string string', help='labels of euler angles [%default]') -parser.add_option('-n','--normal', dest='normal', type='float', nargs=3, \ +parser.add_option('-n','--normal', dest='normal', type='float', nargs=3, + metavar ='float float float', help='normal of slices in direction of increasing slice numbers [%default]') parser.add_option('-u','--up', dest='up', type='float', nargs=3, + metavar ='float float float', help='up direction of slices [%default]') -parser.add_option('-i','--slices', dest='Nslices', type='int', \ +parser.add_option('-i','--slices', dest='Nslices', type='int', + metavar ='int', help='number of slices [%default]') -parser.add_option('-d','--distance', dest='distance', type='float', \ +parser.add_option('-d','--distance', dest='distance', type='float', + metavar ='float', help='slice distance [%default]') -parser.add_option('-s','--scale', dest='scale', type='float', \ +parser.add_option('-s','--scale', dest='scale', type='float', + metavar ='float', help='scale length from vtk file [%default]') parser.add_option('-r','--resolution', dest='resolution', type='float', + metavar ='float', help='scaling factor for resolution [%default]') parser.add_option('--hex','--hexagonal', dest='hexagonal', action='store_true', - help='use in plane hexagonal grid [%default]') -parser.add_option('--interpolation', dest='interpolation', type='int', \ + help='use in plane hexagonal grid') +parser.add_option('--interpolation', dest='interpolation', type='int', + metavar='float', help='number of points for linear interpolation [%default]') parser.add_option('--verbose', dest='verbose', action='store_true', - help='verbose mode [%default]') + help='verbose mode') parser.add_option('--visualize', dest='visualize', action='store_true', - help='visualize geometry [%default]') + help='visualize geometry') parser.set_defaults(dispLabel = 'displacement') parser.set_defaults(eulerLabel = ['1_1_eulerangles','1_2_eulerangles','1_3_eulerangles']) diff --git a/processing/post/vtk_addPointcloudData.py b/processing/post/vtk_addPointcloudData.py index 75160f53b..3590a436e 100755 --- a/processing/post/vtk_addPointcloudData.py +++ b/processing/post/vtk_addPointcloudData.py @@ -30,13 +30,15 @@ parser.add_option('-r', '--render', dest = 'render', action = 'store_true', help = 'open output in VTK render window') -parser.add_option('-s', '--scalar', dest='scalar', action='extend', \ +parser.add_option('-s', '--scalar', dest='scalar', action='extend', + metavar ='', help = 'scalar values') parser.add_option('-v', '--vector', dest = 'vector', action = 'extend', metavar = '', help = 'vector value label(s)') -parser.add_option('-c', '--color', dest='color', action='extend', \ +parser.add_option('-c', '--color', dest='color', action='extend', + metavar ='', help = 'RGB color tuples') parser.set_defaults(scalar = [], diff --git a/processing/post/vtk_rectilinearGrid.py b/processing/post/vtk_rectilinearGrid.py index d62a2ecdb..32ea2c11c 100755 --- a/processing/post/vtk_rectilinearGrid.py +++ b/processing/post/vtk_rectilinearGrid.py @@ -21,6 +21,7 @@ Create regular voxel grid from points in an ASCIItable. parser.add_option('-m', '--mode', dest = 'mode', + metavar='string', type = 'choice', choices = ['cell','point'], help = 'cell-centered or point-centered coordinates') parser.add_option('-p', diff --git a/processing/pre/OIMlinear2linearODF.py b/processing/pre/OIMlinear2linearODF.py index 40bc2833b..cbcbcc7ec 100755 --- a/processing/pre/OIMlinear2linearODF.py +++ b/processing/pre/OIMlinear2linearODF.py @@ -23,7 +23,8 @@ Transform the binned texture data from "TSL OIM Analysis" into linear ODF data, """, version = scriptID) parser.add_option('-s', '--symmetry', dest='symmetry', choices=sampleSym.keys(), - help='Sample symmetry {%s} [Triclinic]'%(' '.join(sampleSym.keys()))) + metavar = 'string', + help='Sample symmetry {%s} [Triclinic]'%(' '.join(sampleSym.keys()))) parser.set_defaults(symmetry = 'Triclinic') diff --git a/processing/pre/geom_grainGrowth.py b/processing/pre/geom_grainGrowth.py index 6e4a7fc37..9184bd226 100755 --- a/processing/pre/geom_grainGrowth.py +++ b/processing/pre/geom_grainGrowth.py @@ -28,7 +28,7 @@ parser.add_option('-N', '--smooth', dest='N', type='int', metavar='int', help='N for curvature flow [%default]') parser.add_option('-r', '--renumber', dest='renumber', action='store_true', help='renumber microstructure indices from 1...N [%default]') -parser.add_option('-i', '--immutable', action='extend', dest='immutable', metavar = '', +parser.add_option('-i', '--immutable', action='extend', dest='immutable', metavar = '', help='list of immutable microstructures') parser.set_defaults(d = 1) diff --git a/processing/pre/marc_addUserOutput.py b/processing/pre/marc_addUserOutput.py index 026029470..6f61b2d26 100755 --- a/processing/pre/marc_addUserOutput.py +++ b/processing/pre/marc_addUserOutput.py @@ -70,20 +70,26 @@ Or have an existing set of user variables copied over from another *.dat file. parser.add_option('-n','--number', dest='number', type='int', \ + metavar='int', help='maximum requested User Defined Variable [%default]') parser.add_option('--homogenization', dest='homog', \ + metavar='string', help='homogenization identifier (as string or integer [%default])') parser.add_option('--crystallite', dest='cryst', \ + metavar='string', help='crystallite identifier (as string or integer [%default])') parser.add_option('--phase', dest='phase', \ + metavar='string', help='phase identifier (as string or integer [%default])') parser.add_option('--use', dest='useFile', \ + metavar='string', help='Optionally parse output descriptors from '+ 'different .outputZZZ file. Saves the effort '+ - 'to start a calculation for each job [%default])') + 'to start a calculation for each job)') parser.add_option('--option', dest='damaskOption', \ + metavar='string', help='Add damask option to input file '+ - 'for example: "periodic x z" [%default]') + 'for example: "periodic x z"') parser.set_defaults(number = 0) parser.set_defaults(homog = '1') parser.set_defaults(cryst = '1') diff --git a/processing/pre/table_fromOIMgrainFile.py b/processing/pre/table_fromOIMgrainFile.py index 02f99fe88..30cfee2f4 100755 --- a/processing/pre/table_fromOIMgrainFile.py +++ b/processing/pre/table_fromOIMgrainFile.py @@ -19,6 +19,7 @@ Adds header to OIM grain file to make it accesible as ASCII table parser.add_option('-l', '--labels', dest = 'labels', + action = 'extend', metavar = '', help = 'lables of requested columns') parser.set_defaults(labels = ['1_euler','2_euler','3_euler', From 49b02ac1f2b3a3d47943366c0f2e2db0a35ed788 Mon Sep 17 00:00:00 2001 From: Martin Diehl Date: Fri, 13 May 2016 22:46:03 +0200 Subject: [PATCH 3/3] label name inline with current scheme --- processing/post/3Dvisualize.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/processing/post/3Dvisualize.py b/processing/post/3Dvisualize.py index 49736983a..e29a761df 100755 --- a/processing/post/3Dvisualize.py +++ b/processing/post/3Dvisualize.py @@ -227,7 +227,7 @@ for filename in args: locol = -1 for col,head in enumerate(headings): - if head == {True:'1_ipinitialcoord',False:'1_nodeinitialcoord'}[options.cell]: + if head == {True:'1_pos',False:'1_nodeinitialcoord'}[options.cell]: locol = col maxcol = max(maxcol,col+3) break @@ -430,4 +430,4 @@ for filename in args: vtk = open(os.path.join(head,what+'_'+os.path.splitext(tail)[0]+'.vtk'), 'w') output(out[what],{'filepointer':vtk},'File') vtk.close() - print \ No newline at end of file + print