import stringmap

Header =  {
  'Release'      : '2023',
  'Revision'     : '61624',
  'BuildDate'    : '23 Dec 2022',
  'CreationDate' : '09 Jan 2023',
  'CreationTime' : '14:18:35',
  'Creator'      : 'geodict',
  'Platform'     : '64 bit Linux',
  }

Description = '''
This macro generates a fiber structure, runs a flow simulation, returns permeability and saves an image of the structure with streamlines.
Vary the parameters solid volume percentage and fiber diameter.

Macro file for GeoDict 2023
recorded at 14:18:35 on 09 Jan 2023
by M2M-Cloud of Math2Market GmbH
'''

Variables = {
  'NumberOfVariables' : 2,
  'Variable1' : {
    'Name'           : 'gd_SVP',
    'Label'          : 'Solid Volume Percentage',
    'Type'           : 'double',
    'Unit'           : '%',
    'ToolTip'        : 'Solid volume percentage of the created structure.',
    'BuiltinDefault' : 10.0,
    'Check'          : 'min0;max100'
    },
  'Variable2' : {
    'Name'           : 'gd_FD',
    'Label'          : 'Fiber Diameter',
    'Type'           : 'double',
    'Unit'           : 'µ',
    'ToolTip'        : 'Fiber diameter of material 1.',
    'BuiltinDefault' : 10.0,
    },
  }

# Explanations of variables syntax:
###################################
# Name:           mandatory, name of the variable by that it can be addressed in the macro, must not contain white spaces!
# Label:          optional,  appears as text in the GeoDict GUI. If not present, then Name is used also as Label
# Type:           mandatory, known types are bool, boolgroup, double, uint, int, string, filestring, folderstring, material, combo, table, combogroup, labelgroup
# Unit:           optional,  appears only in GUI (not used to rescale any input parameters automatically)
#                            for type filestring, Unit contains the file suffix
#                            for type material,   Unit must be solid, fluid or porous
#                            for type combo,      Unit must contain the possible string-values for the variable separated by semicolon
#                            for type table,      Unit must be a list of type strings, allowed is "int", "float", "string". E.g. ["int", "float", "string"] for three columns.
# ToolTip:        optional,  appears in GUI (must be in one line)
# BuiltinDefault: optional,  default value which is used in macro (if not given, defaults to 0 or empty string)
#                            for type table, this should be a python list of entries, left to right, top to bottom, e.g. [1,2.0,"three"].
# ColumnHeaders:  optional,  only valid for type table: List of header texts for each table column, e.g. ["Column 1", "Second column", "Third Column"]
# Check:          optional,  known checks are positive, negative, min, max (checks are separated by semicolon)
# Member:         optional,  defines the member of group type variables. For Labelgroups defined by a list, for combogroup and boolgroup defined by a dictionary that maps states to lists

# Examples of variable usage in GeoDict command argument lists:
###############################################################
# 'SolidVolumePercentage' : (gd_SVP, '%'),                    # Set parameter SolidVolumePercentage value of variable gd_SVP
# 'ResultFileName'        : f'FilterEfficiency_{gd_SVP}.gdr'  # Make parameter ResultFileName include the string converted from the value of variable gd_SVP

# Frequently used Python syntax:
#####################################################
# print('The solid volume percentage is:', gd_SVP)             # Print to console and log - file
#
#   for x in range(0, 100) : # Use "for" loop statement
#     x_sq = x * x
#
#   if gd_SVP < 0:                                            # Use "if" statement
#     print('error')


Create_args_1 = {
  'MaterialMode'             : 'Material',     # Possible values: Material, MaterialID
  'MaterialIDMode'           : 'MaterialIDPerObjectType',# Possible values: MaterialIDPerObjectType, MaterialIDPerMaterial
  'Domain' : {
    'PeriodicX'         : False,
    'PeriodicY'         : False,
    'PeriodicZ'         : False,
    'OriginX'           : (0, 'm'),
    'OriginY'           : (0, 'm'),
    'OriginZ'           : (0, 'm'),
    'VoxelLength'       : (1e-06, 'm'),
    'DomainMode'        : 'VoxelNumber',
    'NX'                : 100,
    'NY'                : 100,
    'NZ'                : 100,
    'OverlapMode'       : 'GivenMaterial', # Possible values: OverlapMaterial, NewMaterial, OldMaterial, GivenMaterial
    'Material' : {
      'Type'        : 'Fluid',
      'Name'        : 'Air',
      'Information' : '',
      },
    'OverlapMaterialID' : 3,
    'NumOverlapRules'   : 2,
    'OverlapRule1' : {
      'MaterialID1'       : 1,
      'MaterialID2'       : 1,
      'OverlapMaterialID' : 1,
      },
    'OverlapRule2' : {
      'MaterialID1'       : 2,
      'MaterialID2'       : 2,
      'OverlapMaterialID' : 2,
      },
    'HollowMaterialID'  : 0,
    'PostProcessing' : {
      'ResolveOverlap'    : False,
      'MarkContactVoxels' : False,
      'ContactMaterialID' : 3,
      },
    },
  'MaximalTime'              : (24, 'h'),
  'OverlapMode'              : 'AllowOverlap', # Possible values: AllowOverlap, RemoveOverlap, ForceConnection, IsolationDistance, ProhibitWithExisting, ProhibitOverlap, MatchSVFDistribution
  'NumberOfObjects'          : 100,
  'StoppingCriterion'        : 'SolidVolumePercentage',# Possible values: SolidVolumePercentage, NumberOfObjects, Grammage, Density, WeightPercentage, FillToRim, SVP, Number
  'SolidVolumePercentage'    : (gd_SVP, '%'),
  'Grammage'                 : (10, 'g/m^2'),
  'SaveGadStep'              : 10,
  'RecordIntermediateResult' : False,
  'InExisting'               : False,
  'KeepStructure'            : False,
  'WeightPercentage'         : (0, '%'),
  'Density'                  : (0, 'g/cm^3'),
  'RemoveOverlap' : {
    'Iterations'        : 1000,
    'OverlapSVP'        : (0, '%'),
    'SVPUnchanged'      : 20,
    'AllowShift'        : True,
    'AllowRotation'     : True,
    'AllowDeformation'  : True,
    'NumberOfShifts'    : 10,
    'ShiftDistance'     : (2, 'Voxel'),
    'NumberOfRotations' : 20,
    'MaximalAngle'      : 60,
    'DistanceMode'      : 'Touch',      # Possible values: Touch, Overlap, Isolation, AvoidContact
    'IsolationDistance' : (0, 'm'),
    'MaximalOverlap'    : (0, 'm'),
    },
  'MatchSVFDistribution' : {
    'ErrorBound'         : 0.001,
    'CorrelationLengthX' : (2e-05, 'm'),
    'CorrelationLengthY' : (2e-05, 'm'),
    'CorrelationLengthZ' : (1e-05, 'm'),
    'StandardDeviation'  : 0.5,
    'CoarseningFactor'   : 10,
    'MatchMode'          : 'Gauss',      # Possible values: Gauss, Gradient
    'RelativeDensity'    : True,
    'DensityFunction' : {
      'XValues' : [0, 0.5, 1],
      'YValues' : [1, 0.1, 1],
      },
    },
  'PercentageType'           : 0,
  'RandomSeed'               : 47,
  'IsolationDistance'        : (0, 'm'),
  'ResultFileName'           : f'FiberGeo_{gd_SVP}_{gd_FD}.gdr',
  'MatrixDensity'            : (0, 'g/cm^3'),
  'OverlapMaterial' : {
    'Type'        : 'Solid',
    'Name'        : 'Glass',
    'Information' : 'Overlap',
    },
  'ContactMaterial' : {
    'Type'        : 'Solid',
    'Name'        : 'Glass',
    'Information' : 'Contact',
    },
  'NumberOfGenerators'       : 2,
  'Generator1' : {
    'Material' : {
      'Type'        : 'Solid',
      'Name'        : 'Glass',
      'Information' : 'Fiber',
      },
    'Probability'             : 0.5,
    'SpecificWeight'          : (2.58, 'g/cm^3'),
    'Type'                    : 'InfiniteCircularFiberGenerator',
    'UseDTex'                 : False,
    'DiameterDistribution' : {
      'Type'  : 'Constant', # Possible values: Constant, UniformlyInInterval, Gaussian, Table, LogNormal
      'Value' : gd_FD * 1e-6,
      },
    'OrientationDistribution' : {
      'Type'          : 'AnisotropicDirection',# Possible values: Isotropic, AnisotropicDirection, AnisotropicOrientation, GivenDirection, InXYPlane, AngleAroundDirection, UNDEF
      'DirectionMode' : 'AnisotropyParameter',# Possible values: AnisotropyParameter, DirectionTensor
      'Anisotropy1'   : 7,
      'Anisotropy2'   : 1,
      'Phi'           : 0,
      'Theta'         : 0,
      'Psi'           : 0,
      },
    },
  'Generator2' : {
    'Material' : {
      'Type'        : 'Solid',
      'Name'        : 'Glass',
      'Information' : 'Fiber',
      },
    'Probability'             : 0.5,
    'SpecificWeight'          : (2.58, 'g/cm^3'),
    'Type'                    : 'InfiniteCircularFiberGenerator',
    'UseDTex'                 : False,
    'DiameterDistribution' : {
      'Type'  : 'Constant', # Possible values: Constant, UniformlyInInterval, Gaussian, Table, LogNormal
      'Value' : 6e-06,
      },
    'OrientationDistribution' : {
      'Type'          : 'AnisotropicDirection',# Possible values: Isotropic, AnisotropicDirection, AnisotropicOrientation, GivenDirection, InXYPlane, AngleAroundDirection, UNDEF
      'DirectionMode' : 'AnisotropyParameter',# Possible values: AnisotropyParameter, DirectionTensor
      'Anisotropy1'   : 5,
      'Anisotropy2'   : 1,
      'Phi'           : 0,
      'Theta'         : 0,
      'Psi'           : 0,
      },
    },
  'Temperature'              : (293.15, 'K'),
  }
gd.runCmd("FiberGeo:Create", Create_args_1, Header['Release'])

SolveStokes_args_1 = {
  'ResultFileName'       : f'StokesResult_{gd_SVP}_{gd_FD}.gdr',
  'Experiment' : {
    'DirectionEnabledX'  : False,
    'DirectionEnabledY'  : False,
    'DirectionEnabledZ'  : True,
    'CharLengthMode'     : 'PERMEABILITY', # Possible values: PERMEABILITY, PORE_SIZE, FIBER_SIZE, USER_GIVEN
    'GivenCharLength'    : 1,
    'PressureDifference' : (0.02, 'Pa'),
    'MeanVelocity'       : (0.1, 'm/s'),
    'FlowRate'           : (60, 'l/min'),
    'FlowArea'           : (100, 'cm^2'),
    'ExperimentIO'       : 'PressureDrop', # Possible values: PressureDrop, MeanVelocity, FlowRate
    'AddInletOutlet'     : True,
    'InletLength'        : 10,
    'OutletLength'       : 10,
    'NormalBcType'       : 'Periodic',     # Possible values: Periodic, Symmetric, VinPout
    'SlipLength'         : 0,
    'TangentialBcYInX'   : 'Periodic',     # Possible values: Periodic, Symmetric, NoSlip
    'TangentialBcZInX'   : 'Periodic',     # Possible values: Periodic, Symmetric, NoSlip
    'TangentialBcXInY'   : 'Periodic',     # Possible values: Periodic, Symmetric, NoSlip
    'TangentialBcZInY'   : 'Periodic',     # Possible values: Periodic, Symmetric, NoSlip
    'TangentialBcXInZ'   : 'Periodic',     # Possible values: Periodic, Symmetric, NoSlip
    'TangentialBcYInZ'   : 'Periodic',     # Possible values: Periodic, Symmetric, NoSlip
    },
  'SolverData' : {
    'Solver'    : 'LIR', # Possible values: LIR, SimpleFFT, EJ
    'LIR' : {
      'Parallelization' : {
        'Mode' : 'LOCAL_MAX', # Possible values: Sequential, LOCAL_THREADS, LOCAL_MPI, LOCAL_MAX, CLUSTER, Undefined
        },
      'DiscardTemporaryFiles'   : False,
      'AnalyzeGeometry'         : True,
      'RestartFileName'         : '',
      'Restart'                 : False,
      'RestartSaveIntervalTime' : 6,
      'Tolerance'               : 0.0001,
      'MaxNumberOfIterations'   : 100000,
      'MaximalSolverRunTime'    : (240, 'h'),
      'UseMaxIterations'        : False,
      'UseMaxTime'              : False,
      'UseTolerance'            : False,
      'UseErrorBound'           : True,
      'ErrorBound'              : 0.01,
      'UseLateral'              : False,
      'Refinement'              : 'ENABLED',   # Possible values: ENABLED, DISABLED, MANUAL
      'NumberOfRefinements'     : 10,
      'Threshold'               : 0.1,
      'Optimization'            : 'Speed',
      'GridType'                : 'LIR-Tree',
      'UseMultigrid'            : True,
      'UseKrylov'               : 'Automatic', # Possible values: Automatic, Enabled, Disabled
      'Relaxation'              : 1,
      'WriteCompressedFields'   : True,
      },
    'SimpleFFT' : {
      'UseResidual'             : False,
      'Residual'                : 0.0001,
      'Tolerance'               : 0.0001,
      'MaxNumberOfIterations'   : 100000,
      'MaximalSolverRunTime'    : (240, 'h'),
      'UseMaxIterations'        : False,
      'UseMaxTime'              : False,
      'UseTolerance'            : False,
      'UseErrorBound'           : True,
      'ErrorBound'              : 0.01,
      'UseLateral'              : False,
      'Parallelization' : {
        'Mode' : 'LOCAL_MAX', # Possible values: Sequential, LOCAL_THREADS, LOCAL_MPI, LOCAL_MAX, CLUSTER, Undefined
        },
      'DiscardTemporaryFiles'   : False,
      'AnalyzeGeometry'         : True,
      'RestartFileName'         : '',
      'Restart'                 : False,
      'RestartSaveIntervalTime' : 6,
      'RelaxationVelocity'      : 1,
      'RelaxationPressure'      : 1,
      'TdmaMode'                : 'Automatic', # Possible values: Automatic, NotUseTdma, UseTdma
      },
    'EJ' : {
      'UseResidual'             : False,
      'Residual'                : 0.001,
      'Tolerance'               : 0.001,
      'MaxNumberOfIterations'   : 100000,
      'MaximalSolverRunTime'    : (240, 'h'),
      'UseMaxIterations'        : False,
      'UseMaxTime'              : False,
      'UseTolerance'            : True,
      'Parallelization' : {
        'Mode' : 'LOCAL_MAX', # Possible values: Sequential, LOCAL_THREADS, LOCAL_MPI, LOCAL_MAX, CLUSTER, Undefined
        },
      'DiscardTemporaryFiles'   : False,
      'AnalyzeGeometry'         : True,
      'RestartFileName'         : '',
      'Restart'                 : False,
      'RestartSaveIntervalTime' : 6,
      'SolverType'              : 0,
      },
    },
  'Grid' : {
    'UseBoxels'    : False,
    'BoxelLengthX' : 1e-06,
    'BoxelLengthY' : 1e-06,
    'BoxelLengthZ' : 1e-06,
    },
  'ConstituentMaterials' : {
    'Temperature' : (293.15, 'K'),
    'Material00' : {
      'Type'            : 'Fluid',
      'Name'            : 'Air',
      'Information'     : '',
      'FluidProperties' : {
        'CurrentLaw'   : 1,
        'NumberOfLaws' : 1,
        'MaterialLaw1' : {
          'Name'      : 'Material Law 1',
          'Density'   : (1.204, 'kg/m^3'),
          'Viscosity' : (1.834e-05, 'kg/(ms)'),
          },
        },
      },
    'Material01' : {
      'Type'        : 'Solid',
      'Name'        : 'Glass',
      'Information' : 'Fiber',
      },
    'Material02' : {
      'Type'        : 'Solid',
      'Name'        : 'Glass',
      'Information' : 'Fiber',
      },
    'Material03' : {
      'Type'        : 'Solid',
      'Name'        : 'Glass',
      'Information' : 'Overlap',
      },
    'ChosenFluid' : {
      'Fluid'      : 'Air',
      'CurrentLaw' : 1,
      },
    },
  }
gd.runCmd("FlowDict:SolveStokes", SolveStokes_args_1, "2023")

gdr = stringmap.parseGDR(f'StokesResult_{gd_SVP}_{gd_FD}.gdr')
perm_string = gdr["ResultMap:Permeability33"]
perm = float(perm_string)
gd.msgBox(f"For svp = {gd_SVP} and diameter = {gd_FD} permeability is {perm:.2e}.")

LoadVolumeField_args_1 = {
  'FileName'            : f'StokesResult_{gd_SVP}_{gd_FD}/FlowField_z.vap',
  'OverrideFileName'    : '',
  'Mode'                : 'All',        # Possible values: Selected, All
  'KeepVolumeFields'    : False,
  'KeepCompression'     : 'DecompressIfPossible',# Possible values: DecompressIfPossible, KeepCompression
  'Resampling'          : 'Automatic',  # Possible values: Automatic, Manual
  'ResampleToVoxel'     : True,
  'ResampleVoxelLength' : (1e-06, 'm'),
  }
gd.runCmd("GeoDict:LoadVolumeField", LoadVolumeField_args_1, "2023")



SetViewStatus_args_1 = {
  'Mode'      : 'Mode3D', # Possible values: Mode3D, Mode2D
  'Camera' : {
    'Camera2D' : {
      'Direction'   : 'X',           # Possible values: X, Y, Z
      'Depth'       : 0,
      'Decay'       : 256,
      'Slice'       : 1,
      'Orientation' : 'BottomToTop', # Possible values: BottomToTop, TopToBottom
      'Grid'        : 'Off',         # Possible values: Off, RegularGrid, AdaptiveGrid, Outlines
      'Position'    : [5e-05, -4.999999874e-05],
      'Zoom'        : 604,
      },
    'Camera3D' : {
      'Rotation'         : [-46.04898353, -17.65052696, -75.68897471],
      'LocalRotation'    : [0, 0, 0],
      'Translation'      : [0, 0, 0],
      'LocalTranslation' : [0, 0, 0],
      'FieldOfView'      : 20,
      'Light' : {
        'Rotation' : [28.64788976, -11.4591559, -28.64788976],
        },
      'PostProcessing' : {
        'DrawOutlines'   : False,
        'DrawHalo'       : False,
        'GlobalLight'    : False,
        'DepthDarkening' : False,
        },
      'ScaleMode'        : 'Automatic', # Possible values: Automatic, XAxis, YAxis, ZAxis, Manual
      'ManualScale'      : 100,
      },
    'BackgroundColor' : [255, 255, 255],
    },
  'Legends' : {
    'Logo' : {
      'Shown'     : False,
      'Align'     : 'BottomRight', # Possible values: BottomLeft, BottomRight, TopLeft, TopRight
      'Placement' : {
        'Align'        : 'Right',    # Possible values: Left, Right, Top, Bottom
        'AlignSign'    : 'Positive', # Possible values: Negative, Neutral, Positive
        'AttachedMode' : 'Inside',   # Possible values: Inside, Outside
        },
      },
    'VolumeFieldLegend' : {
      'Shown'             : True,
      'Align'             : 'Right',       # Possible values: Left, Right, Top, Bottom
      'Stretch'           : 0.400000006,
      'Decimals'          : 2,
      'NumberFormat'      : 'Engineering', # Possible values: Scientific, Number, Engineering
      'PlotRanges'        : 'Both',        # Possible values: Both, Plot, Data, None, Auto
      'TickmarkMode'      : 'Automatic',   # Possible values: Manual, Automatic
      'NumberOfTickmarks' : 4,
      'Placement' : {
        'Align'        : 'Right',   # Possible values: Left, Right, Top, Bottom
        'AlignSign'    : 'Neutral', # Possible values: Negative, Neutral, Positive
        'AttachedMode' : 'Outside', # Possible values: Inside, Outside
        },
      },
    'MaterialLegend' : {
      'Shown'     : True,
      'Placement' : {
        'Align'        : 'Left',     # Possible values: Left, Right, Top, Bottom
        'AlignSign'    : 'Negative', # Possible values: Negative, Neutral, Positive
        'AttachedMode' : 'Outside',  # Possible values: Inside, Outside
        },
      },
    'Axes' : {
      'Shown'     : True,
      'Placement' : {
        'Align'        : 'Bottom',   # Possible values: Left, Right, Top, Bottom
        'AlignSign'    : 'Positive', # Possible values: Negative, Neutral, Positive
        'AttachedMode' : 'Outside',  # Possible values: Inside, Outside
        },
      },
    'Status' : {
      'Shown'              : True,
      'UserInfoShown'      : True,
      'DateInfoShown'      : True,
      'TimeInfoShown'      : True,
      'DirectionInfoShown' : True,
      'DepthInfoShown'     : True,
      'Placement' : {
        'Align'        : 'Bottom',   # Possible values: Left, Right, Top, Bottom
        'AlignSign'    : 'Negative', # Possible values: Negative, Neutral, Positive
        'AttachedMode' : 'Outside',  # Possible values: Inside, Outside
        },
      },
    'ScaleBar' : {
      'Shown'           : True,
      'Resolution'      : 0.25,
      'FixedResolution' : 50,
      'Axes'            : 'Auto',          # Possible values: XPlus, XMinus, YPlus, YMinus, ZPlus, ZMinus, Auto
      'Unit'            : 'nm',            # Possible values: nm, microns, mm, m, km
      'Mode'            : 'Percentage',    # Possible values: Percentage, FixedSize
      'Orientation'     : 'Deg0',          # Possible values: Deg0, Deg90, Deg180, Deg270
      'Simple'          : False,
      'Align'           : 'BottomLeft',    # Possible values: BottomLeft, BottomRight, TopLeft, TopRight
      'Placement' : {
        'Align'        : 'Bottom',   # Possible values: Left, Right, Top, Bottom
        'AlignSign'    : 'Positive', # Possible values: Negative, Neutral, Positive
        'AttachedMode' : 'Outside',  # Possible values: Inside, Outside
        },
      'ShowBackground'  : True,
      'ShowBorder'      : True,
      'FontColor'       : [255, 255, 255],
      },
    'BoundingBox' : {
      'Shown'     : True,
      'Thickness' : 0,
      'Color'     : [155, 155, 155],
      },
    'CustomText' : {
      'Shown'     : False,
      'Text'      : 'GeoDict',
      'Placement' : {
        'Align'        : 'Bottom',   # Possible values: Left, Right, Top, Bottom
        'AlignSign'    : 'Positive', # Possible values: Negative, Neutral, Positive
        'AttachedMode' : 'Outside',  # Possible values: Inside, Outside
        },
      },
    'Metrology' : {
      'LineThickness' : 0,
      'LineColor'     : [0, 0, 0],
      },
    'LegendLocation'     : 'Overlay',       # Possible values: Overlay, Attached
    'TextSize'           : 10,
    'FontColorMode'      : 'Automatic',     # Possible values: Manual, Automatic
    'FontColor'          : [255, 255, 255],
    'BackgroundColor'    : [192, 192, 192],
    'StatusBarPlacement' : 'Bottom',        # Possible values: Left, Right, Top, Bottom
    'StatusBarShown'     : True,
    },
  'DataView' : {
    'Structure' : {
      'Shown'        : True,
      'Renderer'     : 'Smooth', # Possible values: Box, Smooth, GPU
      'GPURenderer' : {
        'WireFrame'   : False,
        'BackFaces'   : False,
        'HighQuality' : False,
        },
      'Transparency' : {
        'Mode'                      : 'None', # Possible values: None, Surface, Volume
        'Density'                   : 0.1,
        'SmoothTransparentMaterial' : 1,
        'MaterialTransparency'      : [0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5, 0.5],
        },
      'Visibility' : {
        'Material'    : [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
        'BoxClipping' : {
          'Enabled' : [True, True, True],
          'Start'   : [0, 0, 0],
          'End'     : [100, 100, 100],
          'Mode'    : 'ClipArea',         # Possible values: ClipArea, ClipEverythingButArea
          },
        },
      'Color' : {
        'Material0'   : [255, 255, 255],
        'Material1'   : [220, 200, 140],
        'Material2'   : [220, 200, 140],
        'Material3'   : [220, 200, 140],
        'Material4'   : [0, 0, 255],
        'Material5'   : [170, 0, 255],
        'Material6'   : [0, 255, 255],
        'Material7'   : [140, 140, 140],
        'Material8'   : [255, 170, 0],
        'Material9'   : [140, 100, 100],
        'Material10'  : [100, 140, 100],
        'Material11'  : [220, 200, 140],
        'Material12'  : [100, 100, 200],
        'Material13'  : [100, 0, 100],
        'Material14'  : [100, 140, 140],
        'Material15'  : [40, 40, 40],
        'Material16'  : [248, 9, 118],
        'Material17'  : [43, 233, 134],
        'Material18'  : [251, 153, 219],
        'Material19'  : [123, 18, 1],
        'Material20'  : [253, 52, 212],
        'Material21'  : [110, 167, 0],
        'Material22'  : [55, 0, 164],
        'Material23'  : [245, 136, 104],
        'Material24'  : [127, 96, 2],
        'Material25'  : [87, 190, 254],
        'Material26'  : [90, 4, 40],
        'Material27'  : [52, 99, 151],
        'Material28'  : [194, 98, 253],
        'Material29'  : [218, 253, 117],
        'Material30'  : [167, 253, 200],
        'Material31'  : [0, 115, 25],
        'Material32'  : [210, 195, 254],
        'Material33'  : [189, 72, 99],
        'Material34'  : [160, 255, 26],
        'Material35'  : [0, 192, 0],
        'Material36'  : [39, 34, 96],
        'Material37'  : [209, 83, 2],
        'Material38'  : [247, 177, 177],
        'Material39'  : [202, 0, 49],
        'Material40'  : [88, 86, 255],
        'Material41'  : [188, 178, 0],
        'Material42'  : [0, 181, 139],
        'Material43'  : [194, 28, 131],
        'Material44'  : [72, 72, 24],
        'Material45'  : [255, 0, 255],
        'Material46'  : [141, 0, 161],
        'Material47'  : [134, 102, 152],
        'Material48'  : [129, 144, 52],
        'Material49'  : [78, 143, 238],
        'Material50'  : [167, 81, 172],
        'Material51'  : [140, 218, 227],
        'Material52'  : [16, 70, 48],
        'Material53'  : [46, 4, 113],
        'Material54'  : [233, 175, 90],
        'Material55'  : [249, 130, 248],
        'Material56'  : [144, 253, 112],
        'Material57'  : [20, 250, 202],
        'Material58'  : [187, 134, 93],
        'Material59'  : [0, 250, 100],
        'Material60'  : [112, 60, 37],
        'Material61'  : [139, 31, 221],
        'Material62'  : [192, 119, 3],
        'Material63'  : [75, 36, 70],
        'Material64'  : [127, 197, 123],
        'Material65'  : [28, 89, 105],
        'Material66'  : [192, 140, 235],
        'Material67'  : [191, 199, 180],
        'Material68'  : [128, 157, 201],
        'Material69'  : [107, 53, 185],
        'Material70'  : [197, 132, 162],
        'Material71'  : [157, 80, 24],
        'Material72'  : [20, 176, 59],
        'Material73'  : [135, 43, 101],
        'Material74'  : [51, 169, 196],
        'Material75'  : [89, 50, 255],
        'Material76'  : [160, 211, 0],
        'Material77'  : [63, 101, 26],
        'Material78'  : [86, 124, 253],
        'Material79'  : [34, 144, 127],
        'Material80'  : [24, 41, 75],
        'Material81'  : [245, 130, 139],
        'Material82'  : [247, 132, 3],
        'Material83'  : [194, 248, 159],
        'Material84'  : [250, 5, 160],
        'Material85'  : [239, 88, 150],
        'Material86'  : [197, 78, 63],
        'Material87'  : [96, 91, 107],
        'Material88'  : [125, 203, 174],
        'Material89'  : [244, 187, 226],
        'Material90'  : [246, 234, 137],
        'Material91'  : [156, 145, 108],
        'Material92'  : [198, 55, 182],
        'Material93'  : [153, 6, 43],
        'Material94'  : [244, 62, 51],
        'Material95'  : [157, 140, 12],
        'Material96'  : [243, 213, 0],
        'Material97'  : [51, 74, 151],
        'Material98'  : [201, 0, 224],
        'Material99'  : [183, 201, 217],
        'Material100' : [44, 198, 197],
        'Material101' : [215, 241, 196],
        'Material102' : [247, 88, 190],
        'Material103' : [86, 155, 62],
        'Material104' : [223, 228, 64],
        'Material105' : [0, 134, 87],
        'Material106' : [72, 222, 254],
        'Material107' : [25, 184, 108],
        'Material108' : [187, 210, 101],
        'Material109' : [234, 62, 99],
        'Material110' : [99, 60, 144],
        'Material111' : [152, 75, 99],
        'Material112' : [161, 0, 6],
        'Material113' : [67, 128, 159],
        'Material114' : [64, 6, 74],
        'Material115' : [68, 35, 23],
        'Material116' : [151, 0, 71],
        'Material117' : [188, 100, 95],
        'Material118' : [201, 106, 162],
        'Material119' : [69, 0, 198],
        'Material120' : [146, 147, 248],
        'Material121' : [63, 233, 0],
        'Material122' : [104, 199, 0],
        'Material123' : [79, 83, 215],
        'Material124' : [238, 95, 246],
        'Material125' : [184, 151, 197],
        'Material126' : [240, 195, 56],
        'Material127' : [233, 180, 138],
        'Material128' : [206, 186, 73],
        'Material129' : [122, 104, 58],
        'Material130' : [162, 183, 125],
        'Material131' : [145, 101, 245],
        'Material132' : [53, 49, 156],
        'Material133' : [195, 159, 162],
        'Material134' : [115, 21, 32],
        'Material135' : [75, 66, 106],
        'Material136' : [106, 117, 93],
        'Material137' : [16, 78, 29],
        'Material138' : [104, 243, 169],
        'Material139' : [97, 58, 0],
        'Material140' : [237, 221, 247],
        'Material141' : [108, 240, 215],
        'Material142' : [134, 192, 79],
        'Material143' : [99, 113, 197],
        'Material144' : [4, 136, 0],
        'Material145' : [134, 8, 255],
        'Material146' : [147, 0, 111],
        'Material147' : [206, 108, 42],
        'Material148' : [74, 43, 215],
        'Material149' : [194, 116, 240],
        'Material150' : [177, 113, 183],
        'Material151' : [228, 203, 200],
        'Material152' : [93, 0, 140],
        'Material153' : [70, 122, 0],
        'Material154' : [216, 166, 237],
        'Material155' : [211, 25, 205],
        'Material156' : [171, 207, 62],
        'Material157' : [143, 43, 158],
        'Material158' : [173, 240, 119],
        'Material159' : [81, 145, 212],
        'Material160' : [128, 178, 193],
        'Material161' : [133, 178, 165],
        'Material162' : [146, 123, 196],
        'Material163' : [162, 128, 246],
        'Material164' : [138, 152, 8],
        'Material165' : [204, 13, 109],
        'Material166' : [52, 70, 64],
        'Material167' : [218, 255, 54],
        'Material168' : [200, 154, 6],
        'Material169' : [227, 148, 92],
        'Material170' : [0, 214, 81],
        'Material171' : [173, 162, 97],
        'Material172' : [15, 101, 70],
        'Material173' : [171, 176, 254],
        'Material174' : [167, 126, 107],
        'Material175' : [98, 106, 144],
        'Material176' : [67, 99, 63],
        'Material177' : [104, 65, 121],
        'Material178' : [144, 91, 41],
        'Material179' : [255, 66, 247],
        'Material180' : [175, 245, 219],
        'Material181' : [111, 56, 79],
        'Material182' : [28, 127, 131],
        'Material183' : [88, 212, 103],
        'Material184' : [165, 46, 207],
        'Material185' : [188, 70, 155],
        'Material186' : [91, 230, 71],
        'Material187' : [202, 181, 206],
        'Material188' : [188, 5, 79],
        'Material189' : [187, 142, 61],
        'Material190' : [169, 61, 11],
        'Material191' : [148, 65, 64],
        'Material192' : [154, 114, 140],
        'Material193' : [230, 114, 155],
        'Material194' : [192, 238, 254],
        'Material195' : [76, 167, 104],
        'Material196' : [246, 158, 144],
        'Material197' : [132, 59, 132],
        'Material198' : [205, 45, 8],
        'Material199' : [176, 110, 116],
        'Material200' : [0, 249, 55],
        'Material201' : [251, 107, 116],
        'Material202' : [229, 30, 172],
        'Material203' : [57, 78, 108],
        'Material204' : [91, 98, 26],
        'Material205' : [159, 22, 101],
        'Material206' : [248, 251, 190],
        'Material207' : [66, 34, 47],
        'Material208' : [33, 110, 55],
        'Material209' : [115, 202, 236],
        'Material210' : [35, 161, 165],
        'Material211' : [208, 232, 222],
        'Material212' : [20, 169, 0],
        'Material213' : [68, 51, 197],
        'Material214' : [83, 101, 102],
        'Material215' : [122, 170, 253],
        'Material216' : [143, 158, 178],
        'Material217' : [211, 105, 207],
        'Material218' : [99, 119, 67],
        'Material219' : [175, 218, 160],
        'Material220' : [80, 0, 110],
        'Material221' : [132, 243, 240],
        'Material222' : [126, 89, 161],
        'Material223' : [59, 35, 120],
        'Material224' : [245, 0, 93],
        'Material225' : [173, 78, 210],
        'Material226' : [121, 70, 234],
        'Material227' : [102, 30, 92],
        'Material228' : [157, 253, 171],
        'Material229' : [25, 216, 165],
        'Material230' : [48, 71, 125],
        'Material231' : [208, 121, 92],
        'Material232' : [179, 112, 45],
        'Material233' : [0, 246, 168],
        'Material234' : [211, 229, 141],
        'Material235' : [116, 210, 154],
        'Material236' : [15, 59, 66],
        'Material237' : [136, 220, 80],
        'Material238' : [139, 185, 146],
        'Material239' : [203, 186, 103],
        'Material240' : [185, 60, 71],
        'Material241' : [106, 72, 65],
        'Material242' : [196, 248, 83],
        'Material243' : [126, 250, 62],
        'Material244' : [213, 68, 51],
        'Material245' : [45, 97, 83],
        'Material246' : [104, 0, 182],
        'Material247' : [211, 142, 141],
        'Material248' : [31, 147, 64],
        'Material249' : [34, 251, 128],
        'Material250' : [153, 254, 141],
        'Material251' : [60, 163, 211],
        'Material252' : [240, 236, 204],
        'Material253' : [107, 116, 1],
        'Material254' : [232, 144, 168],
        'Material255' : [134, 48, 33],
        },
      },
    'VolumeField' : {
      'Shown'               : False,
      'ColorField'          : 'FlowField_z.vap:Velocity:Velocity',
      'LinesField'          : '',
      'Transparency'        : False,
      'NumberOfLines'       : 5,
      'DropFactor'          : 5,
      'TransparencyDensity' : 0.05,
      'Visibility' : {
        'ByValue' : {
          'Interpolate'       : True,
          'Mode'              : 'GreaterEqual',      # Possible values: GreaterEqual, SmallerEqual, Equal
          'Isovalue'          : 0,
          'Field'             : 'FlowField_z.vap:Velocity:Velocity',
          'RangeFor2DEnabled' : False,
          'RangeFor2D'        : [0, 0.001446407521],
          },
        'Material'    : [True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True, True],
        'BoxClipping' : {
          'Enabled' : [True, True, True],
          'Start'   : [0, 0, 0],
          'End'     : [100, 100, 100],
          'Mode'    : 'ClipArea',         # Possible values: ClipArea, ClipEverythingButArea
          },
        },
      'ColorInterpolation'  : 'NoInterpolation', # Possible values: NoInterpolation, Linear, Indexed, OnVisible, OnVisibleSmooth, PerMaterial
      'ColorMap'            : 'Default',
      'GPU' : {
        'Enabled'          : False,
        'Ambient'          : 0.7,
        'Diffuse'          : 0.3,
        'Specular'         : 0.7,
        'Shininess'        : 64,
        'AlphaByGrad'      : 0,
        'AlphaByAngle'     : 0,
        'MinGrad'          : 0.02,
        'OutlineThreshold' : 0,
        'OutlineStrength'  : 1,
        'Density'          : 0.15,
        },
      },
    'Arrow' : {
      'Shown'          : False,
      'Mode'           : 'Thick',      # Possible values: Line, Thick
      'Count'          : [10, 10, 10],
      'Visibility' : {
        'BoxClipping' : {
          'Enabled' : [True, True, True],
          'Start'   : [0, 0, 0],
          'End'     : [100, 100, 100],
          },
        'DistanceToStructure'      : False,
        'DistanceToStructureRange' : [1, 5],
        'MinimalVisibleLength'     : 0,
        'Material'                 : [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
        },
      'ArrowScale'     : 100,
      'ColorField'     : '',
      'Color'          : [0, 0, 0],
      'DirectionField' : 'Velocity',
      'Normalize'      : False,
      'ColorMap'       : 'Default',
      },
    'Tensor' : {
      'Shown'       : False,
      'Mode'        : 'Arrow',         # Possible values: Box, Ellipsoid, Arrow, SuperQuadric
      'ColorMode'   : 'MainDirection', # Possible values: MainDirection, Shape
      'TensorField' : '',
      'Visibility' : {
        'Material'    : [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
        'BoxClipping' : {
          'Enabled' : [True, True, True],
          'Start'   : [0, 0, 0],
          'End'     : [100, 100, 100],
          },
        },
      'Spacing'     : [5, 5, 5],
      },
    'Streamline' : {
      'Shown'         : True,
      'Placement' : {
        'Type'              : 'Inflow', # Possible values: Inflow, Box, Random, MaterialID, Circular, Line, Point
        'InflowPlacement' : {
          'Count' : [10, 10],
          },
        'BoxPlacement' : {
          'Count'    : [5, 5, 5],
          'Position' : {
            'Start' : [0, 0, 0],
            'End'   : [100, 100, 100],
            },
          },
        'RandomPlacement' : {
          'Count' : 1000,
          },
        'MaterialPlacement' : {
          'ID'       : 2,
          'MaxCount' : 100,
          },
        'CirclePlacement' : {
          'Midpoint'  : [10, 10, 10],
          'Direction' : 'Z',          # Possible values: X, Y, Z
          'Radius'    : 25,
          'Repeats'   : 3,
          'Density'   : 2,
          },
        'PointPlacement' : {
          'Position' : [0, 0, 0],
          },
        'LinePlacement' : {
          'Count'    : 10,
          'Position' : {
            'Start' : [0, 0, 0],
            'End'   : [100, 100, 100],
            },
          },
        },
      'Periodicity'   : True,
      'VelocityField' : 'Velocity',
      'RenderMode'    : 'Streamline', # Possible values: Streamline, Streamlet, Streamtube
      'Thickness'     : 2,
      'Streamlet' : {
        'NumberOfStreamlets' : 10,
        'Length'             : 0.25,
        'NumberOfFrames'     : 250,
        'CurrentFrame'       : 0,
        },
      'Visibility' : {
        'BoxClipping' : {
          'Enabled' : [True, True, True],
          'Start'   : [0, 0, 0],
          'End'     : [100, 100, 100],
          },
        'ClipWithVelocity'       : False,
        'MinimalVisibleVelocity' : 0,
        },
      'ColorMap'      : 'Default',
      },
    'LineIntegratedConvolution' : {
      'Shown'         : False,
      'VelocityField' : 'Velocity',
      'Direction'     : 'X',        # Possible values: X, Y, Z
      'Position'      : 0,
      'Normalize'     : False,
      'Resolution'    : 1,
      'Type'          : 'T4',       # Possible values: T0, T1, T2, T3, T4
      'Length'        : 25,
      'Colorize'      : False,
      'ColorField'    : 'StokesResult_10.0_10.0/FlowField_z.vap:Velocity:Velocity',
      'Visibility' : {
        'BoxClipping' : {
          'Enabled' : [True, True, True],
          'Start'   : [0, 0, 0],
          'End'     : [100, 100, 100],
          },
        },
      'ColorMap'      : 'Default',
      },
    'STL' : {
      'Shown'             : False,
      'Mode'              : 'Faces',     # Possible values: None, Points, Wireframe, HiddenLines, Faces, FacesAndWireframe, Smooth
      'ColorMode'         : 'ObjectID',  # Possible values: FixedColor, ObjectID, ConnectedComponent, Quality, MeanCurvature, NormalColor, MaterialID, ObjectIDColorTable
      'FixedColor'        : [255, 0, 0],
      'Transparency'      : 'None',      # Possible values: None, Simple, SeeThrough
      'ShowVertices'      : False,
      'ShowMidpoints'     : False,
      'ShowBoundary'      : False,
      'ShowFaceNormals'   : False,
      'ShowVertexNormals' : False,
      'Visibility' : {
        'Material'    : [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
        'BoxClipping' : {
          'Enabled' : [True, True, True],
          'Start'   : [0, 0, 0],
          'End'     : [100, 100, 100],
          },
        },
      },
    'Particles' : {
      'Shown'             : False,
      'Time'              : 0,
      'Batch'             : 0,
      'ParticlesMode'     : 'All',         # Possible values: None, Filtered, NotFiltered, TimeOut, All, Custom
      'TrajectoriesMode'  : 'None',        # Possible values: None, Filtered, NotFiltered, TimeOut, All
      'TrajectoriesStyle' : 'Line',        # Possible values: Stippled, Line
      'ColorScheme'       : 'MovingState', # Possible values: MovingState, Material, Size, BatchID
      'MovingColor'       : [0, 255, 0],
      'DepositedColor'    : [90, 90, 90],
      'Periodicity'       : 'XY',          # Possible values: YZ, XZ, XY, All
      'EnablePeriodicity' : True,
      'ShowOverlay'       : True,
      'CustomMode' : {
        'NumberOfSelections' : 0,
        },
      'Visibility' : {
        'Material'    : [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1],
        'BoxClipping' : {
          'Enabled' : [False, False, False],
          'Start'   : [0, 0, 0],
          'End'     : [0, 0, 0],
          },
        },
      },
    },
  'ColorMaps' : {
    'ColorMaps' : 'Default',
    'Default' : {
      'ColorMapSize'      : 'Discrete', # Possible values: Discrete, Continuous
      'DataRange' : {
        'Mode'            : 'Percentiles',       # Possible values: Manual, MinMax, Extended, Percentiles
        'PercentileRange' : [1, 99],
        'ManualRange'     : [0, 0.001446407521],
        },
      'InterpolationMode' : 'HSV',      # Possible values: RGB, HSV, LAB, Constant
      'Opacity' : {
        'NumberOfPoints' : 2,
        'Point1' : {
          'Opacity'  : 0.8,
          'Position' : 0,
          },
        'Point2' : {
          'Opacity'  : 0.8,
          'Position' : 1,
          },
        },
      'Color' : {
        'NumberOfPoints' : 2,
        'Point1' : {
          'Color'    : [0, 0, 255],
          'Position' : 0,
          },
        'Point2' : {
          'Color'    : [255, 0, 0],
          'Position' : 1,
          },
        },
      'Isosurface' : {
        'NumberOfPoints' : 0,
        },
      },
    },
  }
gd.runCmd("GeoDict:SetViewStatus", SetViewStatus_args_1, "2023")



SaveThreeDImage_args_1 = {
  'FileName'            : f'Streamlines_{gd_SVP}_{gd_FD}.png',
  'Resolution' : {
    'Mode'   : 'Fixed',     # Possible values: Current, Scaled, Fixed, Undefined
    'Width'  : (640, 'px'),
    'Height' : (480, 'px'),
    },
  'IncludeTransparency' : False,
  }
gd.runCmd("GeoDict:Save3DImage", SaveThreeDImage_args_1, "2023")



