From: Cédric Aguerre Date: Tue, 10 Feb 2015 11:15:46 +0000 (+0100) Subject: some fixes in tests X-Git-Tag: V7_6_0a1~2^2~3 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=e1f12e3e3a955aafb903f647a5398c6546250bd1;p=modules%2Fparavis.git some fixes in tests some fixes in tests some fixes in tests --- diff --git a/src/PV_SWIG/presentations.py b/src/PV_SWIG/presentations.py index 979d3380..766f8978 100644 --- a/src/PV_SWIG/presentations.py +++ b/src/PV_SWIG/presentations.py @@ -222,6 +222,7 @@ def process_prs_for_test(prs, view, picture_name, show_bar=True): display_only(prs, view) # Show scalar bar + global _current_bar if show_bar and _current_bar: _current_bar.Visibility = 1 @@ -235,6 +236,7 @@ def process_prs_for_test(prs, view, picture_name, show_bar=True): os.makedirs(pic_dir) # Save picture + print "Write image:", file_name pvs.WriteImage(file_name, view=view, Magnification=1) @@ -292,7 +294,7 @@ def display_only(prs, view=None): def set_visible_lines(xy_prs, lines): """Set visible only the given lines for XYChartRepresentation.""" - sv = xy_prs.GetProperty("SeriesVisibilityInfo").GetData() + sv = xy_prs.GetProperty("SeriesVisibility").GetData() visible = '0' for i in xrange(0, len(sv)): @@ -805,9 +807,6 @@ def select_cells_with_data(proxy, on_points=[], on_cells=[], on_gauss=[]): fields_info = proxy.GetProperty("FieldsTreeInfo")[::2] arr_name_with_dis=[elt.split("/")[-1] for elt in fields_info] - proxy.AllArrays = [] - proxy.UpdatePipeline() - fields = [] for name in on_gauss: fields.append(name+_med_field_sep+'GAUSS') @@ -821,13 +820,14 @@ def select_cells_with_data(proxy, on_points=[], on_cells=[], on_gauss=[]): if arr_name_with_dis.count(name) > 0: index = arr_name_with_dis.index(name) field_list.append(fields_info[index]) - - proxy.AllArrays = field_list - proxy.UpdatePipeline() + + if field_list: + proxy.AllArrays = field_list + proxy.UpdatePipeline() return len(field_list) != 0 # TODO: VTN. Looks like this code is out of date. - + #all_cell_types = proxy.CellTypes.Available all_cell_types = proxy.Entity.Available all_arrays = list(proxy.CellArrays.GetData()) @@ -927,13 +927,11 @@ def add_scalar_bar(field_name, nb_components, # Reassign the current bar _current_bar = scalar_bar - return scalar_bar + return _current_bar def get_bar(): """Get current scalar bar.""" - global _current_bar - return _current_bar @@ -1002,10 +1000,10 @@ def get_group_names(extrGrps): def get_time(proxy, timestamp_nb): """Get time value by timestamp number.""" - proxy.UpdatePipeline() + #proxy.UpdatePipeline() # Check timestamp number timestamps = [] - + if (hasattr(proxy, 'TimestepValues')): timestamps = proxy.TimestepValues.GetData() elif (hasattr(proxy.Input, 'TimestepValues')): @@ -1015,6 +1013,9 @@ def get_time(proxy, timestamp_nb): if (timestamp_nb > 0 and (timestamp_nb - 1) not in xrange(length) ) or (timestamp_nb < 0 and -timestamp_nb > length): raise ValueError("Timestamp number is out of range: " + str(timestamp_nb)) + if not timestamps: + return 0.0 + # Return time value if timestamp_nb > 0: return timestamps[timestamp_nb - 1] @@ -1195,7 +1196,7 @@ def CutPlanesOnField(proxy, entity, field_name, timestamp_nb, lookup_table.RGBPoints = [data_range[0], 0, 0, 1, data_range[1], 1, 0, 0] # Set properties - cut_planes.ColorArrayName = (EntityType.get_pvtype(entity), field_name) + cut_planes.ColorArrayName = (EntityType.get_pvtype(entity), field_name) cut_planes.LookupTable = lookup_table # Add scalar bar @@ -1526,9 +1527,9 @@ def VectorsOnField(proxy, entity, field_name, timestamp_nb, # Set properties if (is_colored): - vectors.ColorArrayName = 'GlyphVector' + vectors.ColorArrayName = (EntityType.get_pvtype(entity), 'GlyphVector') else: - vectors.ColorArrayName = '' + vectors.ColorArrayName = (None, '') vectors.LookupTable = lookup_table vectors.LineWidth = 1.0 @@ -1585,6 +1586,7 @@ def DeformedShapeOnField(proxy, entity, field_name, # Do merge source = pvs.MergeBlocks(proxy) + pvs.UpdatePipeline() # Cell data to point data if is_data_on_cells(proxy, field_name): @@ -1625,7 +1627,7 @@ def DeformedShapeOnField(proxy, entity, field_name, if is_colored: defshape.ColorArrayName = (EntityType.get_pvtype(entity), field_name) else: - defshape.ColorArrayName = '' + defshape.ColorArrayName = (None, '') defshape.LookupTable = lookup_table # Set wireframe represenatation mode @@ -1702,6 +1704,7 @@ def DeformedShapeAndScalarMapOnField(proxy, entity, field_name, # Do merge source = pvs.MergeBlocks(proxy) + pvs.UpdatePipeline() # Cell data to point data if is_data_on_cells(proxy, field_name): @@ -1963,6 +1966,7 @@ def IsoSurfacesOnField(proxy, entity, field_name, timestamp_nb, # Do merge source = pvs.MergeBlocks(proxy) + pvs.UpdatePipeline() # Transform cell data into point data if necessary if is_data_on_cells(proxy, field_name): @@ -2011,7 +2015,7 @@ def IsoSurfacesOnField(proxy, entity, field_name, timestamp_nb, if (is_colored): isosurfaces.ColorArrayName = (EntityType.get_pvtype(entity), field_name) else: - isosurfaces.ColorArrayName = '' + isosurfaces.ColorArrayName = (None, '') if color: isosurfaces.DiffuseColor = color isosurfaces.LookupTable = lookup_table @@ -2080,7 +2084,7 @@ def GaussPointsOnField(proxy, entity, field_name, # Set timestamp pvs.GetRenderView().ViewTime = time_value - proxy.UpdatePipeline(time=time_value) + pvs.UpdatePipeline(time_value, proxy) source = proxy @@ -2102,8 +2106,7 @@ def GaussPointsOnField(proxy, entity, field_name, vector_array = field_name # If the given vector array has only 2 components, add the third one if nb_components == 2: - calc = get_add_component_calc(source, - EntityType.NODE, field_name) + calc = get_add_component_calc(source, EntityType.NODE, field_name) vector_array = calc.ResultArrayName source = calc @@ -2135,7 +2138,7 @@ def GaussPointsOnField(proxy, entity, field_name, if is_colored: gausspnt.ColorArrayName = (EntityType.get_pvtype(entity), field_name) else: - gausspnt.ColorArrayName = '' + gausspnt.ColorArrayName = (None, '') if color: gausspnt.DiffuseColor = color @@ -2249,7 +2252,7 @@ def GaussPointsOnField1(proxy, entity, field_name, # Create Gauss Points object source = pvs.GaussPoints(proxy) source.UpdatePipeline() - + # Get Gauss Points representation object gausspnt = pvs.GetRepresentation(source) @@ -2266,7 +2269,7 @@ def GaussPointsOnField1(proxy, entity, field_name, if is_colored: gausspnt.ColorArrayName = (EntityType.get_pvtype(entity), field_name) else: - gausspnt.ColorArrayName = '' + gausspnt.ColorArrayName = (None, '') if color: gausspnt.DiffuseColor = color @@ -2375,12 +2378,13 @@ def StreamLinesOnField(proxy, entity, field_name, timestamp_nb, # Do merge source = pvs.MergeBlocks(proxy) + pvs.UpdatePipeline() # Cell data to point data if is_data_on_cells(proxy, field_name): cell_to_point = pvs.CellDatatoPointData(source) cell_to_point.PassCellData = 1 - cell_to_point.UpdatePipeline() + pvs.UpdatePipeline() source = cell_to_point vector_array = field_name @@ -2388,14 +2392,13 @@ def StreamLinesOnField(proxy, entity, field_name, timestamp_nb, if nb_components == 2: calc = get_add_component_calc(source, EntityType.NODE, field_name) vector_array = calc.ResultArrayName - calc.UpdatePipeline() + pvs.UpdatePipeline() source = calc # Stream Tracer stream = pvs.StreamTracer(source) stream.SeedType = "Point Source" stream.Vectors = ['POINTS', vector_array] - stream.SeedType = "Point Source" stream.IntegrationDirection = direction stream.IntegratorType = 'Runge-Kutta 2' stream.UpdatePipeline() @@ -2418,7 +2421,7 @@ def StreamLinesOnField(proxy, entity, field_name, timestamp_nb, if is_colored: streamlines.ColorArrayName = (EntityType.get_pvtype(entity), field_name) else: - streamlines.ColorArrayName = '' + streamlines.ColorArrayName = (None, '') if color: streamlines.DiffuseColor = color @@ -2452,8 +2455,6 @@ def MeshOnEntity(proxy, mesh_name, entity): if not mesh_full_name: raise RuntimeError, "The given mesh name was not found" # Select only the given mesh - proxy.AllArrays = [] - proxy.UpdatePipeline() proxy.AllArrays = [mesh_full_name] proxy.UpdatePipeline() @@ -2461,8 +2462,9 @@ def MeshOnEntity(proxy, mesh_name, entity): prs = None if (proxy.GetDataInformation().GetNumberOfPoints() or proxy.GetDataInformation().GetNumberOfCells()): - prs = pvs.GetRepresentation(proxy) - prs.ColorArrayName = '' + my_view = pvs.GetRenderView() + prs = pvs.GetRepresentation(proxy, view=my_view) + prs.ColorArrayName = (None, '') return prs @@ -2507,14 +2509,13 @@ def MeshOnGroup(proxy, extrGroups, group_name): return prs -def CreatePrsForFile(paravis_instance, file_name, prs_types, +def CreatePrsForFile(file_name, prs_types, picture_dir, picture_ext): """Build presentations of the given types for the file. Build presentations for all fields on all timestamps. Arguments: - paravis_instance: ParaVis module instance object file_name: full path to the MED file prs_types: the list of presentation types to build picture_dir: the directory path for saving snapshots @@ -2529,13 +2530,16 @@ def CreatePrsForFile(paravis_instance, file_name, prs_types, if proxy is None: print "FAILED" else: - proxy.UpdatePipeline() + #proxy.UpdatePipeline() print "OK" except: print "FAILED" else: # Get view view = pvs.GetRenderView() + time_value = get_time(proxy, 0) + view.ViewTime = time_value + pvs.UpdatePipeline(time=time_value, proxy=proxy) # Create required presentations for the proxy CreatePrsForProxy(proxy, view, prs_types, @@ -2578,7 +2582,7 @@ def CreatePrsForProxy(proxy, view, prs_types, picture_dir, picture_ext): print "OK" # Construct image file name pic_name = picture_dir + get_field_short_name(mesh_name) + "." + picture_ext - + # Show and dump the presentation into a graphics file process_prs_for_test(prs, view, pic_name, False) @@ -2596,7 +2600,7 @@ def CreatePrsForProxy(proxy, view, prs_types, picture_dir, picture_ext): print "OK" # Construct image file name pic_name = picture_dir + get_group_short_name(group) + "." + picture_ext - + # Show and dump the presentation into a graphics file process_prs_for_test(prs, view, pic_name, False) @@ -2607,12 +2611,9 @@ def CreatePrsForProxy(proxy, view, prs_types, picture_dir, picture_ext): if field_name == get_field_mesh_name(field): continue field_entity = get_field_entity(field) - # Clear fields selection state - proxy.AllArrays = [] - proxy.UpdatePipeline() # Select only the current field: # necessary for getting the right timestamps - proxy.AllArrays = field + proxy.AllArrays = [field] proxy.UpdatePipeline() # Get timestamps diff --git a/src/PV_SWIG/pvsimple.py b/src/PV_SWIG/pvsimple.py index b5f95d9f..64288435 100644 --- a/src/PV_SWIG/pvsimple.py +++ b/src/PV_SWIG/pvsimple.py @@ -47,8 +47,8 @@ def __getFromGUI(): def ShowParaviewView(): """ - If the import is made from SALOME embedded console, the ParaView application needs to - be instanciated to avoid a future crash. + If the import is made from SALOME embedded console, the ParaView application needs to + be instanciated to avoid a future crash. """ if __getFromGUI(): __my_log("Initializing ParaView main elements, please be patient ...") @@ -58,14 +58,14 @@ def ShowParaviewView(): if len(viewIds): sgPyQt.setViewVisible(viewIds[0], True) sgPyQt.activateView(viewIds[0]) - else: + else: sgPyQt.createView("ParaView") # Now let the GUI main loop process the initialization event posted above - sgPyQt.processEvents() + sgPyQt.processEvents() __my_log("ParaView initialized.") ## The below has to called BEFORE importing paraview!!! This is crazy, but it has to be. -ShowParaviewView() +ShowParaviewView() import paraview import pvserver @@ -97,7 +97,7 @@ def SalomeConnectToPVServer(): __my_log("*******************************************") raise e pass - + if __getFromGUI() < 1: # Only if not in GUI (otherwise the createView will do the connection) SalomeConnectToPVServer() @@ -108,4 +108,3 @@ for name in dir(simple): if not name.startswith("__"): globals()[name] = getattr(simple, name) del simple - diff --git a/test/VisuPrs/3D_viewer/A1.py b/test/VisuPrs/3D_viewer/A1.py index 0874da8a..57db2648 100644 --- a/test/VisuPrs/3D_viewer/A1.py +++ b/test/VisuPrs/3D_viewer/A1.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -34,9 +33,6 @@ picturedir = get_picture_dir("3D_viewer/A1") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -my_paravis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) diff --git a/test/VisuPrs/3D_viewer/A2.py b/test/VisuPrs/3D_viewer/A2.py index ef8e82e3..f75d2ef9 100644 --- a/test/VisuPrs/3D_viewer/A2.py +++ b/test/VisuPrs/3D_viewer/A2.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -34,9 +33,6 @@ picturedir = get_picture_dir("3D_viewer/A2") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -my_paravis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) diff --git a/test/VisuPrs/3D_viewer/A3.py b/test/VisuPrs/3D_viewer/A3.py index ca71daf9..2776f594 100644 --- a/test/VisuPrs/3D_viewer/A3.py +++ b/test/VisuPrs/3D_viewer/A3.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -34,9 +33,6 @@ picturedir = get_picture_dir("3D_viewer/A3") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -my_paravis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) @@ -48,6 +44,17 @@ print "file ", file_name print " --------------------------------- " OpenDataFile(file_name) +#reader = OpenDataFile(file_name) +#reader = MEDReader(FileName=file_name) +#keys = reader.GetProperty("FieldsTreeInfo")[::2] +#reader.AllArrays = [keys[0]] +#SetActiveSource(reader) + +#reader.UpdatePipelineInformation() +#from paraview import servermanager +#res = servermanager.Fetch(reader,0) +#print res + proxy = GetActiveSource() if proxy is None: raise RuntimeError("Error: can't import file.") @@ -56,6 +63,7 @@ else: represents = [RepresentationType.POINTS, RepresentationType.WIREFRAME,\ RepresentationType.SURFACE, RepresentationType.VOLUME] + shrinks = [0, 1] shadings = ["Flat", "Gouraud"] opacities = [1.0, 0.5, 0.0] @@ -66,10 +74,10 @@ field_name = 'vectoriel field' print "\nCreating stream_lines......." stream_lines = StreamLinesOnField(proxy, EntityType.CELL, -field_name, 1, is_colored=True) + field_name, 1, is_colored=True) stream_tracer = stream_lines.Input print "stream_tracer:", stream_tracer -stream_tracer.Input = None +#stream_tracer.Input = None stream_tracer.InitialStepLength = 0.00940275 stream_tracer.MaximumStreamlineLength = 140.373 stream_tracer.MaximumStepLength = 0.5319 diff --git a/test/VisuPrs/3D_viewer/A4.py b/test/VisuPrs/3D_viewer/A4.py index 6454dbb1..88858109 100644 --- a/test/VisuPrs/3D_viewer/A4.py +++ b/test/VisuPrs/3D_viewer/A4.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -33,8 +32,6 @@ picturedir = get_picture_dir("3D_viewer/A4") # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -my_paravis = paravis.myParavis # Get view my_view = GetRenderView() diff --git a/test/VisuPrs/3D_viewer/A5.py b/test/VisuPrs/3D_viewer/A5.py index ee1df61e..b0b63cf0 100644 --- a/test/VisuPrs/3D_viewer/A5.py +++ b/test/VisuPrs/3D_viewer/A5.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -34,9 +33,6 @@ picturedir = get_picture_dir("3D_viewer/A5") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -myParavis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) diff --git a/test/VisuPrs/3D_viewer/A6.py b/test/VisuPrs/3D_viewer/A6.py index 99013d16..e77a16bd 100644 --- a/test/VisuPrs/3D_viewer/A6.py +++ b/test/VisuPrs/3D_viewer/A6.py @@ -25,7 +25,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -35,9 +34,6 @@ picturedir = get_picture_dir("3D_viewer/A6") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -my_paravis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) diff --git a/test/VisuPrs/3D_viewer/A7.py b/test/VisuPrs/3D_viewer/A7.py index 018da24b..62d21fbe 100644 --- a/test/VisuPrs/3D_viewer/A7.py +++ b/test/VisuPrs/3D_viewer/A7.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -33,8 +32,6 @@ picturedir = get_picture_dir("3D_viewer/A7") # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -my_paravis = paravis.myParavis # Get view my_view = GetRenderView() diff --git a/test/VisuPrs/3D_viewer/A8.py b/test/VisuPrs/3D_viewer/A8.py index 6fdc9539..9a93c7f0 100644 --- a/test/VisuPrs/3D_viewer/A8.py +++ b/test/VisuPrs/3D_viewer/A8.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -33,8 +32,6 @@ picturedir = get_picture_dir("3D_viewer/A8") # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -my_paravis = paravis.myParavis # Get view my_view = GetRenderView() diff --git a/test/VisuPrs/3D_viewer/A9.py b/test/VisuPrs/3D_viewer/A9.py index 21159a14..02f61cb6 100644 --- a/test/VisuPrs/3D_viewer/A9.py +++ b/test/VisuPrs/3D_viewer/A9.py @@ -24,10 +24,8 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time - def check_value(prs, property_name, value, do_raise=1, compare_toler=-1.0): # compare just set value and the one got from presentation really_set_value = prs.GetPropertyValue(property_name) @@ -60,9 +58,6 @@ picturedir = get_picture_dir("3D_viewer/A9") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -myParavis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) diff --git a/test/VisuPrs/3D_viewer/B0.py b/test/VisuPrs/3D_viewer/B0.py index 0023dd6c..0dfbb2ff 100644 --- a/test/VisuPrs/3D_viewer/B0.py +++ b/test/VisuPrs/3D_viewer/B0.py @@ -24,7 +24,6 @@ from paravistest import * from presentations import * from pvsimple import * import sys -import pvserver as paravis import time # Directory for saving snapshots @@ -34,9 +33,6 @@ picturedir = get_picture_dir("3D_viewer/B0") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -myParavis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) diff --git a/test/VisuPrs/3D_viewer/B1.py b/test/VisuPrs/3D_viewer/B1.py index 2b4a9289..aeaa7fde 100644 --- a/test/VisuPrs/3D_viewer/B1.py +++ b/test/VisuPrs/3D_viewer/B1.py @@ -22,7 +22,6 @@ from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis import math @@ -47,8 +46,8 @@ view2.ViewSize = [w2, size2[1]] h = view1.ViewSize[1] view1.ViewSize = [h//2, w] view2.ViewSize = [h//2, w] -view1.ViewPosition = [0, h//2] -view1.ViewPosition = [0, 0] +#view1.ViewPosition = [0, h//2] +#view1.ViewPosition = [0, 0] Render(view1) Render(view2) diff --git a/test/VisuPrs/3D_viewer/B2.py b/test/VisuPrs/3D_viewer/B2.py index 2b0254f7..e172b874 100644 --- a/test/VisuPrs/3D_viewer/B2.py +++ b/test/VisuPrs/3D_viewer/B2.py @@ -26,8 +26,6 @@ import time from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("3D_viewer/B2") @@ -36,9 +34,6 @@ picturedir = get_picture_dir("3D_viewer/B2") if not picturedir.endswith(os.sep): picturedir += os.sep -#import file -myParavis = paravis.myParavis - # Get view my_view = GetRenderView() reset_view(my_view) diff --git a/test/VisuPrs/Animation/A0.py b/test/VisuPrs/Animation/A0.py index 7c369f3d..399f631c 100644 --- a/test/VisuPrs/Animation/A0.py +++ b/test/VisuPrs/Animation/A0.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/A0") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"A0_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 40 # correspond to set the speed of animation in VISU +scene.Duration = 40 # correspond to set the speed of animation in VISU scene.GoToFirst() scene.Loop = 0 print "Animation.................................", diff --git a/test/VisuPrs/Animation/A1.py b/test/VisuPrs/Animation/A1.py index aa01f5b3..de4a6727 100644 --- a/test/VisuPrs/Animation/A1.py +++ b/test/VisuPrs/Animation/A1.py @@ -22,12 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -my_paravis = paravis.myParavis # 1. TimeStamps.med import print 'Importing "TimeStamps.med"................', @@ -43,8 +40,8 @@ else: print "Creating Cut Lines........................", med_field = "vitesse" cutlines = CutLinesOnField(med_reader, EntityType.NODE, med_field, 1, - nb_lines = 20, - orientation1=Orientation.XY, orientation2=Orientation.ZX) + nb_lines = 20, + orientation1=Orientation.XY, orientation2=Orientation.ZX) if cutlines is None: print "FAILED" else: @@ -78,7 +75,7 @@ scene.Duration = 120 scene.Duration = 0 scene.Duration = 30 print "Duration ... ", scene.Duration - + print "Loop ... ", scene.Loop scene.Loop = 1 print "Loop ... ", scene.Loop diff --git a/test/VisuPrs/Animation/A2.py b/test/VisuPrs/Animation/A2.py index 9faa1533..96d95081 100644 --- a/test/VisuPrs/Animation/A2.py +++ b/test/VisuPrs/Animation/A2.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/A2") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"A2_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/A4.py b/test/VisuPrs/Animation/A4.py index 282756b0..e788dc9e 100644 --- a/test/VisuPrs/Animation/A4.py +++ b/test/VisuPrs/Animation/A4.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/A4") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"A4_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/A7.py b/test/VisuPrs/Animation/A7.py index 4b30ab51..055484a0 100644 --- a/test/VisuPrs/Animation/A7.py +++ b/test/VisuPrs/Animation/A7.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/A7") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"A7_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/A8.py b/test/VisuPrs/Animation/A8.py index 7b37bedf..a96470a6 100644 --- a/test/VisuPrs/Animation/A8.py +++ b/test/VisuPrs/Animation/A8.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/A8") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"A8_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/B2.py b/test/VisuPrs/Animation/B2.py index 491fd059..b7b7b137 100644 --- a/test/VisuPrs/Animation/B2.py +++ b/test/VisuPrs/Animation/B2.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/B2") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"B2_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/B5.py b/test/VisuPrs/Animation/B5.py index e147f295..e922a63b 100644 --- a/test/VisuPrs/Animation/B5.py +++ b/test/VisuPrs/Animation/B5.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/B5") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"B5_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/B6.py b/test/VisuPrs/Animation/B6.py index 3d1edc67..eaf4f62e 100644 --- a/test/VisuPrs/Animation/B6.py +++ b/test/VisuPrs/Animation/B6.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/B6") @@ -41,11 +37,14 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) reset_view(aView) Render(aView) @@ -64,26 +63,26 @@ if not picturedir.endswith(os.sep): picturedir += os.sep # Select only the current field: -aProxy.AllArrays = [] -aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] -aProxy.UpdatePipeline() - +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"B6_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/C0.py b/test/VisuPrs/Animation/C0.py index ee34d67a..06253d36 100644 --- a/test/VisuPrs/Animation/C0.py +++ b/test/VisuPrs/Animation/C0.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/C0") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"C0_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/C1.py b/test/VisuPrs/Animation/C1.py index dfb0d124..258e866b 100644 --- a/test/VisuPrs/Animation/C1.py +++ b/test/VisuPrs/Animation/C1.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/C1") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"C1_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/C3.py b/test/VisuPrs/Animation/C3.py index 29ce4d89..739ab53c 100644 --- a/test/VisuPrs/Animation/C3.py +++ b/test/VisuPrs/Animation/C3.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/C3") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"C3_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/C8.py b/test/VisuPrs/Animation/C8.py index 152b617e..ea3da19b 100644 --- a/test/VisuPrs/Animation/C8.py +++ b/test/VisuPrs/Animation/C8.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/C8") @@ -41,11 +37,14 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) reset_view(aView) Render(aView) @@ -64,26 +63,26 @@ if not picturedir.endswith(os.sep): picturedir += os.sep # Select only the current field: -aProxy.AllArrays = [] -aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] -aProxy.UpdatePipeline() - +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"C8_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/D1.py b/test/VisuPrs/Animation/D1.py index 07dddb11..b5cbda4c 100644 --- a/test/VisuPrs/Animation/D1.py +++ b/test/VisuPrs/Animation/D1.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/D1") @@ -42,11 +38,14 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) reset_view(aView) Render(aView) @@ -65,26 +64,26 @@ if not picturedir.endswith(os.sep): picturedir += os.sep # Select only the current field: -aProxy.AllArrays = [] -aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] -aProxy.UpdatePipeline() - +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"D1_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/D2.py b/test/VisuPrs/Animation/D2.py index dab7ad2f..e841d9b8 100644 --- a/test/VisuPrs/Animation/D2.py +++ b/test/VisuPrs/Animation/D2.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/D2") @@ -41,11 +37,14 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) reset_view(aView) Render(aView) @@ -64,26 +63,26 @@ if not picturedir.endswith(os.sep): picturedir += os.sep # Select only the current field: -aProxy.AllArrays = [] -aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] -aProxy.UpdatePipeline() - +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"D2_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/D6.py b/test/VisuPrs/Animation/D6.py index 6783d130..be5d35ba 100644 --- a/test/VisuPrs/Animation/D6.py +++ b/test/VisuPrs/Animation/D6.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/D6") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"D6_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/D9.py b/test/VisuPrs/Animation/D9.py index 8433f6e4..ed7adc2b 100644 --- a/test/VisuPrs/Animation/D9.py +++ b/test/VisuPrs/Animation/D9.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/D9") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"D9_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/E0.py b/test/VisuPrs/Animation/E0.py index 40c899e7..fcf740e9 100644 --- a/test/VisuPrs/Animation/E0.py +++ b/test/VisuPrs/Animation/E0.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/E0") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"E0_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/E4.py b/test/VisuPrs/Animation/E4.py index 83ecda20..5033a61d 100644 --- a/test/VisuPrs/Animation/E4.py +++ b/test/VisuPrs/Animation/E4.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -# import file -myParavis = paravis.myParavis # for saving snapshots picturedir = get_picture_dir("Animation/E4") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"E4_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/E7.py b/test/VisuPrs/Animation/E7.py index 9b0fa91a..e3cf65a0 100644 --- a/test/VisuPrs/Animation/E7.py +++ b/test/VisuPrs/Animation/E7.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/E7") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -63,22 +59,22 @@ print "Current format to save snapshots: ",my_format if not picturedir.endswith(os.sep): picturedir += os.sep - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"E7_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/E8.py b/test/VisuPrs/Animation/E8.py index f4464ebc..853ff250 100644 --- a/test/VisuPrs/Animation/E8.py +++ b/test/VisuPrs/Animation/E8.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -# import file -myParavis = paravis.myParavis # for saving snapshots picturedir = get_picture_dir("Animation/E8") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/pression@@][@@P0'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"E8_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/F2.py b/test/VisuPrs/Animation/F2.py index 662a2189..fc48273b 100644 --- a/test/VisuPrs/Animation/F2.py +++ b/test/VisuPrs/Animation/F2.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/F2") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"F2_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/F5.py b/test/VisuPrs/Animation/F5.py index 2468d449..a9d00be8 100644 --- a/test/VisuPrs/Animation/F5.py +++ b/test/VisuPrs/Animation/F5.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/F5") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"F5_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/F6.py b/test/VisuPrs/Animation/F6.py index af96144e..d551c310 100644 --- a/test/VisuPrs/Animation/F6.py +++ b/test/VisuPrs/Animation/F6.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/F6") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"F6_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/G0.py b/test/VisuPrs/Animation/G0.py index 838146d9..8bce57d8 100644 --- a/test/VisuPrs/Animation/G0.py +++ b/test/VisuPrs/Animation/G0.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/G0") @@ -41,11 +37,14 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) reset_view(aView) Render(aView) @@ -64,26 +63,26 @@ if not picturedir.endswith(os.sep): picturedir += os.sep # Select only the current field: -aProxy.AllArrays = [] -aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] -aProxy.UpdatePipeline() - +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"G0_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/G3.py b/test/VisuPrs/Animation/G3.py index 2ee9f1df..c31fb895 100644 --- a/test/VisuPrs/Animation/G3.py +++ b/test/VisuPrs/Animation/G3.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/G3") @@ -42,11 +38,14 @@ OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) reset_view(aView) Render(aView) @@ -65,26 +64,26 @@ if not picturedir.endswith(os.sep): picturedir += os.sep # Select only the current field: -aProxy.AllArrays = [] -aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] -aProxy.UpdatePipeline() - +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"G3_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/G4.py b/test/VisuPrs/Animation/G4.py index cd6e81f5..f1c29c0b 100644 --- a/test/VisuPrs/Animation/G4.py +++ b/test/VisuPrs/Animation/G4.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/G3") @@ -42,11 +38,14 @@ OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) reset_view(aView) Render(aView) @@ -65,26 +64,26 @@ if not picturedir.endswith(os.sep): picturedir += os.sep # Select only the current field: -aProxy.AllArrays = [] -aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] -aProxy.UpdatePipeline() - +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"G3_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/G8.py b/test/VisuPrs/Animation/G8.py index c0dd52d3..73d38bad 100644 --- a/test/VisuPrs/Animation/G8.py +++ b/test/VisuPrs/Animation/G8.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/G8") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"G8_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/H1.py b/test/VisuPrs/Animation/H1.py index 9d588955..beb2b77b 100644 --- a/test/VisuPrs/Animation/H1.py +++ b/test/VisuPrs/Animation/H1.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/H1") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"H1_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/Animation/H2.py b/test/VisuPrs/Animation/H2.py index 1d72b1f0..fc867cf7 100644 --- a/test/VisuPrs/Animation/H2.py +++ b/test/VisuPrs/Animation/H2.py @@ -22,13 +22,9 @@ import sys import os -from paravistest import * +from paravistest import * from presentations import * from pvsimple import * -import pvserver as paravis - -#import file -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir("Animation/H2") @@ -41,7 +37,7 @@ print " --------------------------------- " OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" print "Creating a Viewer.........................", @@ -68,22 +64,22 @@ aProxy.AllArrays = [] aProxy.UpdatePipeline() aProxy.AllArrays = ['TS0/dom/ComSup0/vitesse@@][@@P1'] aProxy.UpdatePipeline() - + # Animation creation and saving into set of files into picturedir scene = AnimateReader(aProxy,aView,picturedir+"H2_dom."+my_format) nb_frames = len(scene.TimeKeeper.TimestepValues) -pics = os.listdir(picturedir) +pics = os.listdir(picturedir) if len(pics) != nb_frames: print "FAILED!!! Number of made pictures is equal to ", len(pics), " instead of ", nb_frames - + for pic in pics: - os.remove(picturedir+pic) - -# Prepare animation performance + os.remove(picturedir+pic) + +# Prepare animation performance scene.PlayMode = 1 # set RealTime mode for animation performance # set period -scene.Duration = 30 # correspond to set the speed of animation in VISU +scene.Duration = 30 # correspond to set the speed of animation in VISU scene.GoToFirst() print "Animation.................................", scene.Play() diff --git a/test/VisuPrs/CutLines/A0.py b/test/VisuPrs/CutLines/A0.py index 27773a3c..09d8a6f0 100644 --- a/test/VisuPrs/CutLines/A0.py +++ b/test/VisuPrs/CutLines/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A0") +picturedir = get_picture_dir("CutLines/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A1.py b/test/VisuPrs/CutLines/A1.py index d33257aa..b0d7385c 100644 --- a/test/VisuPrs/CutLines/A1.py +++ b/test/VisuPrs/CutLines/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A1") +picturedir = get_picture_dir("CutLines/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A2.py b/test/VisuPrs/CutLines/A2.py index 5eb163f0..462db153 100755 --- a/test/VisuPrs/CutLines/A2.py +++ b/test/VisuPrs/CutLines/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A2") +picturedir = get_picture_dir("CutLines/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A3.py b/test/VisuPrs/CutLines/A3.py index 442b7b68..164a2e06 100755 --- a/test/VisuPrs/CutLines/A3.py +++ b/test/VisuPrs/CutLines/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A3") +picturedir = get_picture_dir("CutLines/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A4.py b/test/VisuPrs/CutLines/A4.py index 508e8cdd..10dbce20 100644 --- a/test/VisuPrs/CutLines/A4.py +++ b/test/VisuPrs/CutLines/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A4") +picturedir = get_picture_dir("CutLines/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A5.py b/test/VisuPrs/CutLines/A5.py index 2a47c6ed..0de9bdfb 100644 --- a/test/VisuPrs/CutLines/A5.py +++ b/test/VisuPrs/CutLines/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A5") +picturedir = get_picture_dir("CutLines/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A6.py b/test/VisuPrs/CutLines/A6.py index 35a6ab74..d41b36dc 100644 --- a/test/VisuPrs/CutLines/A6.py +++ b/test/VisuPrs/CutLines/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A6") +picturedir = get_picture_dir("CutLines/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A7.py b/test/VisuPrs/CutLines/A7.py index 00c3af2f..b6412e6f 100644 --- a/test/VisuPrs/CutLines/A7.py +++ b/test/VisuPrs/CutLines/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A7") +picturedir = get_picture_dir("CutLines/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A8.py b/test/VisuPrs/CutLines/A8.py index 82ab47a3..ec179208 100644 --- a/test/VisuPrs/CutLines/A8.py +++ b/test/VisuPrs/CutLines/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A8") +picturedir = get_picture_dir("CutLines/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/A9.py b/test/VisuPrs/CutLines/A9.py index cd576ed7..f259269d 100644 --- a/test/VisuPrs/CutLines/A9.py +++ b/test/VisuPrs/CutLines/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/A9") +picturedir = get_picture_dir("CutLines/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/B0.py b/test/VisuPrs/CutLines/B0.py index ffdf7575..714e27f4 100644 --- a/test/VisuPrs/CutLines/B0.py +++ b/test/VisuPrs/CutLines/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/B0") +picturedir = get_picture_dir("CutLines/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/B1.py b/test/VisuPrs/CutLines/B1.py index c3cae636..ed235800 100644 --- a/test/VisuPrs/CutLines/B1.py +++ b/test/VisuPrs/CutLines/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/B1") +picturedir = get_picture_dir("CutLines/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/B2.py b/test/VisuPrs/CutLines/B2.py index 0671229b..b36c244e 100644 --- a/test/VisuPrs/CutLines/B2.py +++ b/test/VisuPrs/CutLines/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/B2") +picturedir = get_picture_dir("CutLines/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E0.py b/test/VisuPrs/CutLines/E0.py index 067aed5d..c5e1565e 100644 --- a/test/VisuPrs/CutLines/E0.py +++ b/test/VisuPrs/CutLines/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E0") +picturedir = get_picture_dir("CutLines/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E1.py b/test/VisuPrs/CutLines/E1.py index cb7b1763..fb90bf20 100644 --- a/test/VisuPrs/CutLines/E1.py +++ b/test/VisuPrs/CutLines/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E1") +picturedir = get_picture_dir("CutLines/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E2.py b/test/VisuPrs/CutLines/E2.py index 2cbb1d3f..5856bc89 100644 --- a/test/VisuPrs/CutLines/E2.py +++ b/test/VisuPrs/CutLines/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E2") +picturedir = get_picture_dir("CutLines/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E3.py b/test/VisuPrs/CutLines/E3.py index 7f7a4929..dc3bfefd 100644 --- a/test/VisuPrs/CutLines/E3.py +++ b/test/VisuPrs/CutLines/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E3") +picturedir = get_picture_dir("CutLines/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E4.py b/test/VisuPrs/CutLines/E4.py index c49ebb52..abaa584a 100644 --- a/test/VisuPrs/CutLines/E4.py +++ b/test/VisuPrs/CutLines/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E4") +picturedir = get_picture_dir("CutLines/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E5.py b/test/VisuPrs/CutLines/E5.py index ebd6a0a8..96bbf60e 100644 --- a/test/VisuPrs/CutLines/E5.py +++ b/test/VisuPrs/CutLines/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E5") +picturedir = get_picture_dir("CutLines/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E6.py b/test/VisuPrs/CutLines/E6.py index e50b6b54..c21d1b4c 100644 --- a/test/VisuPrs/CutLines/E6.py +++ b/test/VisuPrs/CutLines/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E6") +picturedir = get_picture_dir("CutLines/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E7.py b/test/VisuPrs/CutLines/E7.py index f45a5e1d..2e49d0fb 100644 --- a/test/VisuPrs/CutLines/E7.py +++ b/test/VisuPrs/CutLines/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E7") +picturedir = get_picture_dir("CutLines/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E8.py b/test/VisuPrs/CutLines/E8.py index fc891f47..9fd867b4 100644 --- a/test/VisuPrs/CutLines/E8.py +++ b/test/VisuPrs/CutLines/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E8") +picturedir = get_picture_dir("CutLines/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/E9.py b/test/VisuPrs/CutLines/E9.py index 6886d868..5b6f6369 100644 --- a/test/VisuPrs/CutLines/E9.py +++ b/test/VisuPrs/CutLines/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/E9") +picturedir = get_picture_dir("CutLines/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F1.py b/test/VisuPrs/CutLines/F1.py index 835c0ae7..a7d1a391 100644 --- a/test/VisuPrs/CutLines/F1.py +++ b/test/VisuPrs/CutLines/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F1") +picturedir = get_picture_dir("CutLines/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F2.py b/test/VisuPrs/CutLines/F2.py index ad4eeb8b..bf225757 100644 --- a/test/VisuPrs/CutLines/F2.py +++ b/test/VisuPrs/CutLines/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F2") +picturedir = get_picture_dir("CutLines/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F3.py b/test/VisuPrs/CutLines/F3.py index 4a8fa961..c1248f33 100644 --- a/test/VisuPrs/CutLines/F3.py +++ b/test/VisuPrs/CutLines/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F3") +picturedir = get_picture_dir("CutLines/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F4.py b/test/VisuPrs/CutLines/F4.py index 916baf64..d634e7ca 100644 --- a/test/VisuPrs/CutLines/F4.py +++ b/test/VisuPrs/CutLines/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F4") +picturedir = get_picture_dir("CutLines/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F5.py b/test/VisuPrs/CutLines/F5.py index 5aa78231..6f521a51 100644 --- a/test/VisuPrs/CutLines/F5.py +++ b/test/VisuPrs/CutLines/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F5") +picturedir = get_picture_dir("CutLines/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F6.py b/test/VisuPrs/CutLines/F6.py index b2ab3133..0d40cf12 100644 --- a/test/VisuPrs/CutLines/F6.py +++ b/test/VisuPrs/CutLines/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F6") +picturedir = get_picture_dir("CutLines/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F7.py b/test/VisuPrs/CutLines/F7.py index f1efd8c9..0480624c 100644 --- a/test/VisuPrs/CutLines/F7.py +++ b/test/VisuPrs/CutLines/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F7") +picturedir = get_picture_dir("CutLines/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F8.py b/test/VisuPrs/CutLines/F8.py index 1e06a472..1e5c33b2 100755 --- a/test/VisuPrs/CutLines/F8.py +++ b/test/VisuPrs/CutLines/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F8") +picturedir = get_picture_dir("CutLines/F8") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/F9.py b/test/VisuPrs/CutLines/F9.py index d231eb9d..ee5ce759 100644 --- a/test/VisuPrs/CutLines/F9.py +++ b/test/VisuPrs/CutLines/F9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/F9") +picturedir = get_picture_dir("CutLines/F9") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/G0.py b/test/VisuPrs/CutLines/G0.py index 98f85a49..c332394e 100644 --- a/test/VisuPrs/CutLines/G0.py +++ b/test/VisuPrs/CutLines/G0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/G0") +picturedir = get_picture_dir("CutLines/G0") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/G1.py b/test/VisuPrs/CutLines/G1.py index e34c2062..ae4c823d 100644 --- a/test/VisuPrs/CutLines/G1.py +++ b/test/VisuPrs/CutLines/G1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutLines/G1") +picturedir = get_picture_dir("CutLines/G1") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTLINES], picturedir, pictureext) diff --git a/test/VisuPrs/CutLines/G2.py b/test/VisuPrs/CutLines/G2.py index 56d04010..d2db5967 100644 --- a/test/VisuPrs/CutLines/G2.py +++ b/test/VisuPrs/CutLines/G2.py @@ -24,10 +24,7 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("CutLines/G2") theFileName = datadir + "Bug829_resu_mode.med" @@ -40,7 +37,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" # Get viewScalarMap aView = GetRenderView() @@ -59,19 +56,19 @@ for i in range(1,11): #display only current scalar map aPrs.Visibility=1 reset_view(aView) - Render(aView) - + Render(aView) + # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep prs_type = PrsTypeEnum.CUTLINES - + # Get name of presentation type - prs_name = PrsTypeEnum.get_name(prs_type) + prs_name = PrsTypeEnum.get_name(prs_type) f_prs_type = prs_name.replace(' ', '').upper() # Construct image file name pic_name = picturedir + aFieldName + "_" + str(i) + "_" + f_prs_type + "." + pictureext - + # Show and record the presentation process_prs_for_test(aPrs, aView, pic_name) diff --git a/test/VisuPrs/CutPlanes/A0.py b/test/VisuPrs/CutPlanes/A0.py index 0522af55..edb05a41 100644 --- a/test/VisuPrs/CutPlanes/A0.py +++ b/test/VisuPrs/CutPlanes/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A0") +picturedir = get_picture_dir("CutPlanes/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A1.py b/test/VisuPrs/CutPlanes/A1.py index a4fa56a2..f83a477c 100644 --- a/test/VisuPrs/CutPlanes/A1.py +++ b/test/VisuPrs/CutPlanes/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A1") +picturedir = get_picture_dir("CutPlanes/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A2.py b/test/VisuPrs/CutPlanes/A2.py index c61e62f8..b83b51d8 100755 --- a/test/VisuPrs/CutPlanes/A2.py +++ b/test/VisuPrs/CutPlanes/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A2") +picturedir = get_picture_dir("CutPlanes/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A3.py b/test/VisuPrs/CutPlanes/A3.py index 18052c1c..5112d192 100755 --- a/test/VisuPrs/CutPlanes/A3.py +++ b/test/VisuPrs/CutPlanes/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A3") +picturedir = get_picture_dir("CutPlanes/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A4.py b/test/VisuPrs/CutPlanes/A4.py index c879ed9c..3eda51e4 100644 --- a/test/VisuPrs/CutPlanes/A4.py +++ b/test/VisuPrs/CutPlanes/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A4") +picturedir = get_picture_dir("CutPlanes/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A5.py b/test/VisuPrs/CutPlanes/A5.py index 36113a1a..7368216c 100644 --- a/test/VisuPrs/CutPlanes/A5.py +++ b/test/VisuPrs/CutPlanes/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A5") +picturedir = get_picture_dir("CutPlanes/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A6.py b/test/VisuPrs/CutPlanes/A6.py index 9f95c0a7..9b92494f 100644 --- a/test/VisuPrs/CutPlanes/A6.py +++ b/test/VisuPrs/CutPlanes/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A6") +picturedir = get_picture_dir("CutPlanes/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A7.py b/test/VisuPrs/CutPlanes/A7.py index c6c8e293..e56d3d79 100644 --- a/test/VisuPrs/CutPlanes/A7.py +++ b/test/VisuPrs/CutPlanes/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A7") +picturedir = get_picture_dir("CutPlanes/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A8.py b/test/VisuPrs/CutPlanes/A8.py index 68e6a3b8..0cef7ba6 100644 --- a/test/VisuPrs/CutPlanes/A8.py +++ b/test/VisuPrs/CutPlanes/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A8") +picturedir = get_picture_dir("CutPlanes/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/A9.py b/test/VisuPrs/CutPlanes/A9.py index cea9768f..5ad2a18e 100644 --- a/test/VisuPrs/CutPlanes/A9.py +++ b/test/VisuPrs/CutPlanes/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/A9") +picturedir = get_picture_dir("CutPlanes/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/B0.py b/test/VisuPrs/CutPlanes/B0.py index 90ea21da..e7e9e222 100644 --- a/test/VisuPrs/CutPlanes/B0.py +++ b/test/VisuPrs/CutPlanes/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/B0") +picturedir = get_picture_dir("CutPlanes/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/B1.py b/test/VisuPrs/CutPlanes/B1.py index 4d566f30..4d4010e3 100644 --- a/test/VisuPrs/CutPlanes/B1.py +++ b/test/VisuPrs/CutPlanes/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/B1") +picturedir = get_picture_dir("CutPlanes/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/B2.py b/test/VisuPrs/CutPlanes/B2.py index 7292f275..d012ffe3 100644 --- a/test/VisuPrs/CutPlanes/B2.py +++ b/test/VisuPrs/CutPlanes/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/B2") +picturedir = get_picture_dir("CutPlanes/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/B3.py b/test/VisuPrs/CutPlanes/B3.py index 7ac8f998..adb561c6 100644 --- a/test/VisuPrs/CutPlanes/B3.py +++ b/test/VisuPrs/CutPlanes/B3.py @@ -21,18 +21,15 @@ from paravistest import datadir from presentations import CutPlanesOnField, EntityType -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - #====================Stage1: Importing MED file==================== print "**** Stage1: Importing MED file" print 'Import "ResOK_0000.med"...............', file_path = datadir + "ResOK_0000.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/CutPlanes/E0.py b/test/VisuPrs/CutPlanes/E0.py index f4935545..04d1d52a 100644 --- a/test/VisuPrs/CutPlanes/E0.py +++ b/test/VisuPrs/CutPlanes/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E0") +picturedir = get_picture_dir("CutPlanes/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E1.py b/test/VisuPrs/CutPlanes/E1.py index 77708f76..9dc3c773 100644 --- a/test/VisuPrs/CutPlanes/E1.py +++ b/test/VisuPrs/CutPlanes/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E1") +picturedir = get_picture_dir("CutPlanes/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E2.py b/test/VisuPrs/CutPlanes/E2.py index 1a415852..7ae71597 100644 --- a/test/VisuPrs/CutPlanes/E2.py +++ b/test/VisuPrs/CutPlanes/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E2") +picturedir = get_picture_dir("CutPlanes/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E3.py b/test/VisuPrs/CutPlanes/E3.py index f983128b..0a315831 100644 --- a/test/VisuPrs/CutPlanes/E3.py +++ b/test/VisuPrs/CutPlanes/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E3") +picturedir = get_picture_dir("CutPlanes/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E4.py b/test/VisuPrs/CutPlanes/E4.py index 265a86ee..22d1b851 100644 --- a/test/VisuPrs/CutPlanes/E4.py +++ b/test/VisuPrs/CutPlanes/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E4") +picturedir = get_picture_dir("CutPlanes/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E5.py b/test/VisuPrs/CutPlanes/E5.py index 0be44d2a..ca0e27e8 100644 --- a/test/VisuPrs/CutPlanes/E5.py +++ b/test/VisuPrs/CutPlanes/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E5") +picturedir = get_picture_dir("CutPlanes/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E6.py b/test/VisuPrs/CutPlanes/E6.py index 31d7669b..b2d73c87 100644 --- a/test/VisuPrs/CutPlanes/E6.py +++ b/test/VisuPrs/CutPlanes/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E6") +picturedir = get_picture_dir("CutPlanes/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E7.py b/test/VisuPrs/CutPlanes/E7.py index 4195023c..2e76102a 100644 --- a/test/VisuPrs/CutPlanes/E7.py +++ b/test/VisuPrs/CutPlanes/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E7") +picturedir = get_picture_dir("CutPlanes/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E8.py b/test/VisuPrs/CutPlanes/E8.py index 77c557b2..2f391ae1 100644 --- a/test/VisuPrs/CutPlanes/E8.py +++ b/test/VisuPrs/CutPlanes/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E8") +picturedir = get_picture_dir("CutPlanes/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/E9.py b/test/VisuPrs/CutPlanes/E9.py index 6aab6862..ac7f4119 100644 --- a/test/VisuPrs/CutPlanes/E9.py +++ b/test/VisuPrs/CutPlanes/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/E9") +picturedir = get_picture_dir("CutPlanes/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F1.py b/test/VisuPrs/CutPlanes/F1.py index b20c8156..f31651ff 100644 --- a/test/VisuPrs/CutPlanes/F1.py +++ b/test/VisuPrs/CutPlanes/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F1") +picturedir = get_picture_dir("CutPlanes/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F2.py b/test/VisuPrs/CutPlanes/F2.py index 09f32269..877a370f 100644 --- a/test/VisuPrs/CutPlanes/F2.py +++ b/test/VisuPrs/CutPlanes/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F2") +picturedir = get_picture_dir("CutPlanes/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F3.py b/test/VisuPrs/CutPlanes/F3.py index f25d56d5..94e6d275 100644 --- a/test/VisuPrs/CutPlanes/F3.py +++ b/test/VisuPrs/CutPlanes/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F3") +picturedir = get_picture_dir("CutPlanes/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F4.py b/test/VisuPrs/CutPlanes/F4.py index fc00920c..c94e9c8b 100644 --- a/test/VisuPrs/CutPlanes/F4.py +++ b/test/VisuPrs/CutPlanes/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F4") +picturedir = get_picture_dir("CutPlanes/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F5.py b/test/VisuPrs/CutPlanes/F5.py index db03318b..2328e320 100644 --- a/test/VisuPrs/CutPlanes/F5.py +++ b/test/VisuPrs/CutPlanes/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F5") +picturedir = get_picture_dir("CutPlanes/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F6.py b/test/VisuPrs/CutPlanes/F6.py index 619892c6..bdd1f1ef 100644 --- a/test/VisuPrs/CutPlanes/F6.py +++ b/test/VisuPrs/CutPlanes/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F6") +picturedir = get_picture_dir("CutPlanes/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F7.py b/test/VisuPrs/CutPlanes/F7.py index 6f9b7768..86917ebd 100755 --- a/test/VisuPrs/CutPlanes/F7.py +++ b/test/VisuPrs/CutPlanes/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F7") +picturedir = get_picture_dir("CutPlanes/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F8.py b/test/VisuPrs/CutPlanes/F8.py index b9a90fad..b3229726 100644 --- a/test/VisuPrs/CutPlanes/F8.py +++ b/test/VisuPrs/CutPlanes/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F8") +picturedir = get_picture_dir("CutPlanes/F8") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/F9.py b/test/VisuPrs/CutPlanes/F9.py index 32ed20ce..bd57c0df 100644 --- a/test/VisuPrs/CutPlanes/F9.py +++ b/test/VisuPrs/CutPlanes/F9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/F9") +picturedir = get_picture_dir("CutPlanes/F9") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/G0.py b/test/VisuPrs/CutPlanes/G0.py index 843e555a..6dd1768e 100644 --- a/test/VisuPrs/CutPlanes/G0.py +++ b/test/VisuPrs/CutPlanes/G0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/G0") +picturedir = get_picture_dir("CutPlanes/G0") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/G1.py b/test/VisuPrs/CutPlanes/G1.py index 2562125a..00c5c2d2 100644 --- a/test/VisuPrs/CutPlanes/G1.py +++ b/test/VisuPrs/CutPlanes/G1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("CutPlanes/G1") +picturedir = get_picture_dir("CutPlanes/G1") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/CutPlanes/G2.py b/test/VisuPrs/CutPlanes/G2.py index 862c866b..52b1f0b3 100644 --- a/test/VisuPrs/CutPlanes/G2.py +++ b/test/VisuPrs/CutPlanes/G2.py @@ -24,10 +24,7 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("CutPlanes/G2") theFileName = datadir + "Bug829_resu_mode.med" @@ -40,7 +37,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" # Get viewScalarMap aView = GetRenderView() @@ -59,19 +56,19 @@ for i in range(1,11): #display only current scalar map aPrs.Visibility=1 reset_view(aView) - Render(aView) - + Render(aView) + # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep prs_type = PrsTypeEnum.CUTPLANES - + # Get name of presentation type - prs_name = PrsTypeEnum.get_name(prs_type) + prs_name = PrsTypeEnum.get_name(prs_type) f_prs_type = prs_name.replace(' ', '').upper() # Construct image file name pic_name = picturedir + aFieldName + "_" + str(i) + "_" + f_prs_type + "." + pictureext - + # Show and record the presentation process_prs_for_test(aPrs, aView, pic_name) diff --git a/test/VisuPrs/DeformedShape/A0.py b/test/VisuPrs/DeformedShape/A0.py index 48fbb526..6af9adfa 100644 --- a/test/VisuPrs/DeformedShape/A0.py +++ b/test/VisuPrs/DeformedShape/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A0") +picturedir = get_picture_dir("DeformedShape/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A1.py b/test/VisuPrs/DeformedShape/A1.py index 0881584b..19a3cdfd 100644 --- a/test/VisuPrs/DeformedShape/A1.py +++ b/test/VisuPrs/DeformedShape/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A1") +picturedir = get_picture_dir("DeformedShape/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A2.py b/test/VisuPrs/DeformedShape/A2.py index 521ea2d9..62e0e776 100755 --- a/test/VisuPrs/DeformedShape/A2.py +++ b/test/VisuPrs/DeformedShape/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A2") +picturedir = get_picture_dir("DeformedShape/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A3.py b/test/VisuPrs/DeformedShape/A3.py index 25ddf99a..a4ba1363 100755 --- a/test/VisuPrs/DeformedShape/A3.py +++ b/test/VisuPrs/DeformedShape/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A3") +picturedir = get_picture_dir("DeformedShape/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A4.py b/test/VisuPrs/DeformedShape/A4.py index d86f261b..20a7bdc9 100755 --- a/test/VisuPrs/DeformedShape/A4.py +++ b/test/VisuPrs/DeformedShape/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A4") +picturedir = get_picture_dir("DeformedShape/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A5.py b/test/VisuPrs/DeformedShape/A5.py index d583f3d3..9d515472 100644 --- a/test/VisuPrs/DeformedShape/A5.py +++ b/test/VisuPrs/DeformedShape/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A5") +picturedir = get_picture_dir("DeformedShape/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A6.py b/test/VisuPrs/DeformedShape/A6.py index afafea9c..485a8840 100755 --- a/test/VisuPrs/DeformedShape/A6.py +++ b/test/VisuPrs/DeformedShape/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A6") +picturedir = get_picture_dir("DeformedShape/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A7.py b/test/VisuPrs/DeformedShape/A7.py index 81193c98..f645b6b2 100644 --- a/test/VisuPrs/DeformedShape/A7.py +++ b/test/VisuPrs/DeformedShape/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A7") +picturedir = get_picture_dir("DeformedShape/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A8.py b/test/VisuPrs/DeformedShape/A8.py index 3aa703d2..863fdfeb 100644 --- a/test/VisuPrs/DeformedShape/A8.py +++ b/test/VisuPrs/DeformedShape/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A8") +picturedir = get_picture_dir("DeformedShape/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/A9.py b/test/VisuPrs/DeformedShape/A9.py index 9f3aa081..78ec5bf4 100644 --- a/test/VisuPrs/DeformedShape/A9.py +++ b/test/VisuPrs/DeformedShape/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/A9") +picturedir = get_picture_dir("DeformedShape/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/B0.py b/test/VisuPrs/DeformedShape/B0.py index 6d106d69..e436eb6c 100644 --- a/test/VisuPrs/DeformedShape/B0.py +++ b/test/VisuPrs/DeformedShape/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/B0") +picturedir = get_picture_dir("DeformedShape/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/B1.py b/test/VisuPrs/DeformedShape/B1.py index 0b9841ed..7f633c6d 100644 --- a/test/VisuPrs/DeformedShape/B1.py +++ b/test/VisuPrs/DeformedShape/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/B1") +picturedir = get_picture_dir("DeformedShape/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/B2.py b/test/VisuPrs/DeformedShape/B2.py index 7566a214..6845c45b 100644 --- a/test/VisuPrs/DeformedShape/B2.py +++ b/test/VisuPrs/DeformedShape/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/B2") +picturedir = get_picture_dir("DeformedShape/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/B3.py b/test/VisuPrs/DeformedShape/B3.py index d8512d10..5434d9b9 100755 --- a/test/VisuPrs/DeformedShape/B3.py +++ b/test/VisuPrs/DeformedShape/B3.py @@ -21,19 +21,15 @@ from paravistest import datadir from presentations import DeformedShapeOnField, EntityType -import pvserver as paravis import pvsimple - -my_paravis = paravis.myParavis - #====================Stage1: Import from MED file in ParaVis============ print "**** Stage1: Import from MED file in ParaVis" print 'Import "Tria3.med"....................', file_path = datadir + "Tria3.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -86,26 +82,26 @@ print "Scale: ", warp_vector.ScaleFactor #====================Stage4: Coloring method of Deformed Shape=========== print "**** Stage4: Coloring of Deformed Shape" -color_array = defshape.ColorArrayName +color_array = defshape.ColorArrayName[1] if color_array: print "Default shape is colored by array: ", color_array else: print "Default shape is colored by solid color: ", defshape.AmbientColor print "Set colored by array mode .... ", -defshape.ColorArrayName = field_name +defshape.ColorArrayName = ("CELLS", field_name) pvsimple.Render() -if defshape.ColorArrayName == field_name: +if defshape.ColorArrayName[1] == field_name: print "OK" else: print "FAILED" print "Set colored by solid color mode .... ", -defshape.ColorArrayName = '' +defshape.ColorArrayName = (None, '') pvsimple.Render() -if defshape.ColorArrayName: +if defshape.ColorArrayName[1]: print "FAILED" else: print "OK" diff --git a/test/VisuPrs/DeformedShape/B4.py b/test/VisuPrs/DeformedShape/B4.py index 47c677a5..6f2f0488 100644 --- a/test/VisuPrs/DeformedShape/B4.py +++ b/test/VisuPrs/DeformedShape/B4.py @@ -21,19 +21,15 @@ from paravistest import datadir from presentations import DeformedShapeOnField, EntityType -import pvserver as paravis import pvsimple - -my_paravis = paravis.myParavis - #====================Stage1: Import from MED file in ParaVis============ print "**** Stage1: Import from MED file in ParaVis" print 'Import "Hexa8.med"....................', file_path = datadir + "Hexa8.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/DeformedShape/E0.py b/test/VisuPrs/DeformedShape/E0.py index 3ec4694a..02370932 100644 --- a/test/VisuPrs/DeformedShape/E0.py +++ b/test/VisuPrs/DeformedShape/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E0") +picturedir = get_picture_dir("DeformedShape/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E1.py b/test/VisuPrs/DeformedShape/E1.py index 75c3f3fd..a8c59117 100644 --- a/test/VisuPrs/DeformedShape/E1.py +++ b/test/VisuPrs/DeformedShape/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E1") +picturedir = get_picture_dir("DeformedShape/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E2.py b/test/VisuPrs/DeformedShape/E2.py index d171bc05..3fc61e6b 100644 --- a/test/VisuPrs/DeformedShape/E2.py +++ b/test/VisuPrs/DeformedShape/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E2") +picturedir = get_picture_dir("DeformedShape/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E3.py b/test/VisuPrs/DeformedShape/E3.py index 345ad1fe..5c5dea69 100755 --- a/test/VisuPrs/DeformedShape/E3.py +++ b/test/VisuPrs/DeformedShape/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E3") +picturedir = get_picture_dir("DeformedShape/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E4.py b/test/VisuPrs/DeformedShape/E4.py index 4bb28968..7ef42acf 100644 --- a/test/VisuPrs/DeformedShape/E4.py +++ b/test/VisuPrs/DeformedShape/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E4") +picturedir = get_picture_dir("DeformedShape/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E5.py b/test/VisuPrs/DeformedShape/E5.py index 4ddcfe6c..9a1952a3 100644 --- a/test/VisuPrs/DeformedShape/E5.py +++ b/test/VisuPrs/DeformedShape/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E5") +picturedir = get_picture_dir("DeformedShape/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E6.py b/test/VisuPrs/DeformedShape/E6.py index e8f7a4bc..1f670b6b 100644 --- a/test/VisuPrs/DeformedShape/E6.py +++ b/test/VisuPrs/DeformedShape/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E6") +picturedir = get_picture_dir("DeformedShape/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E7.py b/test/VisuPrs/DeformedShape/E7.py index 9e90e2d7..fc167e7f 100644 --- a/test/VisuPrs/DeformedShape/E7.py +++ b/test/VisuPrs/DeformedShape/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E7") +picturedir = get_picture_dir("DeformedShape/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E8.py b/test/VisuPrs/DeformedShape/E8.py index d6a2588f..f6b12e1e 100644 --- a/test/VisuPrs/DeformedShape/E8.py +++ b/test/VisuPrs/DeformedShape/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E8") +picturedir = get_picture_dir("DeformedShape/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/E9.py b/test/VisuPrs/DeformedShape/E9.py index 39da3fd6..33abb955 100644 --- a/test/VisuPrs/DeformedShape/E9.py +++ b/test/VisuPrs/DeformedShape/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/E9") +picturedir = get_picture_dir("DeformedShape/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F1.py b/test/VisuPrs/DeformedShape/F1.py index 0ed6f0a2..42f61c3e 100644 --- a/test/VisuPrs/DeformedShape/F1.py +++ b/test/VisuPrs/DeformedShape/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F1") +picturedir = get_picture_dir("DeformedShape/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F2.py b/test/VisuPrs/DeformedShape/F2.py index 6f457f1a..e7005273 100644 --- a/test/VisuPrs/DeformedShape/F2.py +++ b/test/VisuPrs/DeformedShape/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F2") +picturedir = get_picture_dir("DeformedShape/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F3.py b/test/VisuPrs/DeformedShape/F3.py index b2211a22..515f664f 100644 --- a/test/VisuPrs/DeformedShape/F3.py +++ b/test/VisuPrs/DeformedShape/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F3") +picturedir = get_picture_dir("DeformedShape/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F4.py b/test/VisuPrs/DeformedShape/F4.py index 680bc793..aabadf52 100644 --- a/test/VisuPrs/DeformedShape/F4.py +++ b/test/VisuPrs/DeformedShape/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F4") +picturedir = get_picture_dir("DeformedShape/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F5.py b/test/VisuPrs/DeformedShape/F5.py index 5bbe3ccb..34b0d2f6 100644 --- a/test/VisuPrs/DeformedShape/F5.py +++ b/test/VisuPrs/DeformedShape/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F5") +picturedir = get_picture_dir("DeformedShape/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F6.py b/test/VisuPrs/DeformedShape/F6.py index 7f3f7e7e..21636005 100644 --- a/test/VisuPrs/DeformedShape/F6.py +++ b/test/VisuPrs/DeformedShape/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F6") +picturedir = get_picture_dir("DeformedShape/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F7.py b/test/VisuPrs/DeformedShape/F7.py index 7e050951..3b79a0b3 100755 --- a/test/VisuPrs/DeformedShape/F7.py +++ b/test/VisuPrs/DeformedShape/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F7") +picturedir = get_picture_dir("DeformedShape/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F8.py b/test/VisuPrs/DeformedShape/F8.py index beebcc65..8b053649 100644 --- a/test/VisuPrs/DeformedShape/F8.py +++ b/test/VisuPrs/DeformedShape/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("DeformedShape/F8") +picturedir = get_picture_dir("DeformedShape/F8") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPE], picturedir, pictureext) diff --git a/test/VisuPrs/DeformedShape/F9.py b/test/VisuPrs/DeformedShape/F9.py index d284b28f..53c5f99b 100644 --- a/test/VisuPrs/DeformedShape/F9.py +++ b/test/VisuPrs/DeformedShape/F9.py @@ -24,10 +24,6 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("DeformedShape/F9") @@ -41,7 +37,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" # Get view aView = GetRenderView() @@ -58,12 +54,12 @@ for colored in [False,True]: colored_str = "_colored" for i in range(1,11): hide_all(aView, True) - aPrs = DeformedShapeOnField(aProxy, aFieldEntity, aFieldName, i, is_colored=colored) + aPrs = DeformedShapeOnField(aProxy, aFieldEntity, aFieldName, i, is_colored=colored) if aPrs is None: raise RuntimeError, "Presentation is None!!!" # display only current deformed shape #display_only(aView,aPrs) - aPrs.Visibility =1 + aPrs.Visibility =1 reset_view(aView) Render(aView) @@ -71,9 +67,9 @@ for colored in [False,True]: if not picturedir.endswith(os.sep): picturedir += os.sep prs_type = PrsTypeEnum.DEFORMEDSHAPE - + # Get name of presentation type - prs_name = PrsTypeEnum.get_name(prs_type) + prs_name = PrsTypeEnum.get_name(prs_type) f_prs_type = prs_name.replace(' ', '').upper() # Construct image file name pic_name = picturedir + aFieldName+colored_str + "_" + str(i) + "_" + f_prs_type + "." + pictureext diff --git a/test/VisuPrs/GaussPoints/A0.py b/test/VisuPrs/GaussPoints/A0.py index 1b16713a..184d2134 100644 --- a/test/VisuPrs/GaussPoints/A0.py +++ b/test/VisuPrs/GaussPoints/A0.py @@ -25,35 +25,33 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A0") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "hexa_28320_ELEM.med" field_name = "pression_elem_dom_pb1" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") +view = pvsimple.GetRenderView() +time = get_time(med_reader, timestamp_nb) +view.ViewTime = time +pvsimple.UpdatePipeline(time=time, proxy=med_reader) + # Create Gauss Points presentation prs = GaussPointsOnField(med_reader, EntityType.CELL, field_name, timestamp_nb) if prs is None: raise RuntimeError, "Created presentation is None!!!" # Display presentation and get snapshot -view = pvsimple.GetRenderView() -time = get_time(med_reader, timestamp_nb) - pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/A1.py b/test/VisuPrs/GaussPoints/A1.py index cce5f7eb..b93bc9cf 100644 --- a/test/VisuPrs/GaussPoints/A1.py +++ b/test/VisuPrs/GaussPoints/A1.py @@ -25,22 +25,20 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A1") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "pointe.med" field_name = "fieldcelldoublescalar" #field_name = "fieldcelldoublevector" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/A2.py b/test/VisuPrs/GaussPoints/A2.py index 1b793712..bab9b831 100644 --- a/test/VisuPrs/GaussPoints/A2.py +++ b/test/VisuPrs/GaussPoints/A2.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A2") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "Fields_group3D.med" field_name = "scalar field" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ time = get_time(med_reader, timestamp_nb) pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/A3.py b/test/VisuPrs/GaussPoints/A3.py index 2dc8dd1e..f906dedf 100644 --- a/test/VisuPrs/GaussPoints/A3.py +++ b/test/VisuPrs/GaussPoints/A3.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A3") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "Hexa8.med" field_name = "scalar field" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ time = get_time(med_reader, timestamp_nb) pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/A4.py b/test/VisuPrs/GaussPoints/A4.py index b9ddf67f..c70bb50c 100644 --- a/test/VisuPrs/GaussPoints/A4.py +++ b/test/VisuPrs/GaussPoints/A4.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A4") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "Penta6.med" field_name = "scalar field" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ time = get_time(med_reader, timestamp_nb) pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/A5.py b/test/VisuPrs/GaussPoints/A5.py index e5e49bac..6bc75d00 100644 --- a/test/VisuPrs/GaussPoints/A5.py +++ b/test/VisuPrs/GaussPoints/A5.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A5") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "Tetra4.med" field_name = "scalar field" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ time = get_time(med_reader, timestamp_nb) pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/A6.py b/test/VisuPrs/GaussPoints/A6.py index 61952d03..4862b19c 100644 --- a/test/VisuPrs/GaussPoints/A6.py +++ b/test/VisuPrs/GaussPoints/A6.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A6") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "Tria3.med" field_name = "scalar field" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ time = get_time(med_reader, timestamp_nb) pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/A7.py b/test/VisuPrs/GaussPoints/A7.py index a9562f19..2f2bc8f2 100644 --- a/test/VisuPrs/GaussPoints/A7.py +++ b/test/VisuPrs/GaussPoints/A7.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A7") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "Quad4.med" field_name = "scalar field" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ time = get_time(med_reader, timestamp_nb) pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/A9.py b/test/VisuPrs/GaussPoints/A9.py index 86ccf23d..57347b0f 100644 --- a/test/VisuPrs/GaussPoints/A9.py +++ b/test/VisuPrs/GaussPoints/A9.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/A9") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "carre_en_quad4_seg2_fields.med" field_name = "AREA" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ time = get_time(med_reader, timestamp_nb) pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/GaussPoints/B0.py b/test/VisuPrs/GaussPoints/B0.py index 7d939ef6..e0bb57a7 100644 --- a/test/VisuPrs/GaussPoints/B0.py +++ b/test/VisuPrs/GaussPoints/B0.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B0") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "cube_hexa8_quad4.med" field_name = "fieldcelldouble" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B1.py b/test/VisuPrs/GaussPoints/B1.py index 626c87dc..246031d8 100644 --- a/test/VisuPrs/GaussPoints/B1.py +++ b/test/VisuPrs/GaussPoints/B1.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B1") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "test_55_solid_concentr_dom.med" field_name = "RN_precipite_restr" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B2.py b/test/VisuPrs/GaussPoints/B2.py index 5ce69d24..3e49e8ba 100644 --- a/test/VisuPrs/GaussPoints/B2.py +++ b/test/VisuPrs/GaussPoints/B2.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B2") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "H_COUPLEX1.med" field_name = "Head" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B3.py b/test/VisuPrs/GaussPoints/B3.py index a9e300ba..c2aba953 100644 --- a/test/VisuPrs/GaussPoints/B3.py +++ b/test/VisuPrs/GaussPoints/B3.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B3") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "cas2_2d_couplage_chess_castem.med" field_name = "pH" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B4.py b/test/VisuPrs/GaussPoints/B4.py index ab5668ba..38fcda94 100644 --- a/test/VisuPrs/GaussPoints/B4.py +++ b/test/VisuPrs/GaussPoints/B4.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B4") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "champc.med" field_name = "Am241_restriction" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B5.py b/test/VisuPrs/GaussPoints/B5.py index 1d6cbd57..f06a2e81 100644 --- a/test/VisuPrs/GaussPoints/B5.py +++ b/test/VisuPrs/GaussPoints/B5.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B5") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "hydro_sea_alv.med" field_name = "Head" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B6.py b/test/VisuPrs/GaussPoints/B6.py index e169f00c..937474ec 100644 --- a/test/VisuPrs/GaussPoints/B6.py +++ b/test/VisuPrs/GaussPoints/B6.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B6") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "toto.med" field_name = "erreur" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B7.py b/test/VisuPrs/GaussPoints/B7.py index b6d37c8b..072df6de 100644 --- a/test/VisuPrs/GaussPoints/B7.py +++ b/test/VisuPrs/GaussPoints/B7.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B7") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "couplex_alain.med" field_name = "Conc. I129" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B8.py b/test/VisuPrs/GaussPoints/B8.py index 7fe2ddc5..bedcc37a 100644 --- a/test/VisuPrs/GaussPoints/B8.py +++ b/test/VisuPrs/GaussPoints/B8.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B8") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "KCOUPLEX1.med" field_name = "Head" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/B9.py b/test/VisuPrs/GaussPoints/B9.py index 81ff1f3c..2919dbeb 100644 --- a/test/VisuPrs/GaussPoints/B9.py +++ b/test/VisuPrs/GaussPoints/B9.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/B9") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "test_hydro.med" field_name = "Head" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C0.py b/test/VisuPrs/GaussPoints/C0.py index fb672b8e..84d8b4e5 100644 --- a/test/VisuPrs/GaussPoints/C0.py +++ b/test/VisuPrs/GaussPoints/C0.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C0") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "ml.med" field_name = "head_restriction" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C1.py b/test/VisuPrs/GaussPoints/C1.py index 469067da..11ef3532 100644 --- a/test/VisuPrs/GaussPoints/C1.py +++ b/test/VisuPrs/GaussPoints/C1.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C1") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "T_COUPLEX1.med" field_name = "Conc. I129" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C2.py b/test/VisuPrs/GaussPoints/C2.py index 97348574..a7b553f6 100644 --- a/test/VisuPrs/GaussPoints/C2.py +++ b/test/VisuPrs/GaussPoints/C2.py @@ -25,21 +25,19 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C2") if not picturedir.endswith(os.sep): picturedir += os.sep - + # MED file file_name = datadir + "test_hydro_darcy4_out.med" field_name = "DarcyVelocity" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C3.py b/test/VisuPrs/GaussPoints/C3.py index a68b097c..a955fbd8 100644 --- a/test/VisuPrs/GaussPoints/C3.py +++ b/test/VisuPrs/GaussPoints/C3.py @@ -25,10 +25,8 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C3") if not picturedir.endswith(os.sep): @@ -39,7 +37,7 @@ file_name = datadir + "UO2_250ans.med" field_name = "Concentration_O2(aq)_mol per l" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C4.py b/test/VisuPrs/GaussPoints/C4.py index 75082269..d619ca63 100644 --- a/test/VisuPrs/GaussPoints/C4.py +++ b/test/VisuPrs/GaussPoints/C4.py @@ -25,10 +25,8 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C4") if not picturedir.endswith(os.sep): @@ -39,7 +37,7 @@ file_name = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" field_names = ["REMEUN__ERRE_ELGA_NORE__________", "REMEZEROERRE_ELGA_NORE__________"] timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C5.py b/test/VisuPrs/GaussPoints/C5.py index 84305cf5..28afebc5 100644 --- a/test/VisuPrs/GaussPoints/C5.py +++ b/test/VisuPrs/GaussPoints/C5.py @@ -25,10 +25,8 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C5") if not picturedir.endswith(os.sep): @@ -39,7 +37,7 @@ file_name = datadir + "occ4050.med" field_name = "champ_reel" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C6.py b/test/VisuPrs/GaussPoints/C6.py index 371c37a2..a64839ef 100644 --- a/test/VisuPrs/GaussPoints/C6.py +++ b/test/VisuPrs/GaussPoints/C6.py @@ -25,10 +25,8 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C6") if not picturedir.endswith(os.sep): @@ -39,7 +37,7 @@ file_name = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" field_names = ["REMEUN__ERRE_ELGA_NORE__________", "REMEZEROERRE_ELGA_NORE__________"] timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C7.py b/test/VisuPrs/GaussPoints/C7.py index ca9ba499..8e8d5ef4 100644 --- a/test/VisuPrs/GaussPoints/C7.py +++ b/test/VisuPrs/GaussPoints/C7.py @@ -25,10 +25,8 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import GaussPointsOnField, EntityType, get_time, process_prs_for_test -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C7") if not picturedir.endswith(os.sep): @@ -39,7 +37,7 @@ file_name = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" field_names = ["REMEUN__ERRE_ELGA_NORE__________", "REMEZEROERRE_ELGA_NORE__________"] timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C8.py b/test/VisuPrs/GaussPoints/C8.py index e0c798b5..eb887ffe 100644 --- a/test/VisuPrs/GaussPoints/C8.py +++ b/test/VisuPrs/GaussPoints/C8.py @@ -25,10 +25,8 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C8") if not picturedir.endswith(os.sep): @@ -40,7 +38,7 @@ field_name = "gravit__VARI_ELGA" #timestamp_nb = 1 timestamp_nb = 6 # timestamp 1 is empty -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") diff --git a/test/VisuPrs/GaussPoints/C9.py b/test/VisuPrs/GaussPoints/C9.py index 68862bdc..e58128f1 100644 --- a/test/VisuPrs/GaussPoints/C9.py +++ b/test/VisuPrs/GaussPoints/C9.py @@ -25,10 +25,8 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple - # Directory for saving snapshots picturedir = get_picture_dir("GaussPoints/C9") if not picturedir.endswith(os.sep): @@ -39,7 +37,7 @@ file_name = datadir + "petit.rmed" field_name = "RESPIL__SIEF_ELGA" timestamp_nb = -1 # last timestamp -paravis.OpenDataFile(file_name) +pvsimple.OpenDataFile(file_name) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError("File wasn't imported!!!") @@ -55,5 +53,3 @@ if prs is None: # Display presentation and get snapshot pic_name = picturedir + field_name + "_" + str(time) + "_GAUSSPOINTS." + pictureext process_prs_for_test(prs, view, pic_name) - - diff --git a/test/VisuPrs/ImportMedField/A0.py b/test/VisuPrs/ImportMedField/A0.py index 72ad07c4..6ef6f3d9 100644 --- a/test/VisuPrs/ImportMedField/A0.py +++ b/test/VisuPrs/ImportMedField/A0.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "ResOK_0000.med" field_names = ["temperature", "vitesse", "pression"] prs_list = [ [1,2,3,4,8], range(1,10), [0,1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A1.py b/test/VisuPrs/ImportMedField/A1.py index 19a0115d..8495d80f 100644 --- a/test/VisuPrs/ImportMedField/A1.py +++ b/test/VisuPrs/ImportMedField/A1.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "TimeStamps.med" field_names = ["pression", "temperature", "vitesse"] prs_list = [ [0,1,2,3,4,8], [1,2,3,4,8], range(1,10) ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A2.py b/test/VisuPrs/ImportMedField/A2.py index 17fa75e4..bcbd86d5 100644 --- a/test/VisuPrs/ImportMedField/A2.py +++ b/test/VisuPrs/ImportMedField/A2.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "carre_en_quad4_import22.med" field_names = ["fieldcelldouble", "fieldnodedouble", "fieldnodedouble", "fieldnodedouble", "fieldnodeint"] prs_list = [ range(10), [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A3.py b/test/VisuPrs/ImportMedField/A3.py index 4a2f62b5..4763852b 100644 --- a/test/VisuPrs/ImportMedField/A3.py +++ b/test/VisuPrs/ImportMedField/A3.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "carre_en_quad4_seg2.med" field_names = ["fieldcelldouble", "fieldnodedouble", "fieldnodedouble", "fieldnodedouble", "fieldnodeint"] prs_list = [ range(10), [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A4.py b/test/VisuPrs/ImportMedField/A4.py index 6de94572..855e438b 100644 --- a/test/VisuPrs/ImportMedField/A4.py +++ b/test/VisuPrs/ImportMedField/A4.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "test_hydro_darcy1a_out.med" field_names = ["DarcyVelocity","Head"] prs_list = [ range(10), [0,1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A5.py b/test/VisuPrs/ImportMedField/A5.py index 1c5e5a2c..824412d6 100644 --- a/test/VisuPrs/ImportMedField/A5.py +++ b/test/VisuPrs/ImportMedField/A5.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "clo2.med" field_names = ["PRESSION", "TAUX_DE_VIDE", "VITESSE"] prs_list = [ [0,1,2,3,4,8], [1,2,3,4,8], range(1,10) ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A6.py b/test/VisuPrs/ImportMedField/A6.py index 99e34ff5..f6856c16 100644 --- a/test/VisuPrs/ImportMedField/A6.py +++ b/test/VisuPrs/ImportMedField/A6.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "cube_hexa8_import22.med" field_names = ["fieldcelldouble", "fieldnodedouble", "fieldnodedouble", "fieldnodedouble", "fieldnodeint"] prs_list = [ range(10), [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A7.py b/test/VisuPrs/ImportMedField/A7.py index e1273774..64aaf76d 100644 --- a/test/VisuPrs/ImportMedField/A7.py +++ b/test/VisuPrs/ImportMedField/A7.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "cube_hexa8_quad4_import22.med" field_names = ["fieldcelldouble", "fieldnodedouble", "fieldnodedouble", "fieldnodedouble", "fieldnodeint"] prs_list = [ range(10), [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A8.py b/test/VisuPrs/ImportMedField/A8.py index dfeae8de..fad7eef0 100644 --- a/test/VisuPrs/ImportMedField/A8.py +++ b/test/VisuPrs/ImportMedField/A8.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "fra1.med" field_names = ["TAUX_DE_VIDE", "VITESSE"] prs_list = [ [1,2,3,4,8], range(1,10) ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/A9.py b/test/VisuPrs/ImportMedField/A9.py index ef0ec220..273964e4 100644 --- a/test/VisuPrs/ImportMedField/A9.py +++ b/test/VisuPrs/ImportMedField/A9.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "maill.0.med" field_names = ["REQT_GD_________________________", "RESUTRQUDEPL____________________", "RESUTRQUERRE_ELGA_NORE__________", "RESUTRQUSIEF_ELGA_DEPL__________", "RESUTRQUSIGM_ELNO_DEPL__________"] -prs_list = [ range(1,10), range(1,10), range(10), range(10), range(10)]) +prs_list = [ range(1,10), range(1,10), range(10), range(10), range(10)] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B0.py b/test/VisuPrs/ImportMedField/B0.py index 79adf2c9..907dd369 100644 --- a/test/VisuPrs/ImportMedField/B0.py +++ b/test/VisuPrs/ImportMedField/B0.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "maill.0_volumes.med" field_names = ["RETH____FLUX_NOEU_TEMP__________", "RETH____TEMP____________________"] prs_list = [ range(1,10), [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B1.py b/test/VisuPrs/ImportMedField/B1.py index eeb186f9..ad4490c3 100644 --- a/test/VisuPrs/ImportMedField/B1.py +++ b/test/VisuPrs/ImportMedField/B1.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "maill.1.med" field_names = ["RETH____FLUX_NOEU_TEMP__________", "RETH____TEMP____________________"] prs_list = [ range(1,10), [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B2.py b/test/VisuPrs/ImportMedField/B2.py index 1453b2f4..10f7fcce 100644 --- a/test/VisuPrs/ImportMedField/B2.py +++ b/test/VisuPrs/ImportMedField/B2.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "maill.2.med" field_names = ["RETH____FLUX_NOEU_TEMP__________","RETH____TEMP____________________"] prs_list = [ range(1,10), [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B3.py b/test/VisuPrs/ImportMedField/B3.py index 3a2f7de1..1f303605 100644 --- a/test/VisuPrs/ImportMedField/B3.py +++ b/test/VisuPrs/ImportMedField/B3.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "zzzz121b.med" field_names = ["RESUZERODEPL____________________", "RESUZEROERRE_ELGA_NORE__________", "RESUZEROSIEF_ELGA_DEPL__________", "RESUZEROSIGM_ELNO_DEPL__________"] prs_list = [ [0,1,5,6,7], [0,1,5,6,7], [0,1,5,6,7], [0,1,5,6,7,9] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B4.py b/test/VisuPrs/ImportMedField/B4.py index cc7fc76a..4d29b2a4 100644 --- a/test/VisuPrs/ImportMedField/B4.py +++ b/test/VisuPrs/ImportMedField/B4.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "pointe_4fields.med" field_names = ["fieldcelldoublescalar", "fieldcelldoublevector", "fieldnodedouble", "fieldnodedouble", "fieldnodedouble", "fieldnodeint"] prs_list = [ [0,1,2,3,4,8], range(10), [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B5.py b/test/VisuPrs/ImportMedField/B5.py index 1385ffd1..30432657 100644 --- a/test/VisuPrs/ImportMedField/B5.py +++ b/test/VisuPrs/ImportMedField/B5.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "pointe.med" field_names = ["fieldcelldoublescalar", "fieldcelldoublevector", "fieldnodedouble", "fieldnodedouble", "fieldnodedouble", "fieldnodeint"] prs_list = [ [0,1,2,3,4,8], range(10), [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8], [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B6.py b/test/VisuPrs/ImportMedField/B6.py index f663d3e3..a8519203 100644 --- a/test/VisuPrs/ImportMedField/B6.py +++ b/test/VisuPrs/ImportMedField/B6.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "polygones.med" field_names = ["bord_:_distorsion","bord_:_familles","bord_:_non-ortho"] prs_list = [ [0,1,2,3,4,8], [0,1,2,3,4,8], [0,1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B7.py b/test/VisuPrs/ImportMedField/B7.py index 151b786d..99103432 100644 --- a/test/VisuPrs/ImportMedField/B7.py +++ b/test/VisuPrs/ImportMedField/B7.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "recoll_bord.med" field_names = ["bord_:_distorsion","bord_:_familles","bord_:_non-ortho"] prs_list = [ [0,1,2,3,4,8], [0,1,2,3,4,8], [0,1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B8.py b/test/VisuPrs/ImportMedField/B8.py index 86b2ce12..4b141c60 100644 --- a/test/VisuPrs/ImportMedField/B8.py +++ b/test/VisuPrs/ImportMedField/B8.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "resu.2.med" field_names = ["RETH____FLUX_NOEU_TEMP__________","RETH____TEMP____________________"] prs_list = [ range(1,10), [1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/B9.py b/test/VisuPrs/ImportMedField/B9.py index 2f469e71..54f091a2 100644 --- a/test/VisuPrs/ImportMedField/B9.py +++ b/test/VisuPrs/ImportMedField/B9.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "test_2D.med" -field_names = ["champ","field_v","field_v_p"] -prs_list = [ [0,1,2,3,4,8], [0,1,2,3,4,8], [0,1,2,3,4,8] ] +field_names = ["field_v","field_v_p"] +prs_list = [ [0,1,2,3,4,8], [0,1,2,3,4,8] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/C0.py b/test/VisuPrs/ImportMedField/C0.py index 3f1546b2..ca745f7c 100644 --- a/test/VisuPrs/ImportMedField/C0.py +++ b/test/VisuPrs/ImportMedField/C0.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis med_file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" field_names = ["REMEZEROERRE_ELGA_NORE__________", "RETHZEROTEMP____________________"] prs_list = [ [0,1], [1] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/C1.py b/test/VisuPrs/ImportMedField/C1.py index b5c83afd..e8503b0c 100644 --- a/test/VisuPrs/ImportMedField/C1.py +++ b/test/VisuPrs/ImportMedField/C1.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis -med_file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1.med2.2.med" +med_file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" field_names = ["REMEUN__ERRE_ELGA_NORE__________", "RETHUN__TEMP____________________"] prs_list = [ [0,1], [1] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/ImportMedField/C2.py b/test/VisuPrs/ImportMedField/C2.py index 4bcc7ed6..cd674983 100644 --- a/test/VisuPrs/ImportMedField/C2.py +++ b/test/VisuPrs/ImportMedField/C2.py @@ -21,10 +21,9 @@ # Import MED file; create presentations for the given fields. from paravistest import datadir, Import_Med_Field -import pvserver as paravis -med_file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1.med2.3.med" +med_file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" field_names = ["REMEZEROERRE_ELGA_NORE__________", "RETHZEROTEMP____________________"] prs_list = [ [0,1], [1] ] -Import_Med_Field(paravis.myParavis, med_file, field_names, 1, prs_list) +Import_Med_Field(med_file, field_names, 1, prs_list) diff --git a/test/VisuPrs/IsoSurfaces/A0.py b/test/VisuPrs/IsoSurfaces/A0.py index 13aef2a7..c67e354a 100644 --- a/test/VisuPrs/IsoSurfaces/A0.py +++ b/test/VisuPrs/IsoSurfaces/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A0") +picturedir = get_picture_dir("IsoSurfaces/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A1.py b/test/VisuPrs/IsoSurfaces/A1.py index 524e9a6c..33b3f4c4 100755 --- a/test/VisuPrs/IsoSurfaces/A1.py +++ b/test/VisuPrs/IsoSurfaces/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A1") +picturedir = get_picture_dir("IsoSurfaces/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A2.py b/test/VisuPrs/IsoSurfaces/A2.py index 6de3caac..d486f086 100755 --- a/test/VisuPrs/IsoSurfaces/A2.py +++ b/test/VisuPrs/IsoSurfaces/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A2") +picturedir = get_picture_dir("IsoSurfaces/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A3.py b/test/VisuPrs/IsoSurfaces/A3.py index 81e455a7..6b35a66e 100755 --- a/test/VisuPrs/IsoSurfaces/A3.py +++ b/test/VisuPrs/IsoSurfaces/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A3") +picturedir = get_picture_dir("IsoSurfaces/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A4.py b/test/VisuPrs/IsoSurfaces/A4.py index 8ca02c99..86e8a6e5 100755 --- a/test/VisuPrs/IsoSurfaces/A4.py +++ b/test/VisuPrs/IsoSurfaces/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A4") +picturedir = get_picture_dir("IsoSurfaces/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A5.py b/test/VisuPrs/IsoSurfaces/A5.py index f1a21814..210fc42b 100755 --- a/test/VisuPrs/IsoSurfaces/A5.py +++ b/test/VisuPrs/IsoSurfaces/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A5") +picturedir = get_picture_dir("IsoSurfaces/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A6.py b/test/VisuPrs/IsoSurfaces/A6.py index 0d0388e3..b018359a 100644 --- a/test/VisuPrs/IsoSurfaces/A6.py +++ b/test/VisuPrs/IsoSurfaces/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A6") +picturedir = get_picture_dir("IsoSurfaces/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A7.py b/test/VisuPrs/IsoSurfaces/A7.py index 359639be..9f9a3791 100755 --- a/test/VisuPrs/IsoSurfaces/A7.py +++ b/test/VisuPrs/IsoSurfaces/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A7") +picturedir = get_picture_dir("IsoSurfaces/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A8.py b/test/VisuPrs/IsoSurfaces/A8.py index 272b0fc4..15e3955c 100755 --- a/test/VisuPrs/IsoSurfaces/A8.py +++ b/test/VisuPrs/IsoSurfaces/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A8") +picturedir = get_picture_dir("IsoSurfaces/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/A9.py b/test/VisuPrs/IsoSurfaces/A9.py index b3397c4d..4c96804a 100755 --- a/test/VisuPrs/IsoSurfaces/A9.py +++ b/test/VisuPrs/IsoSurfaces/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/A9") +picturedir = get_picture_dir("IsoSurfaces/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/B0.py b/test/VisuPrs/IsoSurfaces/B0.py index e2510945..cd81a3bb 100755 --- a/test/VisuPrs/IsoSurfaces/B0.py +++ b/test/VisuPrs/IsoSurfaces/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/B0") +picturedir = get_picture_dir("IsoSurfaces/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/B1.py b/test/VisuPrs/IsoSurfaces/B1.py index 0d70982c..6e8ea8b7 100644 --- a/test/VisuPrs/IsoSurfaces/B1.py +++ b/test/VisuPrs/IsoSurfaces/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/B1") +picturedir = get_picture_dir("IsoSurfaces/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/B2.py b/test/VisuPrs/IsoSurfaces/B2.py index 928522bf..4fe4d59e 100755 --- a/test/VisuPrs/IsoSurfaces/B2.py +++ b/test/VisuPrs/IsoSurfaces/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/B2") +picturedir = get_picture_dir("IsoSurfaces/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E0.py b/test/VisuPrs/IsoSurfaces/E0.py index 399b731a..f76545fc 100755 --- a/test/VisuPrs/IsoSurfaces/E0.py +++ b/test/VisuPrs/IsoSurfaces/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E0") +picturedir = get_picture_dir("IsoSurfaces/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E1.py b/test/VisuPrs/IsoSurfaces/E1.py index cffe170b..3cc24fc4 100755 --- a/test/VisuPrs/IsoSurfaces/E1.py +++ b/test/VisuPrs/IsoSurfaces/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E1") +picturedir = get_picture_dir("IsoSurfaces/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E2.py b/test/VisuPrs/IsoSurfaces/E2.py index a165fd31..8b73d9ab 100755 --- a/test/VisuPrs/IsoSurfaces/E2.py +++ b/test/VisuPrs/IsoSurfaces/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E2") +picturedir = get_picture_dir("IsoSurfaces/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E3.py b/test/VisuPrs/IsoSurfaces/E3.py index 2148282c..a300d67c 100644 --- a/test/VisuPrs/IsoSurfaces/E3.py +++ b/test/VisuPrs/IsoSurfaces/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E3") +picturedir = get_picture_dir("IsoSurfaces/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E4.py b/test/VisuPrs/IsoSurfaces/E4.py index 959cd007..8ee0b6ff 100755 --- a/test/VisuPrs/IsoSurfaces/E4.py +++ b/test/VisuPrs/IsoSurfaces/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E4") +picturedir = get_picture_dir("IsoSurfaces/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E5.py b/test/VisuPrs/IsoSurfaces/E5.py index 0c390adf..f0b82498 100755 --- a/test/VisuPrs/IsoSurfaces/E5.py +++ b/test/VisuPrs/IsoSurfaces/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E5") +picturedir = get_picture_dir("IsoSurfaces/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E6.py b/test/VisuPrs/IsoSurfaces/E6.py index a94d0221..51167a86 100755 --- a/test/VisuPrs/IsoSurfaces/E6.py +++ b/test/VisuPrs/IsoSurfaces/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E6") +picturedir = get_picture_dir("IsoSurfaces/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E7.py b/test/VisuPrs/IsoSurfaces/E7.py index d1e56328..94818acc 100755 --- a/test/VisuPrs/IsoSurfaces/E7.py +++ b/test/VisuPrs/IsoSurfaces/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E7") +picturedir = get_picture_dir("IsoSurfaces/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E8.py b/test/VisuPrs/IsoSurfaces/E8.py index 9dd9b69d..f8020eb8 100755 --- a/test/VisuPrs/IsoSurfaces/E8.py +++ b/test/VisuPrs/IsoSurfaces/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E8") +picturedir = get_picture_dir("IsoSurfaces/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/E9.py b/test/VisuPrs/IsoSurfaces/E9.py index 9e274639..de650145 100644 --- a/test/VisuPrs/IsoSurfaces/E9.py +++ b/test/VisuPrs/IsoSurfaces/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/E9") +picturedir = get_picture_dir("IsoSurfaces/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F1.py b/test/VisuPrs/IsoSurfaces/F1.py index e69fac85..0ddb4a20 100755 --- a/test/VisuPrs/IsoSurfaces/F1.py +++ b/test/VisuPrs/IsoSurfaces/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F1") +picturedir = get_picture_dir("IsoSurfaces/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F2.py b/test/VisuPrs/IsoSurfaces/F2.py index 9efae8d4..23ededb1 100755 --- a/test/VisuPrs/IsoSurfaces/F2.py +++ b/test/VisuPrs/IsoSurfaces/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F2") +picturedir = get_picture_dir("IsoSurfaces/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F3.py b/test/VisuPrs/IsoSurfaces/F3.py index 734c4204..a0d036bb 100755 --- a/test/VisuPrs/IsoSurfaces/F3.py +++ b/test/VisuPrs/IsoSurfaces/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F3") +picturedir = get_picture_dir("IsoSurfaces/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F4.py b/test/VisuPrs/IsoSurfaces/F4.py index ec41c6ec..a1b65591 100755 --- a/test/VisuPrs/IsoSurfaces/F4.py +++ b/test/VisuPrs/IsoSurfaces/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F4") +picturedir = get_picture_dir("IsoSurfaces/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F5.py b/test/VisuPrs/IsoSurfaces/F5.py index 2bbee9b2..dc5a2201 100755 --- a/test/VisuPrs/IsoSurfaces/F5.py +++ b/test/VisuPrs/IsoSurfaces/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F5") +picturedir = get_picture_dir("IsoSurfaces/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F6.py b/test/VisuPrs/IsoSurfaces/F6.py index eafee131..aaa9bcd3 100755 --- a/test/VisuPrs/IsoSurfaces/F6.py +++ b/test/VisuPrs/IsoSurfaces/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F6") +picturedir = get_picture_dir("IsoSurfaces/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F7.py b/test/VisuPrs/IsoSurfaces/F7.py index 641fad67..fac1ee43 100644 --- a/test/VisuPrs/IsoSurfaces/F7.py +++ b/test/VisuPrs/IsoSurfaces/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F7") +picturedir = get_picture_dir("IsoSurfaces/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F8.py b/test/VisuPrs/IsoSurfaces/F8.py index 180cedab..9a121021 100755 --- a/test/VisuPrs/IsoSurfaces/F8.py +++ b/test/VisuPrs/IsoSurfaces/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F8") +picturedir = get_picture_dir("IsoSurfaces/F8") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/F9.py b/test/VisuPrs/IsoSurfaces/F9.py index ee8a4e36..3e096c79 100644 --- a/test/VisuPrs/IsoSurfaces/F9.py +++ b/test/VisuPrs/IsoSurfaces/F9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/F9") +picturedir = get_picture_dir("IsoSurfaces/F9") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/G0.py b/test/VisuPrs/IsoSurfaces/G0.py index db81ee37..c195da92 100644 --- a/test/VisuPrs/IsoSurfaces/G0.py +++ b/test/VisuPrs/IsoSurfaces/G0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/G0") +picturedir = get_picture_dir("IsoSurfaces/G0") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/G1.py b/test/VisuPrs/IsoSurfaces/G1.py index 42a1ceff..30f879c8 100755 --- a/test/VisuPrs/IsoSurfaces/G1.py +++ b/test/VisuPrs/IsoSurfaces/G1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("IsoSurfaces/G1") +picturedir = get_picture_dir("IsoSurfaces/G1") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.ISOSURFACES], picturedir, pictureext) diff --git a/test/VisuPrs/IsoSurfaces/G2.py b/test/VisuPrs/IsoSurfaces/G2.py index 805f15cd..674cc9d4 100644 --- a/test/VisuPrs/IsoSurfaces/G2.py +++ b/test/VisuPrs/IsoSurfaces/G2.py @@ -24,10 +24,7 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("IsoSurfaces/G2") theFileName = datadir + "Bug829_resu_mode.med" @@ -40,7 +37,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" # Get viewScalarMap aView = GetRenderView() @@ -59,19 +56,19 @@ for i in range(1,11): #display only current scalar map display_only(aPrs, aView) reset_view(aView) - Render(aView) - + Render(aView) + # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep prs_type = PrsTypeEnum.ISOSURFACES - + # Get name of presentation type - prs_name = PrsTypeEnum.get_name(prs_type) + prs_name = PrsTypeEnum.get_name(prs_type) f_prs_type = prs_name.replace(' ', '').upper() # Construct image file name pic_name = picturedir + aFieldName + "_" + str(i) + "_" + f_prs_type + "." + pictureext - + # Show and record the presentation process_prs_for_test(aPrs, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/A0.py b/test/VisuPrs/MeshPresentation/A0.py index 48db2ebc..1d9f4bb2 100644 --- a/test/VisuPrs/MeshPresentation/A0.py +++ b/test/VisuPrs/MeshPresentation/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A0") +picturedir = get_picture_dir("MeshPresentation/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A1.py b/test/VisuPrs/MeshPresentation/A1.py index 1e35e135..db2f1f9f 100644 --- a/test/VisuPrs/MeshPresentation/A1.py +++ b/test/VisuPrs/MeshPresentation/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A1") +picturedir = get_picture_dir("MeshPresentation/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A2.py b/test/VisuPrs/MeshPresentation/A2.py index a8d3b1a0..c8cf6db7 100644 --- a/test/VisuPrs/MeshPresentation/A2.py +++ b/test/VisuPrs/MeshPresentation/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A2") +picturedir = get_picture_dir("MeshPresentation/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A3.py b/test/VisuPrs/MeshPresentation/A3.py index ab419465..723b886c 100644 --- a/test/VisuPrs/MeshPresentation/A3.py +++ b/test/VisuPrs/MeshPresentation/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A3") +picturedir = get_picture_dir("MeshPresentation/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A4.py b/test/VisuPrs/MeshPresentation/A4.py index c4c91a45..1c534a84 100644 --- a/test/VisuPrs/MeshPresentation/A4.py +++ b/test/VisuPrs/MeshPresentation/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A4") +picturedir = get_picture_dir("MeshPresentation/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A5.py b/test/VisuPrs/MeshPresentation/A5.py index 20d440e4..dd618fc7 100644 --- a/test/VisuPrs/MeshPresentation/A5.py +++ b/test/VisuPrs/MeshPresentation/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A5") +picturedir = get_picture_dir("MeshPresentation/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A6.py b/test/VisuPrs/MeshPresentation/A6.py index e0e4b496..b5544a50 100644 --- a/test/VisuPrs/MeshPresentation/A6.py +++ b/test/VisuPrs/MeshPresentation/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A6") +picturedir = get_picture_dir("MeshPresentation/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A7.py b/test/VisuPrs/MeshPresentation/A7.py index c9ef939b..b6878018 100644 --- a/test/VisuPrs/MeshPresentation/A7.py +++ b/test/VisuPrs/MeshPresentation/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A7") +picturedir = get_picture_dir("MeshPresentation/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A8.py b/test/VisuPrs/MeshPresentation/A8.py index 3db53d77..7ba79d05 100644 --- a/test/VisuPrs/MeshPresentation/A8.py +++ b/test/VisuPrs/MeshPresentation/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A8") +picturedir = get_picture_dir("MeshPresentation/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/A9.py b/test/VisuPrs/MeshPresentation/A9.py index 50dc8797..8fa74270 100644 --- a/test/VisuPrs/MeshPresentation/A9.py +++ b/test/VisuPrs/MeshPresentation/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/A9") +picturedir = get_picture_dir("MeshPresentation/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/B0.py b/test/VisuPrs/MeshPresentation/B0.py index 805d9665..01af691d 100644 --- a/test/VisuPrs/MeshPresentation/B0.py +++ b/test/VisuPrs/MeshPresentation/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/B0") +picturedir = get_picture_dir("MeshPresentation/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/B1.py b/test/VisuPrs/MeshPresentation/B1.py index 39a2521e..8bf34edf 100644 --- a/test/VisuPrs/MeshPresentation/B1.py +++ b/test/VisuPrs/MeshPresentation/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/B1") +picturedir = get_picture_dir("MeshPresentation/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/B2.py b/test/VisuPrs/MeshPresentation/B2.py index 0af92bae..2baaa6df 100644 --- a/test/VisuPrs/MeshPresentation/B2.py +++ b/test/VisuPrs/MeshPresentation/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/B2") +picturedir = get_picture_dir("MeshPresentation/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E0.py b/test/VisuPrs/MeshPresentation/E0.py index 917b12cc..a315e140 100644 --- a/test/VisuPrs/MeshPresentation/E0.py +++ b/test/VisuPrs/MeshPresentation/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E0") +picturedir = get_picture_dir("MeshPresentation/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E1.py b/test/VisuPrs/MeshPresentation/E1.py index f289a707..2b3a54b0 100644 --- a/test/VisuPrs/MeshPresentation/E1.py +++ b/test/VisuPrs/MeshPresentation/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E1") +picturedir = get_picture_dir("MeshPresentation/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E2.py b/test/VisuPrs/MeshPresentation/E2.py index 8e785b95..a44eae09 100644 --- a/test/VisuPrs/MeshPresentation/E2.py +++ b/test/VisuPrs/MeshPresentation/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E2") +picturedir = get_picture_dir("MeshPresentation/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E3.py b/test/VisuPrs/MeshPresentation/E3.py index 462862a8..b2ce3119 100644 --- a/test/VisuPrs/MeshPresentation/E3.py +++ b/test/VisuPrs/MeshPresentation/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E3") +picturedir = get_picture_dir("MeshPresentation/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E4.py b/test/VisuPrs/MeshPresentation/E4.py index 56bb82c6..0809f529 100644 --- a/test/VisuPrs/MeshPresentation/E4.py +++ b/test/VisuPrs/MeshPresentation/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E4") +picturedir = get_picture_dir("MeshPresentation/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E5.py b/test/VisuPrs/MeshPresentation/E5.py index 80d3cbf2..ed851717 100644 --- a/test/VisuPrs/MeshPresentation/E5.py +++ b/test/VisuPrs/MeshPresentation/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E5") +picturedir = get_picture_dir("MeshPresentation/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E6.py b/test/VisuPrs/MeshPresentation/E6.py index 26e5c0d3..98e30dee 100644 --- a/test/VisuPrs/MeshPresentation/E6.py +++ b/test/VisuPrs/MeshPresentation/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E6") +picturedir = get_picture_dir("MeshPresentation/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E7.py b/test/VisuPrs/MeshPresentation/E7.py index 6b977889..4ece85e2 100644 --- a/test/VisuPrs/MeshPresentation/E7.py +++ b/test/VisuPrs/MeshPresentation/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E7") +picturedir = get_picture_dir("MeshPresentation/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E8.py b/test/VisuPrs/MeshPresentation/E8.py index 410ce657..fc3ccdb2 100644 --- a/test/VisuPrs/MeshPresentation/E8.py +++ b/test/VisuPrs/MeshPresentation/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E8") +picturedir = get_picture_dir("MeshPresentation/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/E9.py b/test/VisuPrs/MeshPresentation/E9.py index 0838198c..335fefc9 100644 --- a/test/VisuPrs/MeshPresentation/E9.py +++ b/test/VisuPrs/MeshPresentation/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/E9") +picturedir = get_picture_dir("MeshPresentation/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F0.py b/test/VisuPrs/MeshPresentation/F0.py index 58101e82..75dd5aa5 100644 --- a/test/VisuPrs/MeshPresentation/F0.py +++ b/test/VisuPrs/MeshPresentation/F0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F0") +picturedir = get_picture_dir("MeshPresentation/F0") file = datadir + "gro5couches.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F1.py b/test/VisuPrs/MeshPresentation/F1.py index 125c6a56..623b50b6 100644 --- a/test/VisuPrs/MeshPresentation/F1.py +++ b/test/VisuPrs/MeshPresentation/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F1") +picturedir = get_picture_dir("MeshPresentation/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F2.py b/test/VisuPrs/MeshPresentation/F2.py index b1c90000..bf897882 100644 --- a/test/VisuPrs/MeshPresentation/F2.py +++ b/test/VisuPrs/MeshPresentation/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F2") +picturedir = get_picture_dir("MeshPresentation/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F3.py b/test/VisuPrs/MeshPresentation/F3.py index 25b1c853..53652252 100644 --- a/test/VisuPrs/MeshPresentation/F3.py +++ b/test/VisuPrs/MeshPresentation/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F3") +picturedir = get_picture_dir("MeshPresentation/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F4.py b/test/VisuPrs/MeshPresentation/F4.py index 416c24d0..3f1cb0c1 100644 --- a/test/VisuPrs/MeshPresentation/F4.py +++ b/test/VisuPrs/MeshPresentation/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F4") +picturedir = get_picture_dir("MeshPresentation/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F5.py b/test/VisuPrs/MeshPresentation/F5.py index a6a252c7..9ab363c8 100644 --- a/test/VisuPrs/MeshPresentation/F5.py +++ b/test/VisuPrs/MeshPresentation/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F5") +picturedir = get_picture_dir("MeshPresentation/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F6.py b/test/VisuPrs/MeshPresentation/F6.py index 6cd8e7e9..0da43a7a 100644 --- a/test/VisuPrs/MeshPresentation/F6.py +++ b/test/VisuPrs/MeshPresentation/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F6") +picturedir = get_picture_dir("MeshPresentation/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F7.py b/test/VisuPrs/MeshPresentation/F7.py index 710b4646..7a7d9f40 100644 --- a/test/VisuPrs/MeshPresentation/F7.py +++ b/test/VisuPrs/MeshPresentation/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F7") +picturedir = get_picture_dir("MeshPresentation/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F8.py b/test/VisuPrs/MeshPresentation/F8.py index ae738d83..c62d9ea7 100644 --- a/test/VisuPrs/MeshPresentation/F8.py +++ b/test/VisuPrs/MeshPresentation/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F8") +picturedir = get_picture_dir("MeshPresentation/F8") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/F9.py b/test/VisuPrs/MeshPresentation/F9.py index e14db375..fb618f09 100644 --- a/test/VisuPrs/MeshPresentation/F9.py +++ b/test/VisuPrs/MeshPresentation/F9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/F9") +picturedir = get_picture_dir("MeshPresentation/F9") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/G0.py b/test/VisuPrs/MeshPresentation/G0.py index 1cbf521b..d6c0b696 100644 --- a/test/VisuPrs/MeshPresentation/G0.py +++ b/test/VisuPrs/MeshPresentation/G0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/G0") +picturedir = get_picture_dir("MeshPresentation/G0") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/G1.py b/test/VisuPrs/MeshPresentation/G1.py index 03021ca6..2379cc7e 100644 --- a/test/VisuPrs/MeshPresentation/G1.py +++ b/test/VisuPrs/MeshPresentation/G1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("MeshPresentation/G1") +picturedir = get_picture_dir("MeshPresentation/G1") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.MESH], picturedir, pictureext) diff --git a/test/VisuPrs/MeshPresentation/G3.py b/test/VisuPrs/MeshPresentation/G3.py index 9d1d526a..f5a61d03 100644 --- a/test/VisuPrs/MeshPresentation/G3.py +++ b/test/VisuPrs/MeshPresentation/G3.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/G3 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/G3") theFileName = datadir + "Box1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name, entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,5 +62,5 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/G4.py b/test/VisuPrs/MeshPresentation/G4.py index d2a34556..f9e80667 100644 --- a/test/VisuPrs/MeshPresentation/G4.py +++ b/test/VisuPrs/MeshPresentation/G4.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/G4 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/G4") theFileName = datadir + "Box1Moderate.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/G5.py b/test/VisuPrs/MeshPresentation/G5.py index 8dd4ee10..e8db1375 100644 --- a/test/VisuPrs/MeshPresentation/G5.py +++ b/test/VisuPrs/MeshPresentation/G5.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/G5 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/G5") theFileName = datadir + "Box2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/G6.py b/test/VisuPrs/MeshPresentation/G6.py index d57f0102..75c39fa3 100644 --- a/test/VisuPrs/MeshPresentation/G6.py +++ b/test/VisuPrs/MeshPresentation/G6.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/G6 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/G6") theFileName = datadir + "Box2Moderate.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/G7.py b/test/VisuPrs/MeshPresentation/G7.py index d56cfc6e..41b1493d 100644 --- a/test/VisuPrs/MeshPresentation/G7.py +++ b/test/VisuPrs/MeshPresentation/G7.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/G7 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/G7") theFileName = datadir + "Box3.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,5 +62,5 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/G8.py b/test/VisuPrs/MeshPresentation/G8.py index af1c3d2f..a274e972 100644 --- a/test/VisuPrs/MeshPresentation/G8.py +++ b/test/VisuPrs/MeshPresentation/G8.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/G8 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/G8") theFileName = datadir + "BoxEvenSmaller1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/G9.py b/test/VisuPrs/MeshPresentation/G9.py index 6bd57c65..cd2ad237 100644 --- a/test/VisuPrs/MeshPresentation/G9.py +++ b/test/VisuPrs/MeshPresentation/G9.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/G9 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/G9") theFileName = datadir + "BoxHexa1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H0.py b/test/VisuPrs/MeshPresentation/H0.py index 15c4bbee..258e5a2d 100644 --- a/test/VisuPrs/MeshPresentation/H0.py +++ b/test/VisuPrs/MeshPresentation/H0.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H0 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H0") theFileName = datadir + "BoxHexa2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H1.py b/test/VisuPrs/MeshPresentation/H1.py index b8f7763d..8d8a298f 100644 --- a/test/VisuPrs/MeshPresentation/H1.py +++ b/test/VisuPrs/MeshPresentation/H1.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H1 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H1") theFileName = datadir + "BoxModSmall1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H2.py b/test/VisuPrs/MeshPresentation/H2.py index cbff9b7a..5ed7518e 100644 --- a/test/VisuPrs/MeshPresentation/H2.py +++ b/test/VisuPrs/MeshPresentation/H2.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H2 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H2") theFileName = datadir + "BoxModSmall2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H3.py b/test/VisuPrs/MeshPresentation/H3.py index 2829c976..87da4728 100644 --- a/test/VisuPrs/MeshPresentation/H3.py +++ b/test/VisuPrs/MeshPresentation/H3.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H3 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H3") theFileName = datadir + "BoxTetra2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H4.py b/test/VisuPrs/MeshPresentation/H4.py index 28b09754..b54b1731 100644 --- a/test/VisuPrs/MeshPresentation/H4.py +++ b/test/VisuPrs/MeshPresentation/H4.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H4 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H4") theFileName = datadir + "ComplexIncludedTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H5.py b/test/VisuPrs/MeshPresentation/H5.py index a7dfc6d3..78ba4a87 100644 --- a/test/VisuPrs/MeshPresentation/H5.py +++ b/test/VisuPrs/MeshPresentation/H5.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H5 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H5") theFileName = datadir + "ComplexIncludingTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H6.py b/test/VisuPrs/MeshPresentation/H6.py index bb77b19c..45dff21d 100644 --- a/test/VisuPrs/MeshPresentation/H6.py +++ b/test/VisuPrs/MeshPresentation/H6.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H6 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H6") theFileName = datadir + "CornerTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H7.py b/test/VisuPrs/MeshPresentation/H7.py index 097c60da..858f0ff8 100644 --- a/test/VisuPrs/MeshPresentation/H7.py +++ b/test/VisuPrs/MeshPresentation/H7.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H7 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H7") theFileName = datadir + "DegenEdgeXY.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H8.py b/test/VisuPrs/MeshPresentation/H8.py index 4823f29f..36830858 100644 --- a/test/VisuPrs/MeshPresentation/H8.py +++ b/test/VisuPrs/MeshPresentation/H8.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H8 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H8") theFileName = datadir + "DegenFaceXYZ.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/H9.py b/test/VisuPrs/MeshPresentation/H9.py index 14c6ed9b..8b6f0fab 100644 --- a/test/VisuPrs/MeshPresentation/H9.py +++ b/test/VisuPrs/MeshPresentation/H9.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/H9 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/H9") theFileName = datadir + "DegenTranslatedInPlane.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I0.py b/test/VisuPrs/MeshPresentation/I0.py index 298f0543..4b0aa802 100644 --- a/test/VisuPrs/MeshPresentation/I0.py +++ b/test/VisuPrs/MeshPresentation/I0.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I0 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I0") theFileName = datadir + "TinyBox.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I1.py b/test/VisuPrs/MeshPresentation/I1.py index c46be39f..6e475b25 100644 --- a/test/VisuPrs/MeshPresentation/I1.py +++ b/test/VisuPrs/MeshPresentation/I1.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I1 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I1") theFileName = datadir + "TrickyTetra1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I2.py b/test/VisuPrs/MeshPresentation/I2.py index f05f8b1a..20fb798a 100644 --- a/test/VisuPrs/MeshPresentation/I2.py +++ b/test/VisuPrs/MeshPresentation/I2.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I2 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I2") theFileName = datadir + "UnitTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I3.py b/test/VisuPrs/MeshPresentation/I3.py index 46131f7c..e518ad0f 100644 --- a/test/VisuPrs/MeshPresentation/I3.py +++ b/test/VisuPrs/MeshPresentation/I3.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I3 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I3") theFileName = datadir + "UnitTetraDegenT.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I4.py b/test/VisuPrs/MeshPresentation/I4.py index 02a5dfee..3c50012d 100644 --- a/test/VisuPrs/MeshPresentation/I4.py +++ b/test/VisuPrs/MeshPresentation/I4.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I4 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I4") theFileName = datadir + "square1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I5.py b/test/VisuPrs/MeshPresentation/I5.py index 494845a6..a61e89f2 100644 --- a/test/VisuPrs/MeshPresentation/I5.py +++ b/test/VisuPrs/MeshPresentation/I5.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I5 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I5") theFileName = datadir + "square1_split1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I6.py b/test/VisuPrs/MeshPresentation/I6.py index 6680fcc8..96e5b672 100644 --- a/test/VisuPrs/MeshPresentation/I6.py +++ b/test/VisuPrs/MeshPresentation/I6.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I6 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I6") theFileName = datadir + "square1_split2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I7.py b/test/VisuPrs/MeshPresentation/I7.py index 8ec610fe..ee404e28 100644 --- a/test/VisuPrs/MeshPresentation/I7.py +++ b/test/VisuPrs/MeshPresentation/I7.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I7 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I7") theFileName = datadir + "square1_split3.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I8.py b/test/VisuPrs/MeshPresentation/I8.py index 955bba35..1b46b5fe 100644 --- a/test/VisuPrs/MeshPresentation/I8.py +++ b/test/VisuPrs/MeshPresentation/I8.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I8 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I8") theFileName = datadir + "square2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/I9.py b/test/VisuPrs/MeshPresentation/I9.py index b3605781..86d6b537 100644 --- a/test/VisuPrs/MeshPresentation/I9.py +++ b/test/VisuPrs/MeshPresentation/I9.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/I9 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/I9") theFileName = datadir + "square2_split1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J0.py b/test/VisuPrs/MeshPresentation/J0.py index d61fcce4..9f8111f8 100644 --- a/test/VisuPrs/MeshPresentation/J0.py +++ b/test/VisuPrs/MeshPresentation/J0.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J0 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J0") theFileName = datadir + "DividedGenTetra1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J1.py b/test/VisuPrs/MeshPresentation/J1.py index ad6a678f..62ae59ed 100644 --- a/test/VisuPrs/MeshPresentation/J1.py +++ b/test/VisuPrs/MeshPresentation/J1.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J1 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J1") theFileName = datadir + "DividedGenTetra2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J2.py b/test/VisuPrs/MeshPresentation/J2.py index 459572d9..e77f95f7 100644 --- a/test/VisuPrs/MeshPresentation/J2.py +++ b/test/VisuPrs/MeshPresentation/J2.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J2 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J2") theFileName = datadir + "DividedUnitTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J3.py b/test/VisuPrs/MeshPresentation/J3.py index 81df627f..e4785404 100644 --- a/test/VisuPrs/MeshPresentation/J3.py +++ b/test/VisuPrs/MeshPresentation/J3.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J3 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J3") theFileName = datadir + "DividedUnitTetraSimpler.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J4.py b/test/VisuPrs/MeshPresentation/J4.py index 309b3941..0f147d93 100644 --- a/test/VisuPrs/MeshPresentation/J4.py +++ b/test/VisuPrs/MeshPresentation/J4.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J4 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J4") theFileName = datadir + "GenTetra1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J5.py b/test/VisuPrs/MeshPresentation/J5.py index 7a59824b..ef7c805c 100644 --- a/test/VisuPrs/MeshPresentation/J5.py +++ b/test/VisuPrs/MeshPresentation/J5.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J5 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J5") theFileName = datadir + "GenTetra2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J6.py b/test/VisuPrs/MeshPresentation/J6.py index e90eefb5..2adc7b51 100644 --- a/test/VisuPrs/MeshPresentation/J6.py +++ b/test/VisuPrs/MeshPresentation/J6.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J6 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J6") theFileName = datadir + "GeneralTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J7.py b/test/VisuPrs/MeshPresentation/J7.py index 8d2e131a..64777074 100644 --- a/test/VisuPrs/MeshPresentation/J7.py +++ b/test/VisuPrs/MeshPresentation/J7.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J7 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J7") theFileName = datadir + "HalfstripOnly.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J8.py b/test/VisuPrs/MeshPresentation/J8.py index 8212300c..d482183b 100644 --- a/test/VisuPrs/MeshPresentation/J8.py +++ b/test/VisuPrs/MeshPresentation/J8.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J8 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J8") theFileName = datadir + "HalfstripOnly2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/J9.py b/test/VisuPrs/MeshPresentation/J9.py index b70fa6ef..5bb501d2 100644 --- a/test/VisuPrs/MeshPresentation/J9.py +++ b/test/VisuPrs/MeshPresentation/J9.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/J9 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/J9") theFileName = datadir + "LargeInconsistentTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K0.py b/test/VisuPrs/MeshPresentation/K0.py index 48e82753..cc55cbc7 100644 --- a/test/VisuPrs/MeshPresentation/K0.py +++ b/test/VisuPrs/MeshPresentation/K0.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K0 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K0") theFileName = datadir + "LargeUnitTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K1.py b/test/VisuPrs/MeshPresentation/K1.py index 91397e4c..7e1ea275 100644 --- a/test/VisuPrs/MeshPresentation/K1.py +++ b/test/VisuPrs/MeshPresentation/K1.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K1 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K1") theFileName = datadir + "MovedHexaBox1.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K2.py b/test/VisuPrs/MeshPresentation/K2.py index 252afc68..aca86d52 100644 --- a/test/VisuPrs/MeshPresentation/K2.py +++ b/test/VisuPrs/MeshPresentation/K2.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K2 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K2") theFileName = datadir + "MovedHexaBox2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K3.py b/test/VisuPrs/MeshPresentation/K3.py index bdfad592..47f01f76 100644 --- a/test/VisuPrs/MeshPresentation/K3.py +++ b/test/VisuPrs/MeshPresentation/K3.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K3 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K3") theFileName = datadir + "NudgedDividedUnitTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K4.py b/test/VisuPrs/MeshPresentation/K4.py index a8abf7ef..46804640 100644 --- a/test/VisuPrs/MeshPresentation/K4.py +++ b/test/VisuPrs/MeshPresentation/K4.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K4 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K4") theFileName = datadir + "NudgedDividedUnitTetraSimpler.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K5.py b/test/VisuPrs/MeshPresentation/K5.py index 49776d36..c5f151b9 100644 --- a/test/VisuPrs/MeshPresentation/K5.py +++ b/test/VisuPrs/MeshPresentation/K5.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K5 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K5") theFileName = datadir + "NudgedSimpler.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K6.py b/test/VisuPrs/MeshPresentation/K6.py index 7a6c98bb..5c2ed695 100644 --- a/test/VisuPrs/MeshPresentation/K6.py +++ b/test/VisuPrs/MeshPresentation/K6.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K6 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K6") theFileName = datadir + "NudgedTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K7.py b/test/VisuPrs/MeshPresentation/K7.py index c14424ca..523edcf0 100644 --- a/test/VisuPrs/MeshPresentation/K7.py +++ b/test/VisuPrs/MeshPresentation/K7.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K7 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K7") theFileName = datadir + "SimpleHalfstripOnly.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K8.py b/test/VisuPrs/MeshPresentation/K8.py index 08c3bc33..e501e6fa 100644 --- a/test/VisuPrs/MeshPresentation/K8.py +++ b/test/VisuPrs/MeshPresentation/K8.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K8 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K8") theFileName = datadir + "SimpleIncludedTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/K9.py b/test/VisuPrs/MeshPresentation/K9.py index 7b98de0a..54c0c910 100644 --- a/test/VisuPrs/MeshPresentation/K9.py +++ b/test/VisuPrs/MeshPresentation/K9.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/K9 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/K9") theFileName = datadir + "SimpleIncludingTetra.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/L0.py b/test/VisuPrs/MeshPresentation/L0.py index 65208228..b4a46925 100644 --- a/test/VisuPrs/MeshPresentation/L0.py +++ b/test/VisuPrs/MeshPresentation/L0.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/L0 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/L0") theFileName = datadir + "square2_split2.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/MeshPresentation/L1.py b/test/VisuPrs/MeshPresentation/L1.py index 804a02eb..a2ae9e24 100644 --- a/test/VisuPrs/MeshPresentation/L1.py +++ b/test/VisuPrs/MeshPresentation/L1.py @@ -18,16 +18,13 @@ # #This case corresponds to: /visu/MeshPresentation/L0 case -# Create mesh presentation for nodes and cells of the the given MED file +# Create mesh presentation for nodes and cells of the the given MED file import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("MeshPresentation/L1") theFileName = datadir + "Bug829_resu_mode.med" @@ -39,7 +36,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" aView = GetRenderView() @@ -52,9 +49,9 @@ entity_types = [EntityType.NODE,EntityType.CELL] for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) mesh = MeshOnEntity(aProxy, mesh_name ,entity_type) - if mesh is None: + if mesh is None: msg = "ERROR!!!Presentation of mesh on '"+entity_name+"' family wasn't created..." - raise RuntimeError, msg + raise RuntimeError, msg mesh.Visibility=1 reset_view(aView) Render() @@ -65,7 +62,7 @@ for entity_type in entity_types: entity_name = EntityType.get_name(entity_type) # Construct image file name pic_name = picturedir + mesh_name + "_" + entity_name + "." + pictureext - + process_prs_for_test(mesh, aView, pic_name) diff --git a/test/VisuPrs/Plot3D/A0.py b/test/VisuPrs/Plot3D/A0.py index a7fdadde..27f6d22b 100644 --- a/test/VisuPrs/Plot3D/A0.py +++ b/test/VisuPrs/Plot3D/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A0") +picturedir = get_picture_dir("Plot3D/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A1.py b/test/VisuPrs/Plot3D/A1.py index a673a123..eafc707d 100755 --- a/test/VisuPrs/Plot3D/A1.py +++ b/test/VisuPrs/Plot3D/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A1") +picturedir = get_picture_dir("Plot3D/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A2.py b/test/VisuPrs/Plot3D/A2.py index 84e5befe..71314620 100755 --- a/test/VisuPrs/Plot3D/A2.py +++ b/test/VisuPrs/Plot3D/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A2") +picturedir = get_picture_dir("Plot3D/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A3.py b/test/VisuPrs/Plot3D/A3.py index 0f958f31..892000a2 100755 --- a/test/VisuPrs/Plot3D/A3.py +++ b/test/VisuPrs/Plot3D/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A3") +picturedir = get_picture_dir("Plot3D/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A4.py b/test/VisuPrs/Plot3D/A4.py index ffc53e30..5a898ab7 100755 --- a/test/VisuPrs/Plot3D/A4.py +++ b/test/VisuPrs/Plot3D/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A4") +picturedir = get_picture_dir("Plot3D/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A5.py b/test/VisuPrs/Plot3D/A5.py index 616b4f9a..8fe23b88 100755 --- a/test/VisuPrs/Plot3D/A5.py +++ b/test/VisuPrs/Plot3D/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A5") +picturedir = get_picture_dir("Plot3D/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A6.py b/test/VisuPrs/Plot3D/A6.py index 8e087b11..a3e1c921 100644 --- a/test/VisuPrs/Plot3D/A6.py +++ b/test/VisuPrs/Plot3D/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A6") +picturedir = get_picture_dir("Plot3D/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A7.py b/test/VisuPrs/Plot3D/A7.py index 673ffec1..ece6bc87 100755 --- a/test/VisuPrs/Plot3D/A7.py +++ b/test/VisuPrs/Plot3D/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A7") +picturedir = get_picture_dir("Plot3D/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A8.py b/test/VisuPrs/Plot3D/A8.py index 485d2a21..51c1ac6a 100755 --- a/test/VisuPrs/Plot3D/A8.py +++ b/test/VisuPrs/Plot3D/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A8") +picturedir = get_picture_dir("Plot3D/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/A9.py b/test/VisuPrs/Plot3D/A9.py index 5b41835f..875c3bf0 100755 --- a/test/VisuPrs/Plot3D/A9.py +++ b/test/VisuPrs/Plot3D/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/A9") +picturedir = get_picture_dir("Plot3D/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/B0.py b/test/VisuPrs/Plot3D/B0.py index 3084eef0..b0cc9457 100755 --- a/test/VisuPrs/Plot3D/B0.py +++ b/test/VisuPrs/Plot3D/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/B0") +picturedir = get_picture_dir("Plot3D/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/B1.py b/test/VisuPrs/Plot3D/B1.py index 7a5d8416..e3ad329b 100755 --- a/test/VisuPrs/Plot3D/B1.py +++ b/test/VisuPrs/Plot3D/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/B1") +picturedir = get_picture_dir("Plot3D/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/B2.py b/test/VisuPrs/Plot3D/B2.py index 02e6441d..852ffa12 100755 --- a/test/VisuPrs/Plot3D/B2.py +++ b/test/VisuPrs/Plot3D/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/B2") +picturedir = get_picture_dir("Plot3D/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E0.py b/test/VisuPrs/Plot3D/E0.py index 39af14e7..aaefaa74 100755 --- a/test/VisuPrs/Plot3D/E0.py +++ b/test/VisuPrs/Plot3D/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E0") +picturedir = get_picture_dir("Plot3D/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E1.py b/test/VisuPrs/Plot3D/E1.py index 8bceda07..2139976b 100755 --- a/test/VisuPrs/Plot3D/E1.py +++ b/test/VisuPrs/Plot3D/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E1") +picturedir = get_picture_dir("Plot3D/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E2.py b/test/VisuPrs/Plot3D/E2.py index 42ffae30..7ae8d111 100755 --- a/test/VisuPrs/Plot3D/E2.py +++ b/test/VisuPrs/Plot3D/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E2") +picturedir = get_picture_dir("Plot3D/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E3.py b/test/VisuPrs/Plot3D/E3.py index 32f532cc..b2c6c7e8 100644 --- a/test/VisuPrs/Plot3D/E3.py +++ b/test/VisuPrs/Plot3D/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E3") +picturedir = get_picture_dir("Plot3D/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E4.py b/test/VisuPrs/Plot3D/E4.py index 13772447..37113b12 100755 --- a/test/VisuPrs/Plot3D/E4.py +++ b/test/VisuPrs/Plot3D/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E4") +picturedir = get_picture_dir("Plot3D/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E5.py b/test/VisuPrs/Plot3D/E5.py index 5a94fecc..7c85cde4 100755 --- a/test/VisuPrs/Plot3D/E5.py +++ b/test/VisuPrs/Plot3D/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E5") +picturedir = get_picture_dir("Plot3D/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E6.py b/test/VisuPrs/Plot3D/E6.py index 385f188b..47afc818 100755 --- a/test/VisuPrs/Plot3D/E6.py +++ b/test/VisuPrs/Plot3D/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E6") +picturedir = get_picture_dir("Plot3D/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E7.py b/test/VisuPrs/Plot3D/E7.py index 73e64865..292ae34b 100755 --- a/test/VisuPrs/Plot3D/E7.py +++ b/test/VisuPrs/Plot3D/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E7") +picturedir = get_picture_dir("Plot3D/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E8.py b/test/VisuPrs/Plot3D/E8.py index 0ac8ddb8..c2d7d2d7 100755 --- a/test/VisuPrs/Plot3D/E8.py +++ b/test/VisuPrs/Plot3D/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E8") +picturedir = get_picture_dir("Plot3D/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/E9.py b/test/VisuPrs/Plot3D/E9.py index da0d62cb..9ccc03ca 100755 --- a/test/VisuPrs/Plot3D/E9.py +++ b/test/VisuPrs/Plot3D/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/E9") +picturedir = get_picture_dir("Plot3D/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F1.py b/test/VisuPrs/Plot3D/F1.py index d0fb42fa..cd140e5b 100755 --- a/test/VisuPrs/Plot3D/F1.py +++ b/test/VisuPrs/Plot3D/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F1") +picturedir = get_picture_dir("Plot3D/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F2.py b/test/VisuPrs/Plot3D/F2.py index 8a716f33..1880539a 100755 --- a/test/VisuPrs/Plot3D/F2.py +++ b/test/VisuPrs/Plot3D/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F2") +picturedir = get_picture_dir("Plot3D/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F3.py b/test/VisuPrs/Plot3D/F3.py index a9902669..2572b27c 100755 --- a/test/VisuPrs/Plot3D/F3.py +++ b/test/VisuPrs/Plot3D/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F3") +picturedir = get_picture_dir("Plot3D/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F4.py b/test/VisuPrs/Plot3D/F4.py index fba201ed..2c7f2598 100755 --- a/test/VisuPrs/Plot3D/F4.py +++ b/test/VisuPrs/Plot3D/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F4") +picturedir = get_picture_dir("Plot3D/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F5.py b/test/VisuPrs/Plot3D/F5.py index bf0bf3ca..a8d1ef6e 100755 --- a/test/VisuPrs/Plot3D/F5.py +++ b/test/VisuPrs/Plot3D/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F5") +picturedir = get_picture_dir("Plot3D/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F6.py b/test/VisuPrs/Plot3D/F6.py index dcaefc67..e05a2e99 100755 --- a/test/VisuPrs/Plot3D/F6.py +++ b/test/VisuPrs/Plot3D/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F6") +picturedir = get_picture_dir("Plot3D/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F7.py b/test/VisuPrs/Plot3D/F7.py index e995a05a..a2fede0b 100644 --- a/test/VisuPrs/Plot3D/F7.py +++ b/test/VisuPrs/Plot3D/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F7") +picturedir = get_picture_dir("Plot3D/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F8.py b/test/VisuPrs/Plot3D/F8.py index 6be15501..6b090a5c 100755 --- a/test/VisuPrs/Plot3D/F8.py +++ b/test/VisuPrs/Plot3D/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F8") +picturedir = get_picture_dir("Plot3D/F8") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/F9.py b/test/VisuPrs/Plot3D/F9.py index 1cd3b9ce..81313104 100644 --- a/test/VisuPrs/Plot3D/F9.py +++ b/test/VisuPrs/Plot3D/F9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/F9") +picturedir = get_picture_dir("Plot3D/F9") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/G0.py b/test/VisuPrs/Plot3D/G0.py index dd37aaa0..0d763206 100644 --- a/test/VisuPrs/Plot3D/G0.py +++ b/test/VisuPrs/Plot3D/G0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/G0") +picturedir = get_picture_dir("Plot3D/G0") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/G1.py b/test/VisuPrs/Plot3D/G1.py index 77621fd3..1b7642b2 100755 --- a/test/VisuPrs/Plot3D/G1.py +++ b/test/VisuPrs/Plot3D/G1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Plot3D/G1") +picturedir = get_picture_dir("Plot3D/G1") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.PLOT3D], picturedir, pictureext) diff --git a/test/VisuPrs/Plot3D/G2.py b/test/VisuPrs/Plot3D/G2.py index 59b1f220..be73291c 100755 --- a/test/VisuPrs/Plot3D/G2.py +++ b/test/VisuPrs/Plot3D/G2.py @@ -24,10 +24,6 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * from pvsimple import * -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis picturedir = get_picture_dir("Plot3D/G2") @@ -41,7 +37,7 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" # Get viewScalarMap aView = GetRenderView() @@ -58,19 +54,19 @@ for i in range(1,11): #display only current scalar map aPrs.Visibility=1 reset_view(aView) - Render(aView) - + Render(aView) + # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep prs_type = PrsTypeEnum.PLOT3D - + # Get name of presentation type - prs_name = PrsTypeEnum.get_name(prs_type) + prs_name = PrsTypeEnum.get_name(prs_type) f_prs_type = prs_name.replace(' ', '').upper() # Construct image file name pic_name = picturedir + aFieldName + "_" + str(i) + "_" + f_prs_type + "." + pictureext - + # Show and record the presentation process_prs_for_test(aPrs, aView, pic_name) diff --git a/test/VisuPrs/SWIG_scripts/A1.py b/test/VisuPrs/SWIG_scripts/A1.py index 537f1c95..57fba91f 100644 --- a/test/VisuPrs/SWIG_scripts/A1.py +++ b/test/VisuPrs/SWIG_scripts/A1.py @@ -21,19 +21,15 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple - -my_paravis = paravis.myParavis - #====================Stage1: Importing MED file==================== print "**** Stage1: Importing MED file" print 'Import "ResOK_0000.med"...............', file_path = datadir + "ResOK_0000.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -122,7 +118,7 @@ else: print 'Import "Fields_group3D.med"...............', file_path = datadir + "Fields_group3D.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader1 = pvsimple.GetActiveSource() if med_reader1 is None: diff --git a/test/VisuPrs/SWIG_scripts/A3.py b/test/VisuPrs/SWIG_scripts/A3.py index 881c15cd..aaad57b5 100644 --- a/test/VisuPrs/SWIG_scripts/A3.py +++ b/test/VisuPrs/SWIG_scripts/A3.py @@ -21,15 +21,11 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple - -my_paravis = paravis.myParavis - print 'Importing "TimeStamps.med"...............', file_path = datadir + "TimeStamps.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/SWIG_scripts/A4.py b/test/VisuPrs/SWIG_scripts/A4.py index aa9cb0a1..87fcb27d 100644 --- a/test/VisuPrs/SWIG_scripts/A4.py +++ b/test/VisuPrs/SWIG_scripts/A4.py @@ -25,14 +25,10 @@ from time import sleep from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple - DELAY = 0.25 -my_paravis = paravis.myParavis - # Get view view = pvsimple.GetRenderView() sleep(DELAY) @@ -55,7 +51,7 @@ field_name = "fieldnodedouble" entity = EntityType.NODE timestamp = 1 -OpenDataFile(med_file) +pvsimple.OpenDataFile(med_file) med_reader = pvsimple.GetActiveSource() @@ -238,7 +234,7 @@ for curve in curves: b = str(random.random()) xyrep.SeriesColor = [field_name, r, g, b] index += 1 - + pvsimple.Render(xy_view) sleep(DELAY) @@ -256,7 +252,7 @@ field_name = "vitesse" entity = EntityType.NODE timestamp = 2 -OpenDataFile(med_file) +pvsimple.OpenDataFile(med_file) med_reader = pvsimple.GetActiveSource() isosurf = IsoSurfacesOnField(med_reader, entity, field_name, timestamp) @@ -264,4 +260,4 @@ print "IsoSurfacesOnField(...)" pvsimple.ResetCamera(view) print "Start Animation" -pvsimple.AnimateReader(med_reader, view) +pvsimple.AnimateReader(med_reader, view) diff --git a/test/VisuPrs/SWIG_scripts/A5.py b/test/VisuPrs/SWIG_scripts/A5.py index e03e5b24..6df0be1b 100644 --- a/test/VisuPrs/SWIG_scripts/A5.py +++ b/test/VisuPrs/SWIG_scripts/A5.py @@ -21,10 +21,8 @@ # Create table and display it as curves from paravistest import tablesdir -import pvserver as paravis import pvsimple - # Define script for table creation script = """ import math diff --git a/test/VisuPrs/SWIG_scripts/A6.py b/test/VisuPrs/SWIG_scripts/A6.py index 5b0a265c..43972d4c 100644 --- a/test/VisuPrs/SWIG_scripts/A6.py +++ b/test/VisuPrs/SWIG_scripts/A6.py @@ -22,10 +22,8 @@ from paravistest import tablesdir from presentations import * -import pvserver as paravis import pvsimple - # Import table from CSV file file_path = tablesdir + "sinus.csv" sinus_csv = pvsimple.CSVReader(FileName=file_path) diff --git a/test/VisuPrs/SWIG_scripts/A7.py b/test/VisuPrs/SWIG_scripts/A7.py index a1ac6189..c22ad6a7 100644 --- a/test/VisuPrs/SWIG_scripts/A7.py +++ b/test/VisuPrs/SWIG_scripts/A7.py @@ -23,16 +23,12 @@ import time from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple - -my_paravis = paravis.myParavis view = pvsimple.GetRenderView() reset_view(view) delay = 1 - def after_set(error_string, prop_name, old_value, new_value): print prop_name, ": old_value = ", old_value, "new_value = ", new_value if error_string == "": @@ -96,7 +92,7 @@ file_path = datadir + "ResOK_0000.med" field_name = 'vitesse' node_entity = EntityType.NODE -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -132,7 +128,7 @@ file_path = datadir + "fra.med" field_name = 'VITESSE' pvsimple.SetActiveSource(None) -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/SWIG_scripts/B0.py b/test/VisuPrs/SWIG_scripts/B0.py index b8c8c598..b38e23fc 100644 --- a/test/VisuPrs/SWIG_scripts/B0.py +++ b/test/VisuPrs/SWIG_scripts/B0.py @@ -21,10 +21,8 @@ # Create table from paravistest import tablesdir -import pvserver as paravis import pvsimple - # Define script for table creation script = """ import math diff --git a/test/VisuPrs/SWIG_scripts/B1.py b/test/VisuPrs/SWIG_scripts/B1.py index 936f5247..98f281c8 100644 --- a/test/VisuPrs/SWIG_scripts/B1.py +++ b/test/VisuPrs/SWIG_scripts/B1.py @@ -25,14 +25,10 @@ from time import sleep from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple - DELAY = 0.25 -my_paravis = paravis.myParavis - # Get view view = pvsimple.GetRenderView() sleep(DELAY) @@ -55,7 +51,7 @@ field_name = "fieldnodedouble" entity = EntityType.NODE timestamp = 1 -OpenDataFile(med_file) +pvsimple.OpenDataFile(med_file) med_reader = pvsimple.GetActiveSource() @@ -288,7 +284,7 @@ field_name = "vitesse" entity = EntityType.NODE timestamp = 2 -OpenDataFile(med_file) +pvsimple.OpenDataFile(med_file) med_reader = pvsimple.GetActiveSource() isosurf = IsoSurfacesOnField(med_reader, entity, field_name, timestamp) diff --git a/test/VisuPrs/SWIG_scripts/B4.py b/test/VisuPrs/SWIG_scripts/B4.py index 12737f59..f8e207ee 100644 --- a/test/VisuPrs/SWIG_scripts/B4.py +++ b/test/VisuPrs/SWIG_scripts/B4.py @@ -25,14 +25,11 @@ import os from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # Import MED file med_file_path = datadir + "pointe.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -46,7 +43,7 @@ try: entity = EntityType.NODE field_name = "fieldnodedouble" timestamp_id = 1 - + scalarmap = ScalarMapOnField(med_reader, entity, field_name, timestamp_id) if get_nb_components(med_reader, entity, field_name) > 1: vectors = VectorsOnField(med_reader, entity, field_name, timestamp_id) @@ -56,9 +53,9 @@ try: else: print "We have no permission to rewrite medFile" else: - print "We have no permission to read medFile, it will not be opened"; + print "We have no permission to read medFile, it will not be opened"; except: - print sys.exc_type + print sys.exc_type print sys.exc_value print sys.exc_traceback diff --git a/test/VisuPrs/SWIG_scripts/B5.py b/test/VisuPrs/SWIG_scripts/B5.py index 1e5aadbe..66bd1a8d 100644 --- a/test/VisuPrs/SWIG_scripts/B5.py +++ b/test/VisuPrs/SWIG_scripts/B5.py @@ -23,18 +23,14 @@ from time import sleep from paravistest import datadir, tablesdir from presentations import * -import pvserver as paravis import pvsimple - DELAY = 2 -my_paravis = paravis.myParavis - # Step 1 print 'Importing "pointe.med"...............', file_path = datadir + "pointe.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/SWIG_scripts/B6.py b/test/VisuPrs/SWIG_scripts/B6.py index c091f825..ada4c64b 100644 --- a/test/VisuPrs/SWIG_scripts/B6.py +++ b/test/VisuPrs/SWIG_scripts/B6.py @@ -21,10 +21,8 @@ # Create table of integer, create table of real, create curves from paravistest import tablesdir -import pvserver as paravis import pvsimple - # Define script for table of integer creation script_ti = """ def add_column(table, name, lst): diff --git a/test/VisuPrs/SWIG_scripts/B7.py b/test/VisuPrs/SWIG_scripts/B7.py index 8ad780a8..4953deb6 100644 --- a/test/VisuPrs/SWIG_scripts/B7.py +++ b/test/VisuPrs/SWIG_scripts/B7.py @@ -22,10 +22,8 @@ from paravistest import tablesdir from presentations import * -import pvserver as paravis import pvsimple - # Import table from CSV file file_path = tablesdir + "table_test.csv" table_csv = pvsimple.CSVReader(FileName=file_path) diff --git a/test/VisuPrs/SWIG_scripts/B8.py b/test/VisuPrs/SWIG_scripts/B8.py index ebf05d2d..e4bf0764 100644 --- a/test/VisuPrs/SWIG_scripts/B8.py +++ b/test/VisuPrs/SWIG_scripts/B8.py @@ -20,4 +20,3 @@ # This case corresponds to: /visu/SWIG_scripts/B8 case import paravistest -import pvserver as paravis diff --git a/test/VisuPrs/SWIG_scripts/B9.py b/test/VisuPrs/SWIG_scripts/B9.py index ba741176..cb74a8c1 100644 --- a/test/VisuPrs/SWIG_scripts/B9.py +++ b/test/VisuPrs/SWIG_scripts/B9.py @@ -21,12 +21,8 @@ from paravistest import datadir from presentations import EntityType, ScalarMapOnField, CutPlanesOnField -import pvserver as paravis import pvsimple - -my_paravis = paravis.myParavis - # Get view view1 = pvsimple.GetRenderView() @@ -36,7 +32,7 @@ field_name = "fieldnodedouble" entity = EntityType.NODE timestamp = 1 -OpenDataFile(med_file) +pvsimple.OpenDataFile(med_file) med_reader = pvsimple.GetActiveSource() # Create presentations diff --git a/test/VisuPrs/SWIG_scripts/C6.py b/test/VisuPrs/SWIG_scripts/C6.py index 2de470fd..dad9c8be 100644 --- a/test/VisuPrs/SWIG_scripts/C6.py +++ b/test/VisuPrs/SWIG_scripts/C6.py @@ -22,10 +22,8 @@ from paravistest import tablesdir from presentations import * -import pvserver as paravis import pvsimple - # 1. Import tables from file file_path = tablesdir + "tables_test.xls" table_reader = pvsimple.TableReader(FileName=file_path) @@ -47,4 +45,3 @@ xy_rep.XArrayName = 'toto 1 [s]' xy_rep.SeriesVisibility = [xy_rep.XArrayName, '0'] xy_rep.SeriesVisibility = ['vtkOriginalIndices', '0'] pvsimple.Render(xy_view) - diff --git a/test/VisuPrs/SWIG_scripts/C7.py b/test/VisuPrs/SWIG_scripts/C7.py index cfddddae..a74c8d12 100755 --- a/test/VisuPrs/SWIG_scripts/C7.py +++ b/test/VisuPrs/SWIG_scripts/C7.py @@ -25,10 +25,8 @@ import sys from paravistest import tablesdir, get_picture_dir, pictureext from presentations import * -import pvserver as paravis import pvsimple - # Import table from file print 'Import file with tables....', file_path = tablesdir + "table_test.xls" diff --git a/test/VisuPrs/ScalarMap/A0.py b/test/VisuPrs/ScalarMap/A0.py index c2a33c25..607f9dad 100755 --- a/test/VisuPrs/ScalarMap/A0.py +++ b/test/VisuPrs/ScalarMap/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A0") +picturedir = get_picture_dir("ScalarMap/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A1.py b/test/VisuPrs/ScalarMap/A1.py index 00b06b1a..4ded229e 100644 --- a/test/VisuPrs/ScalarMap/A1.py +++ b/test/VisuPrs/ScalarMap/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A1") +picturedir = get_picture_dir("ScalarMap/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A2.py b/test/VisuPrs/ScalarMap/A2.py index 1e9a9a59..2d44f6cb 100755 --- a/test/VisuPrs/ScalarMap/A2.py +++ b/test/VisuPrs/ScalarMap/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A2") +picturedir = get_picture_dir("ScalarMap/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A3.py b/test/VisuPrs/ScalarMap/A3.py index 09e8d219..c9d7e6a8 100755 --- a/test/VisuPrs/ScalarMap/A3.py +++ b/test/VisuPrs/ScalarMap/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A3") +picturedir = get_picture_dir("ScalarMap/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A4.py b/test/VisuPrs/ScalarMap/A4.py index 85bd5c54..c7464fbc 100755 --- a/test/VisuPrs/ScalarMap/A4.py +++ b/test/VisuPrs/ScalarMap/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A4") +picturedir = get_picture_dir("ScalarMap/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A5.py b/test/VisuPrs/ScalarMap/A5.py index 8bde3c40..5a086e8e 100644 --- a/test/VisuPrs/ScalarMap/A5.py +++ b/test/VisuPrs/ScalarMap/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A5") +picturedir = get_picture_dir("ScalarMap/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A6.py b/test/VisuPrs/ScalarMap/A6.py index 045312c4..228db56e 100755 --- a/test/VisuPrs/ScalarMap/A6.py +++ b/test/VisuPrs/ScalarMap/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A6") +picturedir = get_picture_dir("ScalarMap/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A7.py b/test/VisuPrs/ScalarMap/A7.py index 0e3d8ac9..ff04a5b0 100644 --- a/test/VisuPrs/ScalarMap/A7.py +++ b/test/VisuPrs/ScalarMap/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A7") +picturedir = get_picture_dir("ScalarMap/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A8.py b/test/VisuPrs/ScalarMap/A8.py index cb856861..8f2c6063 100644 --- a/test/VisuPrs/ScalarMap/A8.py +++ b/test/VisuPrs/ScalarMap/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A8") +picturedir = get_picture_dir("ScalarMap/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/A9.py b/test/VisuPrs/ScalarMap/A9.py index be046b67..70327816 100644 --- a/test/VisuPrs/ScalarMap/A9.py +++ b/test/VisuPrs/ScalarMap/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/A9") +picturedir = get_picture_dir("ScalarMap/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/B0.py b/test/VisuPrs/ScalarMap/B0.py index 8ee48ac2..82c91b52 100644 --- a/test/VisuPrs/ScalarMap/B0.py +++ b/test/VisuPrs/ScalarMap/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/B0") +picturedir = get_picture_dir("ScalarMap/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/B1.py b/test/VisuPrs/ScalarMap/B1.py index 5ac0d329..bdbfe6fd 100644 --- a/test/VisuPrs/ScalarMap/B1.py +++ b/test/VisuPrs/ScalarMap/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/B1") +picturedir = get_picture_dir("ScalarMap/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/B2.py b/test/VisuPrs/ScalarMap/B2.py index 4b502bc7..fe2e4182 100644 --- a/test/VisuPrs/ScalarMap/B2.py +++ b/test/VisuPrs/ScalarMap/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/B2") +picturedir = get_picture_dir("ScalarMap/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/B3.py b/test/VisuPrs/ScalarMap/B3.py index ddc91692..86b2216f 100644 --- a/test/VisuPrs/ScalarMap/B3.py +++ b/test/VisuPrs/ScalarMap/B3.py @@ -22,16 +22,13 @@ from paravistest import datadir import presentations -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file print 'Importing "fra.med"...', file_path = datadir + "fra.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -56,7 +53,7 @@ print "Vector component .....", lookup_table.VectorComponent lookup_table.VectorMode = 'Component' lookup_table.VectorComponent = 0 -scalarmap.LookupTable = lookup_table +scalarmap.LookupTable = lookup_table print "Vector mode .....", scalarmap.LookupTable.VectorMode print "Vector component .....", scalarmap.LookupTable.VectorComponent @@ -132,10 +129,10 @@ print "Default number of colors = ", scalarmap.LookupTable.NumberOfTableValues scalarmap.LookupTable.Discretize = 1 -print "Set negative number of colors" -nb_colors = -128 -scalarmap.LookupTable.NumberOfTableValues = nb_colors -print "Number of colors =", scalarmap.LookupTable.NumberOfTableValues +#print "Set negative number of colors" +#nb_colors = -128 +#scalarmap.LookupTable.NumberOfTableValues = nb_colors +#print "Number of colors =", scalarmap.LookupTable.NumberOfTableValues print "Set zero number of colors" nb_colors = 0 diff --git a/test/VisuPrs/ScalarMap/E0.py b/test/VisuPrs/ScalarMap/E0.py index d22c3bb9..31e8d7d5 100644 --- a/test/VisuPrs/ScalarMap/E0.py +++ b/test/VisuPrs/ScalarMap/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E0") +picturedir = get_picture_dir("ScalarMap/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E1.py b/test/VisuPrs/ScalarMap/E1.py index 7aba4ea0..738b39c5 100644 --- a/test/VisuPrs/ScalarMap/E1.py +++ b/test/VisuPrs/ScalarMap/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E1") +picturedir = get_picture_dir("ScalarMap/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E2.py b/test/VisuPrs/ScalarMap/E2.py index 46dda14e..dae2a3e3 100644 --- a/test/VisuPrs/ScalarMap/E2.py +++ b/test/VisuPrs/ScalarMap/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E2") +picturedir = get_picture_dir("ScalarMap/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E3.py b/test/VisuPrs/ScalarMap/E3.py index cc0c215e..89a364d7 100755 --- a/test/VisuPrs/ScalarMap/E3.py +++ b/test/VisuPrs/ScalarMap/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E3") +picturedir = get_picture_dir("ScalarMap/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E4.py b/test/VisuPrs/ScalarMap/E4.py index eb719959..713602af 100644 --- a/test/VisuPrs/ScalarMap/E4.py +++ b/test/VisuPrs/ScalarMap/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E4") +picturedir = get_picture_dir("ScalarMap/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E5.py b/test/VisuPrs/ScalarMap/E5.py index 3ead844c..b5fd2b6f 100644 --- a/test/VisuPrs/ScalarMap/E5.py +++ b/test/VisuPrs/ScalarMap/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E5") +picturedir = get_picture_dir("ScalarMap/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E6.py b/test/VisuPrs/ScalarMap/E6.py index bf75b947..512710e1 100644 --- a/test/VisuPrs/ScalarMap/E6.py +++ b/test/VisuPrs/ScalarMap/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E6") +picturedir = get_picture_dir("ScalarMap/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E7.py b/test/VisuPrs/ScalarMap/E7.py index 81da1ab8..6e74a962 100644 --- a/test/VisuPrs/ScalarMap/E7.py +++ b/test/VisuPrs/ScalarMap/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E7") +picturedir = get_picture_dir("ScalarMap/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E8.py b/test/VisuPrs/ScalarMap/E8.py index e19bcdbe..9af0585a 100644 --- a/test/VisuPrs/ScalarMap/E8.py +++ b/test/VisuPrs/ScalarMap/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E8") +picturedir = get_picture_dir("ScalarMap/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/E9.py b/test/VisuPrs/ScalarMap/E9.py index e75fdd21..b7d1616f 100644 --- a/test/VisuPrs/ScalarMap/E9.py +++ b/test/VisuPrs/ScalarMap/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/E9") +picturedir = get_picture_dir("ScalarMap/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F1.py b/test/VisuPrs/ScalarMap/F1.py index 15768ce5..7fd83aaa 100644 --- a/test/VisuPrs/ScalarMap/F1.py +++ b/test/VisuPrs/ScalarMap/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F1") +picturedir = get_picture_dir("ScalarMap/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F2.py b/test/VisuPrs/ScalarMap/F2.py index 98e0bfa8..70e21a84 100644 --- a/test/VisuPrs/ScalarMap/F2.py +++ b/test/VisuPrs/ScalarMap/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F2") +picturedir = get_picture_dir("ScalarMap/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F3.py b/test/VisuPrs/ScalarMap/F3.py index cf2aec8a..981f0dd2 100644 --- a/test/VisuPrs/ScalarMap/F3.py +++ b/test/VisuPrs/ScalarMap/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F3") +picturedir = get_picture_dir("ScalarMap/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F4.py b/test/VisuPrs/ScalarMap/F4.py index 10e54bb1..51e84220 100644 --- a/test/VisuPrs/ScalarMap/F4.py +++ b/test/VisuPrs/ScalarMap/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F4") +picturedir = get_picture_dir("ScalarMap/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F5.py b/test/VisuPrs/ScalarMap/F5.py index d86c50e9..9dfb75e3 100644 --- a/test/VisuPrs/ScalarMap/F5.py +++ b/test/VisuPrs/ScalarMap/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F5") +picturedir = get_picture_dir("ScalarMap/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F6.py b/test/VisuPrs/ScalarMap/F6.py index b79e94c6..1bf84c8f 100644 --- a/test/VisuPrs/ScalarMap/F6.py +++ b/test/VisuPrs/ScalarMap/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F6") +picturedir = get_picture_dir("ScalarMap/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F7.py b/test/VisuPrs/ScalarMap/F7.py index cd530ba0..da55c773 100644 --- a/test/VisuPrs/ScalarMap/F7.py +++ b/test/VisuPrs/ScalarMap/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F7") +picturedir = get_picture_dir("ScalarMap/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F8.py b/test/VisuPrs/ScalarMap/F8.py index 828651bb..0bb06805 100644 --- a/test/VisuPrs/ScalarMap/F8.py +++ b/test/VisuPrs/ScalarMap/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F8") +picturedir = get_picture_dir("ScalarMap/F8") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/F9.py b/test/VisuPrs/ScalarMap/F9.py index 5c25b4a4..2f29631a 100644 --- a/test/VisuPrs/ScalarMap/F9.py +++ b/test/VisuPrs/ScalarMap/F9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/F9") +picturedir = get_picture_dir("ScalarMap/F9") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/G0.py b/test/VisuPrs/ScalarMap/G0.py index 7c0eba49..6a7749eb 100644 --- a/test/VisuPrs/ScalarMap/G0.py +++ b/test/VisuPrs/ScalarMap/G0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/G0") +picturedir = get_picture_dir("ScalarMap/G0") file = datadir + "homard_ASTER_OSF_MEDV2.1.5_1_v2.3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/G1.py b/test/VisuPrs/ScalarMap/G1.py index 621bb1b1..b9d26588 100644 --- a/test/VisuPrs/ScalarMap/G1.py +++ b/test/VisuPrs/ScalarMap/G1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap/G1") +picturedir = get_picture_dir("ScalarMap/G1") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap/G2.py b/test/VisuPrs/ScalarMap/G2.py index 5465eb55..9a3bc7f8 100644 --- a/test/VisuPrs/ScalarMap/G2.py +++ b/test/VisuPrs/ScalarMap/G2.py @@ -23,27 +23,22 @@ import sys import os from paravistest import datadir, pictureext, get_picture_dir -import pvserver as paravis -from pvsimple import GetActiveSource, GetRenderView, Render +from pvsimple import GetActiveSource, GetRenderView, Render, OpenDataFile from presentations import ScalarMapOnField, hide_all, EntityType, PrsTypeEnum,reset_view,process_prs_for_test - -# Create presentations -myParavis = paravis.myParavis - picturedir = get_picture_dir("ScalarMap/G2") theFileName = datadir + "Bug829_resu_mode.med" print " --------------------------------- " print "file ", theFileName print " --------------------------------- " - + """Build presentations of the given types for all fields of the given file.""" #print "Import %s..." % theFileName.split('/')[-1], result = OpenDataFile(theFileName) proxy = GetActiveSource() if proxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" # Get view aView = GetRenderView() @@ -62,27 +57,27 @@ for i in range(1,11): #display only current scalar map aPrs.Visibility=1 reset_view(aView) - Render(aView) - + Render(aView) + # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep prs_type = PrsTypeEnum.SCALARMAP - + # Get name of presentation type - prs_name = PrsTypeEnum.get_name(prs_type) + prs_name = PrsTypeEnum.get_name(prs_type) f_prs_type = prs_name.replace(' ', '').upper() # Construct image file name pic_name = picturedir + aFieldName + "_" + str(i) + "_" + f_prs_type + "." + pictureext - + # Show and record the presentation process_prs_for_test(aPrs, aView, pic_name) sizes.append(os.path.getsize(pic_name)) -# check sizes of pictures +# check sizes of pictures if abs(max(sizes)-min(sizes)) > 0.01*max(sizes): - print "WARNING!!! Pictures have different sizes!!!"; + print "WARNING!!! Pictures have different sizes!!!"; for i in range(1,11): picture_name = "time_stamp_"+str(i)+"."+pictureext - print "Picture: "+picture_name+"; size: "+str(sizes[i-1]) - raise RuntimeError + print "Picture: "+picture_name+"; size: "+str(sizes[i-1]) + raise RuntimeError diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A0.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A0.py index aab8f951..7a748e7c 100644 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A0.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A0") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A1.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A1.py index b42582fb..1fc07e5b 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A1.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A1") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A2.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A2.py index 542459a8..7bbf02cf 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A2.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A2") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A3.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A3.py index a986aabc..b7925be5 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A3.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A3") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A4.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A4.py index 37114eea..be7f45e2 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A4.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A4") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A5.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A5.py index 4dfab688..59a5ed80 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A5.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A5") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A6.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A6.py index 03f8fdcb..f3001ea9 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A6.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A6") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A7.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A7.py index 014689bb..d6b48ec7 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A7.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A7") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A8.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A8.py index 46ad5724..bc608990 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A8.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A8") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/A9.py b/test/VisuPrs/ScalarMap_On_DeformedShape/A9.py index 0a47091e..6fc9a477 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/A9.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A9") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/B0.py b/test/VisuPrs/ScalarMap_On_DeformedShape/B0.py index e524b5e3..debcdc09 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/B0.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/B0") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/B1.py b/test/VisuPrs/ScalarMap_On_DeformedShape/B1.py index cdb1d440..15f046a6 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/B1.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/B1") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/B2.py b/test/VisuPrs/ScalarMap_On_DeformedShape/B2.py index fea51f20..d5fbab6c 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/B2.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/B2") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/B3.py b/test/VisuPrs/ScalarMap_On_DeformedShape/B3.py index 0a806abe..3deddecc 100644 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/B3.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/B3.py @@ -21,15 +21,12 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - #====================Stage1: Import MED file========================= print 'Importing "fra.med"...................', medFile = datadir + "fra.med" -OpenDataFile(medFile) +pvsimple.OpenDataFile(medFile) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -172,11 +169,11 @@ print "Changing number of colors:" print "Default number of colors: ", lt.NumberOfTableValues lt.Discretize = 1 -print "Set negative number of colors" -num = -128 -lt.NumberOfTableValues = num -print "Number of colors: ", lt.NumberOfTableValues -pvsimple.Render(view) +#print "Set negative number of colors" +#num = -128 +#lt.NumberOfTableValues = num +#print "Number of colors: ", lt.NumberOfTableValues +#pvsimple.Render(view) print "Set zero number of colors" num = 0 diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E0.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E0.py index 7ccce3e7..8949312c 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E0.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E0") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E1.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E1.py index 3f6e3b4d..cd9fdbf6 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E1.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E1") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E2.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E2.py index 6e77502a..4e439cdc 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E2.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E2") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E3.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E3.py index 18f98906..4721b7eb 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E3.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E3") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E4.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E4.py index 13116f1f..6bc17a31 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E4.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E4") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E5.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E5.py index 9d70f50c..a14b6683 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E5.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E5") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E6.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E6.py index 19846794..3795b5ec 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E6.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E6") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E7.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E7.py index f94b03be..b567e3e3 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E7.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E7") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E8.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E8.py index 87596c68..29096ddb 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E8.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E8") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/E9.py b/test/VisuPrs/ScalarMap_On_DeformedShape/E9.py index 27f41a11..b79a5ac0 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/E9.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E9") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F1.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F1.py index 0a22664c..55aaf4fc 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F1.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F1") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F2.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F2.py index ffa848f2..df152320 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F2.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F2") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F3.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F3.py index 3a470dd2..3b665040 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F3.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F3") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F4.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F4.py index 46634b50..0bd98159 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F4.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F4") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F5.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F5.py index 24762563..b4b9cb36 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F5.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F5") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F6.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F6.py index fd1f1abc..efead06b 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F6.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F6") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F7.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F7.py index 8b868126..8fa9272e 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F7.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F7") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/ScalarMap_On_DeformedShape/F8.py b/test/VisuPrs/ScalarMap_On_DeformedShape/F8.py index c4f2a328..6010a0b5 100755 --- a/test/VisuPrs/ScalarMap_On_DeformedShape/F8.py +++ b/test/VisuPrs/ScalarMap_On_DeformedShape/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F8") +picturedir = get_picture_dir("ScalarMap_On_DeformedShape/F8") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.DEFORMEDSHAPESCALARMAP], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A0.py b/test/VisuPrs/StreamLines/A0.py index 538f42ac..fa3c7ab7 100644 --- a/test/VisuPrs/StreamLines/A0.py +++ b/test/VisuPrs/StreamLines/A0.py @@ -24,21 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A0") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) - -import time -time.sleep(10000) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A1.py b/test/VisuPrs/StreamLines/A1.py index 94083b9e..64a179e6 100644 --- a/test/VisuPrs/StreamLines/A1.py +++ b/test/VisuPrs/StreamLines/A1.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A1") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A2.py b/test/VisuPrs/StreamLines/A2.py index c78c940d..b2da984d 100644 --- a/test/VisuPrs/StreamLines/A2.py +++ b/test/VisuPrs/StreamLines/A2.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A2") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A3.py b/test/VisuPrs/StreamLines/A3.py index 2bbdaa24..e27f79b3 100644 --- a/test/VisuPrs/StreamLines/A3.py +++ b/test/VisuPrs/StreamLines/A3.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A3") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A4.py b/test/VisuPrs/StreamLines/A4.py index 680e50eb..d65b2089 100644 --- a/test/VisuPrs/StreamLines/A4.py +++ b/test/VisuPrs/StreamLines/A4.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A4") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A5.py b/test/VisuPrs/StreamLines/A5.py index ddd37a8d..80b58455 100644 --- a/test/VisuPrs/StreamLines/A5.py +++ b/test/VisuPrs/StreamLines/A5.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A5") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A6.py b/test/VisuPrs/StreamLines/A6.py index c9756861..2dc6879a 100644 --- a/test/VisuPrs/StreamLines/A6.py +++ b/test/VisuPrs/StreamLines/A6.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A6") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A7.py b/test/VisuPrs/StreamLines/A7.py index 396a2449..e068dea9 100644 --- a/test/VisuPrs/StreamLines/A7.py +++ b/test/VisuPrs/StreamLines/A7.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A7") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A8.py b/test/VisuPrs/StreamLines/A8.py index 7682a22b..6ec3cee6 100644 --- a/test/VisuPrs/StreamLines/A8.py +++ b/test/VisuPrs/StreamLines/A8.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A8") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/A9.py b/test/VisuPrs/StreamLines/A9.py index 0077a591..e30c007b 100644 --- a/test/VisuPrs/StreamLines/A9.py +++ b/test/VisuPrs/StreamLines/A9.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/A9") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/B0.py b/test/VisuPrs/StreamLines/B0.py index c33e4fdc..0b557b7d 100644 --- a/test/VisuPrs/StreamLines/B0.py +++ b/test/VisuPrs/StreamLines/B0.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/B0") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/B1.py b/test/VisuPrs/StreamLines/B1.py index 6d4f5d9f..981ecc0b 100644 --- a/test/VisuPrs/StreamLines/B1.py +++ b/test/VisuPrs/StreamLines/B1.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/B1") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/B2.py b/test/VisuPrs/StreamLines/B2.py index db8bd87a..2445391d 100644 --- a/test/VisuPrs/StreamLines/B2.py +++ b/test/VisuPrs/StreamLines/B2.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/B2") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/B3.py b/test/VisuPrs/StreamLines/B3.py index 0d0e8b93..3e79f55d 100644 --- a/test/VisuPrs/StreamLines/B3.py +++ b/test/VisuPrs/StreamLines/B3.py @@ -24,9 +24,6 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -myParavis = paravis.myParavis # Directory for saving snapshots picturedir = get_picture_dir(sys.argv[1], "StreamLines/B3") @@ -40,4 +37,4 @@ for item in files: print "file ", file print "\nCreatePrsForFile..." print "BREAKPOINT_1" - CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) + CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/B4.py b/test/VisuPrs/StreamLines/B4.py index 9604c86b..9aaf6cfd 100644 --- a/test/VisuPrs/StreamLines/B4.py +++ b/test/VisuPrs/StreamLines/B4.py @@ -22,15 +22,12 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file print 'Import "ResOK_0000.med"...............', file_path = datadir + "ResOK_0000.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: print "FAILED" diff --git a/test/VisuPrs/StreamLines/E0.py b/test/VisuPrs/StreamLines/E0.py index a8b7d0fd..fca110ad 100644 --- a/test/VisuPrs/StreamLines/E0.py +++ b/test/VisuPrs/StreamLines/E0.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E0") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E1.py b/test/VisuPrs/StreamLines/E1.py index 72a818a3..b10aab1b 100644 --- a/test/VisuPrs/StreamLines/E1.py +++ b/test/VisuPrs/StreamLines/E1.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E1") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E2.py b/test/VisuPrs/StreamLines/E2.py index 813bca9c..d566b182 100644 --- a/test/VisuPrs/StreamLines/E2.py +++ b/test/VisuPrs/StreamLines/E2.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E2") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E3.py b/test/VisuPrs/StreamLines/E3.py index fbde0c50..8031a500 100644 --- a/test/VisuPrs/StreamLines/E3.py +++ b/test/VisuPrs/StreamLines/E3.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E3") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E4.py b/test/VisuPrs/StreamLines/E4.py index e1920fa8..81f06f9e 100644 --- a/test/VisuPrs/StreamLines/E4.py +++ b/test/VisuPrs/StreamLines/E4.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E4") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E5.py b/test/VisuPrs/StreamLines/E5.py index a5eb7608..a74761f0 100644 --- a/test/VisuPrs/StreamLines/E5.py +++ b/test/VisuPrs/StreamLines/E5.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E5") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E6.py b/test/VisuPrs/StreamLines/E6.py index 719cf9ef..dab469ad 100644 --- a/test/VisuPrs/StreamLines/E6.py +++ b/test/VisuPrs/StreamLines/E6.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E6") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E7.py b/test/VisuPrs/StreamLines/E7.py index fd573081..b4cc8a57 100644 --- a/test/VisuPrs/StreamLines/E7.py +++ b/test/VisuPrs/StreamLines/E7.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E7") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E8.py b/test/VisuPrs/StreamLines/E8.py index 8c135399..11109bd9 100644 --- a/test/VisuPrs/StreamLines/E8.py +++ b/test/VisuPrs/StreamLines/E8.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E8") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/E9.py b/test/VisuPrs/StreamLines/E9.py index 754a6a8f..edc801a4 100644 --- a/test/VisuPrs/StreamLines/E9.py +++ b/test/VisuPrs/StreamLines/E9.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/E9") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F1.py b/test/VisuPrs/StreamLines/F1.py index 4dc8ce5e..2f8f445c 100644 --- a/test/VisuPrs/StreamLines/F1.py +++ b/test/VisuPrs/StreamLines/F1.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F1") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F2.py b/test/VisuPrs/StreamLines/F2.py index b879028a..7a0cc90b 100644 --- a/test/VisuPrs/StreamLines/F2.py +++ b/test/VisuPrs/StreamLines/F2.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F2") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F3.py b/test/VisuPrs/StreamLines/F3.py index bc492657..c9e196d2 100644 --- a/test/VisuPrs/StreamLines/F3.py +++ b/test/VisuPrs/StreamLines/F3.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F3") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F4.py b/test/VisuPrs/StreamLines/F4.py index 742416de..b6ee5b6b 100644 --- a/test/VisuPrs/StreamLines/F4.py +++ b/test/VisuPrs/StreamLines/F4.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F4") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F5.py b/test/VisuPrs/StreamLines/F5.py index ede202bb..0f420d58 100644 --- a/test/VisuPrs/StreamLines/F5.py +++ b/test/VisuPrs/StreamLines/F5.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F5") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F6.py b/test/VisuPrs/StreamLines/F6.py index 4697f6d1..4437aab1 100644 --- a/test/VisuPrs/StreamLines/F6.py +++ b/test/VisuPrs/StreamLines/F6.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F6") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F7.py b/test/VisuPrs/StreamLines/F7.py index 94a8383a..e1987c7f 100644 --- a/test/VisuPrs/StreamLines/F7.py +++ b/test/VisuPrs/StreamLines/F7.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F7") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F8.py b/test/VisuPrs/StreamLines/F8.py index c81227e1..6ab8a0d2 100644 --- a/test/VisuPrs/StreamLines/F8.py +++ b/test/VisuPrs/StreamLines/F8.py @@ -24,18 +24,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F8") -# Create presentations -myParavis = paravis.myParavis - file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "\nCreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.STREAMLINES], picturedir, pictureext) diff --git a/test/VisuPrs/StreamLines/F9.py b/test/VisuPrs/StreamLines/F9.py index 3b06caac..d23f2071 100644 --- a/test/VisuPrs/StreamLines/F9.py +++ b/test/VisuPrs/StreamLines/F9.py @@ -24,19 +24,15 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import StreamLinesOnField, EntityType, \ reset_view, process_prs_for_test -import pvserver as paravis import pvsimple - -my_paravis = paravis.myParavis - # Directory for saving snapshots picturedir = get_picture_dir("StreamLines/F9") # Import of the "Bug829_resu_mode.med" file file_path = datadir + "Bug829_resu_mode.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/StreamLines/G0.py b/test/VisuPrs/StreamLines/G0.py index 3d7e7337..ab42d0b3 100644 --- a/test/VisuPrs/StreamLines/G0.py +++ b/test/VisuPrs/StreamLines/G0.py @@ -1,4 +1,3 @@ - # Copyright (C) 2010-2015 CEA/DEN, EDF R&D # # This library is free software; you can redistribute it and/or @@ -23,23 +22,16 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file file_path = datadir + "new_case.rmed" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError, "new_case.rmed was not imported!!!" # 2. Creation of a set of "StreamLines" presentations, based on time stamps of "RESU_DEPL" field streamlines = StreamLinesOnField(med_reader, EntityType.NODE, 'RESU_DEPL', 1) -if streamlines is None: +if streamlines is None: raise RuntimeError, "Presentation is None!!!" - -import time -time.sleep(10000) - diff --git a/test/VisuPrs/Tables/A0.py b/test/VisuPrs/Tables/A0.py index 83d5e1ae..e21d4e5b 100755 --- a/test/VisuPrs/Tables/A0.py +++ b/test/VisuPrs/Tables/A0.py @@ -25,10 +25,8 @@ import sys from paravistest import tablesdir, get_picture_dir, pictureext from presentations import * -import pvserver as paravis import pvsimple - # Import table from file print 'Import tables_test.xls ....', file_path = tablesdir + "tables_test.xls" @@ -74,5 +72,3 @@ if not picturedir.endswith(os.sep): file_name = picturedir + "sinus." + pictureext pvsimple.WriteImage(file_name, view=xy_view, Magnification=1) - - diff --git a/test/VisuPrs/Tables/A2.py b/test/VisuPrs/Tables/A2.py index f505e322..8fdd4fb9 100755 --- a/test/VisuPrs/Tables/A2.py +++ b/test/VisuPrs/Tables/A2.py @@ -25,7 +25,6 @@ import sys from paravistest import tablesdir, get_picture_dir, pictureext from presentations import * -import pvserver as paravis import pvsimple # Import table from file @@ -72,6 +71,3 @@ if not picturedir.endswith(os.sep): file_name = picturedir + "flux_tab." + pictureext pvsimple.WriteImage(file_name, view=xy_view, Magnification=1) - - - diff --git a/test/VisuPrs/Util/paravistest.py b/test/VisuPrs/Util/paravistest.py index ac5db92e..b32cba09 100755 --- a/test/VisuPrs/Util/paravistest.py +++ b/test/VisuPrs/Util/paravistest.py @@ -231,13 +231,12 @@ def TimeStampId(proxy): return mesh_name, iterations -def Import_Med_Field(paravis, file, field_names, check_errors=0, prs=[]): +def Import_Med_Field(filename, field_names, check_errors=0, prs=[]): """Builds presentations on the given fields of the MED file. Originally defined in VISU_TEST/Grids/visu/ImportMedField/begin file. Arguments: - paravis : PARAVIS instance - file_name : the full path to med file + filename : the full path to med file field_names : the list of field names (for ex: ["pression","temperature","vitesse"]) prs : [[0,1,...], [], []]; empty list (sublist(s)) is ignored 0-VISU.TGAUSSPOINTS @@ -255,15 +254,16 @@ def Import_Med_Field(paravis, file, field_names, check_errors=0, prs=[]): nb_errors = 0 - print "File: ", file + print "File: ", filename # check the file accessibility - if not os.access(file, os.F_OK): - msg = "File " + file + " does not exist!!!" + if not os.access(filename, os.F_OK): + msg = "File " + filename + " does not exist!!!" raise RuntimeError, msg # import MED file - paravis.ImportFile(file) + import pvsimple + pvsimple.OpenDataFile(filename) proxy = presentations.pvs.GetActiveSource() if proxy is None: raise RuntimeError, "ERROR!!! Can't import file!!!" @@ -321,7 +321,7 @@ def Import_Med_Field(paravis, file, field_names, check_errors=0, prs=[]): print "Presentation(s) creation...OK" if nb_errors > 0 and check_errors: - raise RuntimeError, "There are some errors were occured!!! For more information see ERRORs above..." + raise RuntimeError, "Errors occured!!! For more information see ERRORs above..." else: return nb_errors diff --git a/test/VisuPrs/Util/paravistesthelper.py b/test/VisuPrs/Util/paravistesthelper.py index 67f62359..de6216f5 100644 --- a/test/VisuPrs/Util/paravistesthelper.py +++ b/test/VisuPrs/Util/paravistesthelper.py @@ -83,7 +83,7 @@ def run_test(command): # :TRICKY: Special case of returncode=127 # When using paraview in SALOME environment, the following error - # systematicallty appears when exiting paraview (it's also true when using + # systematically appears when exiting paraview (it's also true when using # PARAVIS and exiting SALOME): # Inconsistency detected by ld.so: dl-close.c: 738: _dl_close: Assertion `map->l_init_called' failed! # For PARAVIS tests purpose, paraview functionalities are accessed in each @@ -92,8 +92,12 @@ def run_test(command): # status is considered as "failed". # The tricky part here is to discard such return codes, waiting for a fix # maybe in paraview... + print "#############################" + print res + print _err + print "#############################" if res == 127 and _err.startswith("Inconsistency detected by ld.so: dl-close.c"): - print " ** THE FOLLOWING MESSAGE IS NOT CONSIDERED WHEN ANALYZING TEST SUCCESSFULNESS **" + print " ** THE FOLLOWING MESSAGE IS DISCARDED WHEN ANALYZING TEST SUCCESSFULNESS **" print _err print " ** end of message **" res = 0; diff --git a/test/VisuPrs/Vectors/A0.py b/test/VisuPrs/Vectors/A0.py index 06e2f804..13b49a16 100644 --- a/test/VisuPrs/Vectors/A0.py +++ b/test/VisuPrs/Vectors/A0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A0") +picturedir = get_picture_dir("Vectors/A0") file = datadir + "fra.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A1.py b/test/VisuPrs/Vectors/A1.py index e0600d9d..1b26f542 100755 --- a/test/VisuPrs/Vectors/A1.py +++ b/test/VisuPrs/Vectors/A1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A1") +picturedir = get_picture_dir("Vectors/A1") file = datadir + "hexa_28320_ELEM.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A2.py b/test/VisuPrs/Vectors/A2.py index fd681387..8a6dbcbc 100644 --- a/test/VisuPrs/Vectors/A2.py +++ b/test/VisuPrs/Vectors/A2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A2") +picturedir = get_picture_dir("Vectors/A2") file = datadir + "pointe.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A3.py b/test/VisuPrs/Vectors/A3.py index 08ebc9cb..1ad524c2 100755 --- a/test/VisuPrs/Vectors/A3.py +++ b/test/VisuPrs/Vectors/A3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A3") +picturedir = get_picture_dir("Vectors/A3") file = datadir + "Fields_group3D.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A4.py b/test/VisuPrs/Vectors/A4.py index dd4e58b0..3981b4d9 100755 --- a/test/VisuPrs/Vectors/A4.py +++ b/test/VisuPrs/Vectors/A4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A4") +picturedir = get_picture_dir("Vectors/A4") file = datadir + "Hexa8.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A5.py b/test/VisuPrs/Vectors/A5.py index b65077e9..7afec8dd 100755 --- a/test/VisuPrs/Vectors/A5.py +++ b/test/VisuPrs/Vectors/A5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A5") +picturedir = get_picture_dir("Vectors/A5") file = datadir + "Penta6.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A6.py b/test/VisuPrs/Vectors/A6.py index 9e197166..2ecb018d 100644 --- a/test/VisuPrs/Vectors/A6.py +++ b/test/VisuPrs/Vectors/A6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A6") +picturedir = get_picture_dir("Vectors/A6") file = datadir + "clo.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A7.py b/test/VisuPrs/Vectors/A7.py index fb9d0fba..6ed43437 100755 --- a/test/VisuPrs/Vectors/A7.py +++ b/test/VisuPrs/Vectors/A7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A7") +picturedir = get_picture_dir("Vectors/A7") file = datadir + "Tetra4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A8.py b/test/VisuPrs/Vectors/A8.py index 9ca995d5..02a028d8 100755 --- a/test/VisuPrs/Vectors/A8.py +++ b/test/VisuPrs/Vectors/A8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A8") +picturedir = get_picture_dir("Vectors/A8") file = datadir + "Tria3.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/A9.py b/test/VisuPrs/Vectors/A9.py index 98e01aa5..897b0ceb 100755 --- a/test/VisuPrs/Vectors/A9.py +++ b/test/VisuPrs/Vectors/A9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/A9") +picturedir = get_picture_dir("Vectors/A9") file = datadir + "Quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/B0.py b/test/VisuPrs/Vectors/B0.py index a2563aa6..56a7046e 100755 --- a/test/VisuPrs/Vectors/B0.py +++ b/test/VisuPrs/Vectors/B0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/B0") +picturedir = get_picture_dir("Vectors/B0") file = datadir + "carre_en_quad4_seg2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/B1.py b/test/VisuPrs/Vectors/B1.py index cb886400..29d94253 100755 --- a/test/VisuPrs/Vectors/B1.py +++ b/test/VisuPrs/Vectors/B1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/B1") +picturedir = get_picture_dir("Vectors/B1") file = datadir + "carre_en_quad4_seg2_fields.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/B2.py b/test/VisuPrs/Vectors/B2.py index acdea75b..2c65e543 100755 --- a/test/VisuPrs/Vectors/B2.py +++ b/test/VisuPrs/Vectors/B2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/B2") +picturedir = get_picture_dir("Vectors/B2") file = datadir + "cube_hexa8_quad4.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/B3.py b/test/VisuPrs/Vectors/B3.py index 90d5310e..678a73f0 100644 --- a/test/VisuPrs/Vectors/B3.py +++ b/test/VisuPrs/Vectors/B3.py @@ -23,18 +23,15 @@ import sys from paravistest import datadir from presentations import VectorsOnField, EntityType -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - #====================Stage1: Importing MED file==================== print "**** Stage1: Importing MED file" print 'Import "ResOK_0000.med"...............', medFile = datadir + "ResOK_0000.med" -OpenDataFile(medFile) +pvsimple.OpenDataFile(medFile) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -64,20 +61,20 @@ print "Default subtype : ", glyph.GlyphType.GlyphType print "Default GlyphPos : ", glyph.GlyphType.Center print "Changing value of line width" -width = -10 -vectors.LineWidth = width -print "Negative value -10 : ", vectors.LineWidth -pvsimple.Render() +#width = -10 +#vectors.LineWidth = width +#print "Negative value -10 : ", vectors.LineWidth +#pvsimple.Render() width = 10 vectors.LineWidth = width print "Positive value 10 : ", vectors.LineWidth pvsimple.Render() -width = 0 -vectors.LineWidth = width -print "Zero value 0 : ", vectors.LineWidth -pvsimple.Render() +# width = 0 +# vectors.LineWidth = width +# print "Zero value 0 : ", vectors.LineWidth +# pvsimple.Render() width = 2 vectors.LineWidth = width diff --git a/test/VisuPrs/Vectors/E0.py b/test/VisuPrs/Vectors/E0.py index f02d399f..8dd15ce2 100755 --- a/test/VisuPrs/Vectors/E0.py +++ b/test/VisuPrs/Vectors/E0.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E0") +picturedir = get_picture_dir("Vectors/E0") file = datadir + "test_55_solid_concentr_dom.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E1.py b/test/VisuPrs/Vectors/E1.py index 5a9928fd..d34e6cf2 100755 --- a/test/VisuPrs/Vectors/E1.py +++ b/test/VisuPrs/Vectors/E1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E1") +picturedir = get_picture_dir("Vectors/E1") file = datadir + "H_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E2.py b/test/VisuPrs/Vectors/E2.py index e55b98e1..92563e36 100755 --- a/test/VisuPrs/Vectors/E2.py +++ b/test/VisuPrs/Vectors/E2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E2") +picturedir = get_picture_dir("Vectors/E2") file = datadir + "cas2_2d_couplage_chess_castem.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E3.py b/test/VisuPrs/Vectors/E3.py index 305d902d..479e87a3 100644 --- a/test/VisuPrs/Vectors/E3.py +++ b/test/VisuPrs/Vectors/E3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E3") +picturedir = get_picture_dir("Vectors/E3") file = datadir + "hydro_d10.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E4.py b/test/VisuPrs/Vectors/E4.py index 6b788fa4..a41ede12 100755 --- a/test/VisuPrs/Vectors/E4.py +++ b/test/VisuPrs/Vectors/E4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E4") +picturedir = get_picture_dir("Vectors/E4") file = datadir + "champc.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E5.py b/test/VisuPrs/Vectors/E5.py index 26f26ad5..bee20782 100755 --- a/test/VisuPrs/Vectors/E5.py +++ b/test/VisuPrs/Vectors/E5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E5") +picturedir = get_picture_dir("Vectors/E5") file = datadir + "hydro_sea_alv.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E6.py b/test/VisuPrs/Vectors/E6.py index b9e02d8e..b461117a 100755 --- a/test/VisuPrs/Vectors/E6.py +++ b/test/VisuPrs/Vectors/E6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E6") +picturedir = get_picture_dir("Vectors/E6") file = datadir + "toto.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E7.py b/test/VisuPrs/Vectors/E7.py index e072d357..8ffee458 100755 --- a/test/VisuPrs/Vectors/E7.py +++ b/test/VisuPrs/Vectors/E7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E7") +picturedir = get_picture_dir("Vectors/E7") file = datadir + "couplex_alain.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E8.py b/test/VisuPrs/Vectors/E8.py index 5eca8e33..e25f86d0 100755 --- a/test/VisuPrs/Vectors/E8.py +++ b/test/VisuPrs/Vectors/E8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E8") +picturedir = get_picture_dir("Vectors/E8") file = datadir + "KCOUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/E9.py b/test/VisuPrs/Vectors/E9.py index a104dfd0..c5f4ef99 100755 --- a/test/VisuPrs/Vectors/E9.py +++ b/test/VisuPrs/Vectors/E9.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/E9") +picturedir = get_picture_dir("Vectors/E9") file = datadir + "test_hydro.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F1.py b/test/VisuPrs/Vectors/F1.py index 46205546..690b54fd 100755 --- a/test/VisuPrs/Vectors/F1.py +++ b/test/VisuPrs/Vectors/F1.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F1") +picturedir = get_picture_dir("Vectors/F1") file = datadir + "ml.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F2.py b/test/VisuPrs/Vectors/F2.py index 1d09e38d..08ad9db4 100755 --- a/test/VisuPrs/Vectors/F2.py +++ b/test/VisuPrs/Vectors/F2.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F2") +picturedir = get_picture_dir("Vectors/F2") file = datadir + "T_COUPLEX1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F3.py b/test/VisuPrs/Vectors/F3.py index e27a8aec..8b80b3a4 100755 --- a/test/VisuPrs/Vectors/F3.py +++ b/test/VisuPrs/Vectors/F3.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F3") +picturedir = get_picture_dir("Vectors/F3") file = datadir + "test_hydro_darcy4_out.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F4.py b/test/VisuPrs/Vectors/F4.py index 8296a95a..28657baa 100755 --- a/test/VisuPrs/Vectors/F4.py +++ b/test/VisuPrs/Vectors/F4.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F4") +picturedir = get_picture_dir("Vectors/F4") file = datadir + "UO2_250ans.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F5.py b/test/VisuPrs/Vectors/F5.py index 884b25ae..c5023a7e 100755 --- a/test/VisuPrs/Vectors/F5.py +++ b/test/VisuPrs/Vectors/F5.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F5") +picturedir = get_picture_dir("Vectors/F5") file = datadir + "maill.1.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F6.py b/test/VisuPrs/Vectors/F6.py index 2bdec5ba..6e523dbe 100755 --- a/test/VisuPrs/Vectors/F6.py +++ b/test/VisuPrs/Vectors/F6.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F6") +picturedir = get_picture_dir("Vectors/F6") file = datadir + "maill.0.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F7.py b/test/VisuPrs/Vectors/F7.py index 729bed49..1a121a0e 100644 --- a/test/VisuPrs/Vectors/F7.py +++ b/test/VisuPrs/Vectors/F7.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F7") +picturedir = get_picture_dir("Vectors/F7") file = datadir + "occ4050.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F8.py b/test/VisuPrs/Vectors/F8.py index f6f4ad27..fa2e85d5 100755 --- a/test/VisuPrs/Vectors/F8.py +++ b/test/VisuPrs/Vectors/F8.py @@ -23,17 +23,13 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis - -# Create presentations -myParavis = paravis.myParavis # Directory for saving snapshots -picturedir = get_picture_dir("Vectors/F8") +picturedir = get_picture_dir("Vectors/F8") file = datadir + "maill.2.med" print " --------------------------------- " print "file ", file print " --------------------------------- " print "CreatePrsForFile..." -CreatePrsForFile(myParavis, file, [PrsTypeEnum.VECTORS], picturedir, pictureext) +CreatePrsForFile(file, [PrsTypeEnum.VECTORS], picturedir, pictureext) diff --git a/test/VisuPrs/Vectors/F9.py b/test/VisuPrs/Vectors/F9.py index 29f4156a..f386506c 100644 --- a/test/VisuPrs/Vectors/F9.py +++ b/test/VisuPrs/Vectors/F9.py @@ -20,14 +20,11 @@ # This case corresponds to: /visu/Vectors/F9 case # Create Vectors for field of the the given MED file for 10 timestamps% +import os import sys from paravistest import datadir, pictureext, get_picture_dir -import pvserver as paravis -from pvsimple import GetActiveSource, GetRenderView, Render -from presentations import VectorsOnField, hide_all,EntityType,PrsTypeEnum,reset_view,process_prs_for_test - -# Create presentations -myParavis = paravis.myParavis +from pvsimple import GetActiveSource, GetRenderView, Render, OpenDataFile, UpdatePipeline +from presentations import VectorsOnField, hide_all,EntityType,PrsTypeEnum,reset_view,process_prs_for_test, get_time picturedir = get_picture_dir("Vectors/F9") @@ -41,10 +38,13 @@ print " --------------------------------- " result = OpenDataFile(theFileName) aProxy = GetActiveSource() if aProxy is None: - raise RuntimeError, "Error: can't import file." + raise RuntimeError, "Error: can't import file." else: print "OK" # Get view aView = GetRenderView() +time_value = get_time(aProxy, 0) +aView.ViewTime = time_value +UpdatePipeline(time=time_value, proxy=aProxy) # Create required presentations for the proxy # CreatePrsForProxy(aProxy, aView, thePrsTypeList, thePictureDir, thePictureExt, theIsAutoDelete) @@ -58,24 +58,23 @@ for colored in [False,True]: colored_str = "_colored" for i in range(1,11): hide_all(aView, True) - aPrs = VectorsOnField(aProxy, aFieldEntity, aFieldName, i, is_colored=colored) + aPrs = VectorsOnField(aProxy, aFieldEntity, aFieldName, i, is_colored=colored) if aPrs is None: raise RuntimeError, "Presentation is None!!!" # display only current deformed shape #display_only(aView,aPrs) - aPrs.Visibility =1 + aPrs.Visibility =1 reset_view(aView) Render(aView) # Add path separator to the end of picture path if necessery if not picturedir.endswith(os.sep): picturedir += os.sep prs_type = PrsTypeEnum.VECTORS - + # Get name of presentation type - prs_name = PrsTypeEnum.get_name(prs_type) + prs_name = PrsTypeEnum.get_name(prs_type) f_prs_type = prs_name.replace(' ', '').upper() # Construct image file name pic_name = picturedir + aFieldName+colored_str + "_" + str(i) + "_" + f_prs_type + "." + pictureext # Show and record the presentation process_prs_for_test(aPrs, aView, pic_name) - diff --git a/test/VisuPrs/bugs/A0.py b/test/VisuPrs/bugs/A0.py index 038cb4ff..bd8dbbd2 100644 --- a/test/VisuPrs/bugs/A0.py +++ b/test/VisuPrs/bugs/A0.py @@ -23,17 +23,14 @@ import sys import os from paravistest import datadir, pictureext, get_picture_dir import presentations -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/A0") # 1. Import MED file print 'Importing "hydro_sea_alv.med"...', file_path = datadir + "hydro_sea_alv.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -58,11 +55,3 @@ for ts in xrange(1, len(timestamps) + 1): presentations.process_prs_for_test(cutlines, pvsimple.GetRenderView(), pic_path) nb_lines = len(cutlines.Input.SliceOffsetValues) print "Number of lines = ", nb_lines - - - - - - - - diff --git a/test/VisuPrs/bugs/A1.py b/test/VisuPrs/bugs/A1.py index cd5cefe3..7d565926 100644 --- a/test/VisuPrs/bugs/A1.py +++ b/test/VisuPrs/bugs/A1.py @@ -24,22 +24,19 @@ import os import time from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/A1") med_file_path = datadir + "fra1.med" pic_path = os.path.join(picturedir, "A1." + pictureext) # 1. Import MED file -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() # 2. Create mesh -mesh = MeshOnEntity(med_reader, "LE_VOLUME", EntityType.CELL) +mesh = MeshOnEntity(med_reader, "LE VOLUME", EntityType.CELL) mesh.Representation = 'Surface With Edges' # 3. Display mesh and make snapshot diff --git a/test/VisuPrs/bugs/A2.py b/test/VisuPrs/bugs/A2.py index ebe682bf..eb64828a 100644 --- a/test/VisuPrs/bugs/A2.py +++ b/test/VisuPrs/bugs/A2.py @@ -24,20 +24,17 @@ import os import time from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/A2") -med_file_path = datadir + "carre_MIXTE_0000_v3.0.6.med" +med_file_path = datadir + "carre_MIXTE_0000.med" pic_path = os.path.join(picturedir, "A2." + pictureext) print "BREAKPOINT_1" # 1. Import MED file print 'Importing "carre_MIXTE_0000.med"...', -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/bugs/A3.py b/test/VisuPrs/bugs/A3.py index f2909367..beb66b06 100644 --- a/test/VisuPrs/bugs/A3.py +++ b/test/VisuPrs/bugs/A3.py @@ -22,14 +22,11 @@ import time from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file med_file_path = datadir + "hexa_28320_ELEM.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() # 2. Create vectors @@ -39,13 +36,13 @@ display_only(vectors) reset_view() time.sleep(1) -vectors.Input.SetScaleFactor = 0.005 +#vectors.Input.SetScaleFactor = 0.005 display_only(vectors) reset_view() time.sleep(1) -vectors.Input.SetScaleFactor = 0.002 -display_only(vectors) -reset_view() -time.sleep(1) +#vectors.Input.SetScaleFactor = 0.002 +#display_only(vectors) +#reset_view() +#time.sleep(1) diff --git a/test/VisuPrs/bugs/A4.py b/test/VisuPrs/bugs/A4.py index 70f7626d..1b7b6254 100644 --- a/test/VisuPrs/bugs/A4.py +++ b/test/VisuPrs/bugs/A4.py @@ -22,14 +22,11 @@ import time from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file med_file_path = datadir + "carre_ELEM_0000.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() # 2. Create vectors diff --git a/test/VisuPrs/bugs/A5.py b/test/VisuPrs/bugs/A5.py index 9dd57f5e..fca0fa4f 100644 --- a/test/VisuPrs/bugs/A5.py +++ b/test/VisuPrs/bugs/A5.py @@ -24,9 +24,9 @@ import salome from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple +salome.salome_init() myStudy = salome.myStudy myStudyManager = salome.myStudyManager @@ -39,9 +39,10 @@ if tmp_dir == None: save_file = tmp_dir + "/TimeStamps_save.hdf" print "Save to file ", save_file -paravis.OpenDataFile(data_file) +pvsimple.OpenDataFile(data_file) myStudyManager.SaveAs(save_file, myStudy, 0) myStudyManager.Close(myStudy) + openedStudy = myStudyManager.Open(data_file) myStudyManager.Close(openedStudy) diff --git a/test/VisuPrs/bugs/A6.py b/test/VisuPrs/bugs/A6.py index f13eadf6..69acc3f2 100644 --- a/test/VisuPrs/bugs/A6.py +++ b/test/VisuPrs/bugs/A6.py @@ -23,18 +23,15 @@ import sys import os from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/A6") med_file_path = datadir + "fra.med" # 1. Import MED file print 'Importing "fra.med"....', -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -51,10 +48,8 @@ for mesh_name in [get_field_short_name(name) for name in mesh_names]: raise RuntimeError, "Error" mesh.Representation = 'Wireframe' - + pic_path = os.path.join(picturedir, mesh_name + "_Cell." + pictureext) pic_path = re.sub("\s+","_", pic_path) print "Save picture ", pic_path process_prs_for_test(mesh, pvsimple.GetRenderView(), pic_path) - - diff --git a/test/VisuPrs/bugs/A7.py b/test/VisuPrs/bugs/A7.py index b027a46f..6338692f 100644 --- a/test/VisuPrs/bugs/A7.py +++ b/test/VisuPrs/bugs/A7.py @@ -22,13 +22,10 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import CreatePrsForFile, PrsTypeEnum -import pvserver as paravis -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/A7") med_file_path = datadir + "hexa_28320_ELEM.med" -CreatePrsForFile(my_paravis, med_file_path, [PrsTypeEnum.MESH], picturedir, pictureext) -CreatePrsForFile(my_paravis, med_file_path, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) -CreatePrsForFile(my_paravis, med_file_path, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) +CreatePrsForFile(med_file_path, [PrsTypeEnum.MESH], picturedir, pictureext) +CreatePrsForFile(med_file_path, [PrsTypeEnum.SCALARMAP], picturedir, pictureext) +CreatePrsForFile(med_file_path, [PrsTypeEnum.CUTPLANES], picturedir, pictureext) diff --git a/test/VisuPrs/bugs/A9.py b/test/VisuPrs/bugs/A9.py index 10b4b3d2..6f6e761d 100644 --- a/test/VisuPrs/bugs/A9.py +++ b/test/VisuPrs/bugs/A9.py @@ -24,20 +24,16 @@ import sys from paravistest import datadir, get_picture_dir, pictureext from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/A9") # 1. Step1: Import MED file print "**** Step1: Importing MED file" print 'Import "sortie_med_volumique.med"...............', -file_path = datadir + "sortie_med_volumique_v3.0.6.med" -OpenDataFile(file_path) +file_path = datadir + "sortie_med_volumique.med" +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -52,8 +48,8 @@ if view is None: else: reset_view(view) print "OK" - -mesh_name = 'Volume_fluide' + +mesh_name = 'Volume fluide' cell_entity = EntityType.CELL node_entity = EntityType.NODE diff --git a/test/VisuPrs/bugs/B1.py b/test/VisuPrs/bugs/B1.py index 7ddeb6f8..4179421c 100644 --- a/test/VisuPrs/bugs/B1.py +++ b/test/VisuPrs/bugs/B1.py @@ -23,18 +23,15 @@ import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/B1") # 1. Import MED file med_file_path = datadir + "resultat.01.med" print 'Importing "resultat.01.med"....', -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -54,15 +51,15 @@ for group in groups: shor_name = group.split('/')[-1] print "group: ", shor_name prs = MeshOnGroup(med_reader, extGrp, group) - - if prs is None : + + if prs is None : print "FAILED!!! Created presentation is None!!!" errors += 1 else : print "Presentation was created!" pic_path = os.path.join(picturedir, shor_name.strip().split("_")[0]+str(i)+"."+pictureext) - process_prs_for_test(prs, pvsimple.GetRenderView(), pic_path) - + process_prs_for_test(prs, pvsimple.GetRenderView(), pic_path) + # check errors if errors == 1: diff --git a/test/VisuPrs/bugs/C3.py b/test/VisuPrs/bugs/C3.py index ced563c2..2ef4bcb7 100644 --- a/test/VisuPrs/bugs/C3.py +++ b/test/VisuPrs/bugs/C3.py @@ -21,16 +21,13 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file med_file_path = datadir + "MEDfileForStructuredMesh.med" print 'Importing "MEDfileForStructuredMesh.med"....', -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: diff --git a/test/VisuPrs/bugs/C4.py b/test/VisuPrs/bugs/C4.py index 949ddeef..1c3fdff9 100644 --- a/test/VisuPrs/bugs/C4.py +++ b/test/VisuPrs/bugs/C4.py @@ -23,18 +23,15 @@ import sys import os from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/C4") # 1. Import MED file med_file_path = datadir + "forma01f.resu.med" print 'Importing "forma01f.resu.med"....', -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -52,19 +49,19 @@ view = pvsimple.GetRenderView() for scale in scales: for i in range(len(fields)): - print "Field: ", fields[i], "; Scale: ", scale + print "Field: ", fields[i], "; Scale: ", scale presentation = None try: presentation = DeformedShapeAndScalarMapOnField(med_reader, entities[i], fields[i], 1) except ValueError as e: print "Error:", e - - if presentation is not None: - if scale is not None: - presentation.Input.ScaleFactor = scale + + if presentation is not None: + if scale is not None: + presentation.Input.ScaleFactor = scale # save picture pic_path = os.path.join(picturedir, "MAIL_" + entities_str[i] + "_" + fields[i] + "_" + str(scale) + "_." + pictureext) process_prs_for_test(presentation, view, pic_path) else: - print "FAILED! Created presentation is None!!!" + print "FAILED! Created presentation is None!!!" diff --git a/test/VisuPrs/bugs/C5.py b/test/VisuPrs/bugs/C5.py index 47cdac8b..2d98084e 100644 --- a/test/VisuPrs/bugs/C5.py +++ b/test/VisuPrs/bugs/C5.py @@ -24,11 +24,8 @@ import os import time from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - medPath = datadir class DisplayManager: @@ -43,11 +40,11 @@ class DisplayManager: self.meshName = None self.myData = None self.myMesh = None - self.myEntity = None - + self.myEntity = None + def loadData(self, medFile, meshName=None, myEntity=EntityType.NODE): self.medFile = medFile - OpenDataFile(medFile) + pvsimple.OpenDataFile(medFile) self.myData = pvsimple.GetActiveSource() self.myEntity = myEntity if meshName is not None: @@ -55,7 +52,7 @@ class DisplayManager: def getData(self): return self.myData - + def checkData(self): if ( self.myData is None or self.myMesh is None ): return False @@ -70,7 +67,7 @@ class DisplayManager: def DisplayMap(self, aView, aMap, title, aDelay=0): if aMap is None: - print "Null scalar map is created" + print "Null scalar map is created" display_only(aMap, aView) reset_view(aView) time.sleep(aDelay) @@ -84,14 +81,14 @@ class DisplayManager: if not self.checkData(): return aMap = DeformedShapeOnField(self.myData, self.myEntity, fieldName, iteration) if aMap is not None: - aMap.ColorArrayName = fieldName + aMap.ColorArrayName = ("CELLS", fieldName) self.DisplayMap(aView, aMap, title, delay) def Vectors(self, aView, fieldName, iteration, title , delay=0): if not self.checkData(): return aMap = VectorsOnField(self.myData, self.myEntity, fieldName, iteration) if aMap is not None: - aMap.ColorArrayName = fieldName + aMap.ColorArrayName = ("CELLS", fieldName) self.DisplayMap(aView, aMap, title, delay) def IsoSurfaces(self, aView, fieldName, iteration, title , delay=0): @@ -104,10 +101,10 @@ class DisplayManager: path = None if aPath is not "": print "Define save path" - path = aPath - + path = aPath + scene = pvsimple.AnimateReader(theObj, aView, path) - + print "Start Animation" scene.Duration = theDuration @@ -132,7 +129,7 @@ class DisplayManager: # >>> Create curve myView = CreateXYPlotView() myCurve = Show(table, view = myView) - + def createView(): aView=pvsimple.GetRenderView() return aView diff --git a/test/VisuPrs/bugs/C6.py b/test/VisuPrs/bugs/C6.py index 88b1facb..4a40d648 100644 --- a/test/VisuPrs/bugs/C6.py +++ b/test/VisuPrs/bugs/C6.py @@ -23,18 +23,15 @@ import sys import os from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/C6") # 1. Import MED file med_file_path = datadir + "relachement_brutal_sans_dudg_gauss.med" print 'Importing "relachement_brutal_sans_dudg_gauss.med"....', -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -54,5 +51,3 @@ for timestamp in timestamp_list: raise RuntimeError, "Created presentation is None!!!" pic_path = os.path.join(picturedir, "GaussPoints_" + mesh_name + "_" + field_name + "_" + str(timestamp) + "." + pictureext) process_prs_for_test(gauss_points, pvsimple.GetRenderView(), pic_path) - - diff --git a/test/VisuPrs/bugs/C7.py b/test/VisuPrs/bugs/C7.py index d9c87235..b0b9f786 100644 --- a/test/VisuPrs/bugs/C7.py +++ b/test/VisuPrs/bugs/C7.py @@ -23,18 +23,15 @@ import os import sys from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/C7") # 1. Import MED file med_file_path = datadir + "Bug583-Quadratique.resu.med" print 'Importing "Bug583-Quadratique.resu.med"....', -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -55,7 +52,7 @@ for field in field_names: print "Creation of the GaussPoints presentation.. Field: ", field, "; Iteration: 1" presentation = GaussPointsOnField1(med_reader, EntityType.CELL, field, 1) if presentation is None: - print "ERROR!!! GaussPoints presentation wasn't created for the ", field, " field!!!" + print "ERROR!!! GaussPoints presentation wasn't created for the ", field, " field!!!" error += 1 else: pic_path = os.path.join(picturedir, "GaussPoints_" + mesh_name + "_" + field + "." + pictureext) diff --git a/test/VisuPrs/bugs/C8.py b/test/VisuPrs/bugs/C8.py index 5c65251f..ff582067 100644 --- a/test/VisuPrs/bugs/C8.py +++ b/test/VisuPrs/bugs/C8.py @@ -21,7 +21,6 @@ from paravistest import tablesdir from presentations import * -import pvserver as paravis import pvsimple # 1. Import table from file @@ -59,8 +58,8 @@ for table in available_tables: xy_rep.AttributeType = 'Row Data' xy_rep.UseIndexForXAxis = 0 xy_rep.SeriesVisibility = ['0', '0'] - + pvsimple.Render() - + diff --git a/test/VisuPrs/bugs/C9.py b/test/VisuPrs/bugs/C9.py index 85d108cd..2a8ece06 100644 --- a/test/VisuPrs/bugs/C9.py +++ b/test/VisuPrs/bugs/C9.py @@ -21,15 +21,12 @@ from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file med_file_path = datadir + "TimeStamps.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -37,7 +34,7 @@ if med_reader is None: # 2. Creation of presentations mesh_on_cells = MeshOnEntity(med_reader, "dom", EntityType.CELL) -if mesh_on_cells is None : +if mesh_on_cells is None : raise RuntimeError, "Mesh presentation is None!!!" view = pvsimple.GetRenderView() @@ -47,7 +44,7 @@ reset_view(view) mesh_on_cells.Representation = 'Wireframe' scalar_map = ScalarMapOnField(med_reader, EntityType.NODE, "vitesse", 1) -if scalar_map is None : +if scalar_map is None : raise RuntimeError, "ScalarMap presentation is None!!!" scalar_map.Visibility = 1 diff --git a/test/VisuPrs/bugs/D0.py b/test/VisuPrs/bugs/D0.py index 86722cd2..962cc122 100644 --- a/test/VisuPrs/bugs/D0.py +++ b/test/VisuPrs/bugs/D0.py @@ -24,18 +24,16 @@ import os import time from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/D0") # Aux method def get_group_full_name(source, group_name): result_name = group_name - - full_names = source.Groups.Available + + #full_names = source.Groups.Available + full_names = get_group_names(source) for name in full_names: if name.endswith(group_name): result_name = name @@ -46,7 +44,7 @@ def get_group_full_name(source, group_name): # 1. Import of the "Bug619-result_calcul_OCC.med" file med_file_path = datadir + "Bug619-result_calcul_OCC.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -62,13 +60,13 @@ groups = ['TU_3D_G1', 'TU_3D_D1'] for group_name in groups: extract_group = pvsimple.ExtractGroup(med_reader) - extract_group.Groups = [get_group_full_name(med_reader, group_name)] + #extract_group.Groups = [get_group_full_name(med_reader, group_name)] + extract_group.AllGroups = [get_group_full_name(extract_group, group_name)] extract_group.UpdatePipeline() - + scalar_map = ScalarMapOnField(extract_group, EntityType.CELL, field_name, 1) if scalar_map is None : raise RuntimeError, "ScalarMap presentation on '" + group_name + "' group is None!!!" pic_path = os.path.join(picturedir, "npal18711_" + group_name + "." + pictureext) process_prs_for_test(scalar_map, view, pic_path) - diff --git a/test/VisuPrs/bugs/D1.py b/test/VisuPrs/bugs/D1.py index ced55496..e781c12b 100644 --- a/test/VisuPrs/bugs/D1.py +++ b/test/VisuPrs/bugs/D1.py @@ -23,16 +23,13 @@ import sys import os from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -os.environ["PARAVIS_TEST_PICS"] = sys.argv[1] picturedir = get_picture_dir("bugs/D1") # 1. Import of the "Bug829_resu_mode.med" file at first time med_file_path = datadir + "Bug829_resu_mode.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader1 = pvsimple.GetActiveSource() if med_reader1 is None: raise RuntimeError, "Bug829_resu_mode.med was not imported!!!" @@ -43,7 +40,7 @@ sizes=[] for i in range(1,11): presentation = DeformedShapeAndScalarMapOnField(med_reader1, EntityType.NODE, "MODES___DEPL____________________", i) - if presentation is None : + if presentation is None : raise RuntimeError, "Presentation is None!!!" pic_path = os.path.join(picturedir, "npal19999_1_time_stamp_" + str(i) + "." + pictureext) @@ -55,12 +52,12 @@ if abs(max(sizes)-min(sizes)) > 0.01*max(sizes): print "WARNING!!! Pictures have different sizes!!!" errors += 1 for i in range(1,11): - picture_name = "npal19999_1_time_stamp_" + str(i) + "." + pictureext - print "Picture: " + picture_name + "; size: " + str(sizes[i-1]) + picture_name = "npal19999_1_time_stamp_" + str(i) + "." + pictureext + print "Picture: " + picture_name + "; size: " + str(sizes[i-1]) raise RuntimeError # 3. Import of the "Bug829_resu_mode.med" file at second time -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader2 = pvsimple.GetActiveSource() if med_reader2 is None: raise RuntimeError, "Bug829_resu_mode.med was not imported second time!!!" @@ -71,7 +68,7 @@ sizes=[] for i in range(1,11): presentation = DeformedShapeAndScalarMapOnField(med_reader2, EntityType.NODE, "MODES___DEPL____________________", 11-i) - if presentation is None : + if presentation is None : raise RuntimeError, "Presentation is None!!!" pic_path = os.path.join(picturedir, "npal19999_2_time_stamp_" + str(i) + "." + pictureext) @@ -83,6 +80,6 @@ if abs(max(sizes)-min(sizes)) > 0.01*max(sizes): print "WARNING!!! Pictures have different sizes!!!" errors += 1 for i in range(1,11): - picture_name = "npal19999_2_time_stamp_" + str(i) + "." + pictureext - print "Picture: " + picture_name + "; size: " + str(sizes[i-1]) + picture_name = "npal19999_2_time_stamp_" + str(i) + "." + pictureext + print "Picture: " + picture_name + "; size: " + str(sizes[i-1]) raise RuntimeError diff --git a/test/VisuPrs/bugs/D3.py b/test/VisuPrs/bugs/D3.py index 743efbc1..420164ae 100644 --- a/test/VisuPrs/bugs/D3.py +++ b/test/VisuPrs/bugs/D3.py @@ -21,14 +21,11 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import of the "LinearStaticsSTA9.resu.med" file med_file_path = datadir + "LinearStaticsSTA9.resu.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError, "LinearStaticsSTA9.resu.med was not imported!!!" @@ -37,15 +34,15 @@ view = pvsimple.GetRenderView() # Creation of colored "DeformedShape" presentations, based on time stamps of "RESU_DEPL" field presentation = DeformedShapeOnField(med_reader, EntityType.NODE, 'RESU____DEPL____________________', 1, is_colored=True) -if presentation is None : +if presentation is None : raise RuntimeError, "DeformedShapeOnField Presentation is None!!!" display_only(presentation, view) reset_view(view) - + # Creation of colored "Vectors" presentations, based on time stamps of "RESU_DEPL" field presentation = VectorsOnField(med_reader, EntityType.NODE, 'RESU____DEPL____________________', 1, is_colored=True) -if presentation is None : +if presentation is None : raise RuntimeError, "Vectors Presentation is None!!!" display_only(presentation, view) @@ -53,7 +50,7 @@ reset_view(view) # Creation of colored "DeformedShapeAndScalarMap" presentations, based on time stamps of "RESU_DEPL" field presentation = DeformedShapeAndScalarMapOnField(med_reader, EntityType.NODE, 'RESU____DEPL____________________', 1) -if presentation is None : +if presentation is None : raise RuntimeError, "DeformedShapeAndScalarMap Presentation is None!!!" display_only(presentation, view) @@ -61,7 +58,7 @@ reset_view(view) # Creation of colored "CutPlanes" presentations, based on time stamps of "RESU_DEPL" field presentation = CutPlanesOnField(med_reader, EntityType.NODE, 'RESU____DEPL____________________', 1) -if presentation is None : +if presentation is None : raise RuntimeError, "CutPlanes Presentation is None!!!" display_only(presentation, view) diff --git a/test/VisuPrs/bugs/D5.py b/test/VisuPrs/bugs/D5.py index deefe47d..6323f013 100644 --- a/test/VisuPrs/bugs/D5.py +++ b/test/VisuPrs/bugs/D5.py @@ -19,7 +19,6 @@ from paravistest import tablesdir from presentations import * -import pvserver as paravis import pvsimple # Import table from file diff --git a/test/VisuPrs/bugs/D6.py b/test/VisuPrs/bugs/D6.py index cb1ca266..af847697 100644 --- a/test/VisuPrs/bugs/D6.py +++ b/test/VisuPrs/bugs/D6.py @@ -21,15 +21,12 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file med_file_path = datadir + "fra.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() # 2. Creation of CutSegment presentations, based on time stamps of "VITESSE" field @@ -38,7 +35,7 @@ point2 = [0.4, 0.05, 1.0] cut_segment1 = CutSegmentOnField(med_reader, EntityType.NODE, "VITESSE", 1, point1, point2) if cut_segment1 == None: - raise RuntimeError, "ERROR!!! The first CutSegment presentation is not built!" + raise RuntimeError, "ERROR!!! The first CutSegment presentation is not built!" # 3. Creation of CutSegment presentations, based on time stamps of "TAUX_DE_VIDE" field point1 = [0, 0, 1] diff --git a/test/VisuPrs/bugs/D7.py b/test/VisuPrs/bugs/D7.py index 0694bcb8..ec8d5990 100644 --- a/test/VisuPrs/bugs/D7.py +++ b/test/VisuPrs/bugs/D7.py @@ -23,16 +23,13 @@ import sys import os from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. MED file import print 'Importing "Fields_group3D.med"........', med_file_path = datadir + "Fields_group3D.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: print "FAILED" @@ -55,8 +52,9 @@ if scalarmap is None: else: print "OK" -med_reader.Groups = ['GROUP/mailles_MED/OnCell/box_1'] +extract_group = pvsimple.ExtractGroup(med_reader) +extract_group.UpdatePipelineInformation() +extract_group.AllGroups = ['GRP_box_1'] display_only(scalarmap, view) reset_view(view) - diff --git a/test/VisuPrs/bugs/E0.py b/test/VisuPrs/bugs/E0.py index 8a9a9e61..873b163b 100644 --- a/test/VisuPrs/bugs/E0.py +++ b/test/VisuPrs/bugs/E0.py @@ -22,16 +22,14 @@ import time from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple sleep_delay = 1 -my_paravis = paravis.myParavis # 1. MED file import print 'Import "ResOK_0000.med"...............', med_file_path = datadir + "ResOK_0000.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError, "ResOK_0000.med was not imported!!!" diff --git a/test/VisuPrs/dump_study/A0.py b/test/VisuPrs/dump_study/A0.py index 780d038b..8087706f 100644 --- a/test/VisuPrs/dump_study/A0.py +++ b/test/VisuPrs/dump_study/A0.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal'} # 1. TimeStamps.med import diff --git a/test/VisuPrs/dump_study/A1.py b/test/VisuPrs/dump_study/A1.py index 79b3773a..e0ef96d7 100644 --- a/test/VisuPrs/dump_study/A1.py +++ b/test/VisuPrs/dump_study/A1.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal', "NbSurfaces": 444} # 1. TimeStamps.med import diff --git a/test/VisuPrs/dump_study/A2.py b/test/VisuPrs/dump_study/A2.py index 5134644f..b996b2e5 100644 --- a/test/VisuPrs/dump_study/A2.py +++ b/test/VisuPrs/dump_study/A2.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal'} # 1. TimeStamps.med import diff --git a/test/VisuPrs/dump_study/A3.py b/test/VisuPrs/dump_study/A3.py index 23d4d3ae..2e3cfa3e 100644 --- a/test/VisuPrs/dump_study/A3.py +++ b/test/VisuPrs/dump_study/A3.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal', "Scale": 0.333, "ColorArray": "", "ColorComponents": [0.111, 0.222, 0.333]} # 1. TimeStamps.med import @@ -49,7 +46,7 @@ deformedshape.LookupTable.NumberOfTableValues = settings["NbColors"] deformedshape.LookupTable.UseLogScale = settings["UseLogScale"] deformedshape.Input.ScaleFactor = settings["Scale"] -deformedshape.ColorArrayName = '' +deformedshape.ColorArrayName = (None, '') deformedshape.AmbientColor = settings["ColorComponents"] bar = get_bar() @@ -161,7 +158,7 @@ if abs(scale - settings["Scale"]) > tolerance: errors += 1 # Color array name -array_name = recreated_deformedshape.ColorArrayName +array_name = recreated_deformedshape.ColorArrayName[1] if array_name != settings["ColorArray"]: print "ERROR!!! Color array name of presentation is incorrect: ", array_name, " instead of ", settings["arrayName"] errors += 1 diff --git a/test/VisuPrs/dump_study/A4.py b/test/VisuPrs/dump_study/A4.py index 2563c7da..ce566bb4 100644 --- a/test/VisuPrs/dump_study/A4.py +++ b/test/VisuPrs/dump_study/A4.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 1), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation"} # 1. TimeStamps.med import diff --git a/test/VisuPrs/dump_study/A5.py b/test/VisuPrs/dump_study/A5.py index d78fc020..4a6583af 100644 --- a/test/VisuPrs/dump_study/A5.py +++ b/test/VisuPrs/dump_study/A5.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal', "ScaleFactor": 0.25, "NbContours": 4} # 1. TimeStamps.med import diff --git a/test/VisuPrs/dump_study/A6.py b/test/VisuPrs/dump_study/A6.py index 164a7d42..7a024830 100644 --- a/test/VisuPrs/dump_study/A6.py +++ b/test/VisuPrs/dump_study/A6.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal', "Scale": 0.12929} # 1. TimeStamps.med import @@ -165,7 +162,7 @@ if abs(cur_range_min - range_min) > tolerance: if abs(cur_range_max - range_max) > tolerance: print "ERROR!!! Maximum value of range of presentation is incorrect: ", cur_range_max, " instead of ", range_max errors += 1 - + # Scale factor scale = recreated_prs.Input.ScaleFactor if abs(scale - settings["Scale"]) > tolerance: diff --git a/test/VisuPrs/dump_study/A7.py b/test/VisuPrs/dump_study/A7.py index b5dd3343..65dc0bc9 100644 --- a/test/VisuPrs/dump_study/A7.py +++ b/test/VisuPrs/dump_study/A7.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - # StreamLines settings settings = {'name': 'myStreamLines', 'IntegrationDirection': 'FORWARD', diff --git a/test/VisuPrs/dump_study/A8.py b/test/VisuPrs/dump_study/A8.py index 3989a183..32a28fd1 100644 --- a/test/VisuPrs/dump_study/A8.py +++ b/test/VisuPrs/dump_study/A8.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal', "Scale": 0.333, "ColorArray": "", "ColorComponents": [0.111, 0.222, 0.333], "LineWidth": 2, "GlyphType": 'Cone', "GlyphPos": [-0.5, 0.0, 0.0]} # 1. TimeStamps.med import @@ -49,7 +46,7 @@ vectors.LookupTable.NumberOfTableValues = settings["NbColors"] vectors.LookupTable.UseLogScale = settings["UseLogScale"] vectors.Input.SetScaleFactor = settings["Scale"] -vectors.ColorArrayName = '' +vectors.ColorArrayName = (None, '') vectors.AmbientColor = settings["ColorComponents"] vectors.LineWidth = settings["LineWidth"] @@ -167,7 +164,7 @@ if abs(scale - settings["Scale"]) > tolerance: errors += 1 # Color array name -array_name = recreated_vectors.ColorArrayName +array_name = recreated_vectors.ColorArrayName[1] if array_name != settings["ColorArray"]: print "ERROR!!! Color array name of presentation is incorrect: ", array_name, " instead of ", settings["arrayName"] errors += 1 diff --git a/test/VisuPrs/dump_study/A9.py b/test/VisuPrs/dump_study/A9.py index a29bf81d..e14157f7 100644 --- a/test/VisuPrs/dump_study/A9.py +++ b/test/VisuPrs/dump_study/A9.py @@ -21,11 +21,8 @@ from paravistest import datadir, delete_with_inputs from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - settings = {"Offset": [0.0001, 0.0002, 0], "ScalarMode": ("Component", 2), "Position": [0.1, 0.2], "Size": [0.15, 0.25], "Discretize": 1, "NbColors": 44, "NbLabels": 22, "Title": "My presentation", "UseLogScale": 1, "Orientation": 'Horizontal', "Orientation_BasePlane": [Orientation.ZX, 22, 33], "Orientation_CuttingPlanes": [Orientation.YZ, 44, 55], "Displacement": 0.1, "Displacement2": 0.2, "BasePlane_Position": 0.1, "NbLines": 3} # 1. TimeStamps.med import diff --git a/test/VisuPrs/dump_study/B0.py b/test/VisuPrs/dump_study/B0.py index 452447f5..3d6062bd 100644 --- a/test/VisuPrs/dump_study/B0.py +++ b/test/VisuPrs/dump_study/B0.py @@ -21,11 +21,8 @@ from paravistest import datadir from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - # 1. TimeStamps.med import file_path = datadir + "TimeStamps.med" OpenDataFile(file_path) @@ -43,10 +40,10 @@ med_field = "vitesse" for name in prs_names: print "Creation of ", name, " presentation..." if name == "GaussPoints": - prs = GaussPointsOnField(med_reader, EntityType.CELL, "pression", 1) - pass - else: - prs = eval(name + "OnField(med_reader, EntityType.NODE, med_field, 1)") + prs = GaussPointsOnField(med_reader, EntityType.CELL, "pression", 1) + pass + else: + prs = eval(name + "OnField(med_reader, EntityType.NODE, med_field, 1)") if prs is None: print "ERROR!!! ", name," presentation wasn't created..." errors += 1 diff --git a/test/VisuPrs/dump_study/B1.py b/test/VisuPrs/dump_study/B1.py index 244a937e..328580f0 100644 --- a/test/VisuPrs/dump_study/B1.py +++ b/test/VisuPrs/dump_study/B1.py @@ -21,11 +21,8 @@ from paravistest import tablesdir from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - # Import table from file xls_file = tablesdir + "tables_test.xls" table_reader = TableReader(FileName=xls_file) @@ -58,15 +55,15 @@ count_not=0 for name in tables: if name not in available_tables: - count_not += 1 - print "ERROR!!! Table with ", name, " name was not found" + count_not += 1 + print "ERROR!!! Table with ", name, " name was not found" errors += 1 else: print "\"" + name + "\" table was found..." if count_not > 0: print "ERROR!!! "+str(count_not)+" table(s) was(were) not found!!!" - errors += 1 + errors += 1 if errors > 0: raise RuntimeError, "There is(are) some error(s) was(were) found... For more info see ERRORs above..." diff --git a/test/VisuPrs/dump_study/B3.py b/test/VisuPrs/dump_study/B3.py index 26236cc2..5269eff4 100644 --- a/test/VisuPrs/dump_study/B3.py +++ b/test/VisuPrs/dump_study/B3.py @@ -21,11 +21,8 @@ import paravistest from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - # 1. Table creation title = "My Table" errors = 0 @@ -90,6 +87,6 @@ if table.Script != orig_script: print "ERROR!!! The script value is incorrect:" print table.Script errors += 1 - + if errors > 0: raise RuntimeError, "There is(are) some error(s) was(were) found... For more info see ERRORs above..." diff --git a/test/VisuPrs/dump_study/B4.py b/test/VisuPrs/dump_study/B4.py index 49c4d8ee..80556bd5 100644 --- a/test/VisuPrs/dump_study/B4.py +++ b/test/VisuPrs/dump_study/B4.py @@ -21,11 +21,8 @@ import paravistest from presentations import * -import pvserver as paravis from pvsimple import * -my_paravis = paravis.myParavis - # 1. Table creation title = "My Table" errors = 0 @@ -90,6 +87,6 @@ if table.Script != orig_script: print "ERROR!!! The script value is incorrect:" print table.Script errors += 1 - + if errors > 0: raise RuntimeError, "There is(are) some error(s) was(were) found... For more info see ERRORs above..." diff --git a/test/VisuPrs/dump_study/B5.py b/test/VisuPrs/dump_study/B5.py index f7ffd88b..610d38c6 100644 --- a/test/VisuPrs/dump_study/B5.py +++ b/test/VisuPrs/dump_study/B5.py @@ -23,33 +23,31 @@ import os import sys import salome -class SalomeSession(object): - def __init__(self): - import runSalome - import sys - sys.argv += ["--show-desktop=1"] - sys.argv += ["--splash=0"] - sys.argv += ["--modules=MED,VISU,PARAVIS"] - clt, d = runSalome.main() - port = d['port'] - self.port = port - return - pass +# class SalomeSession(object): +# def __init__(self): +# import runSalome +# import sys +# sys.argv += ["--show-desktop=1"] +# sys.argv += ["--splash=0"] +# sys.argv += ["--modules=MED,VISU,PARAVIS"] +# clt, d = runSalome.main() +# port = d['port'] +# self.port = port +# return +# pass # 1. Opening saved study # run Salome -salome_session = SalomeSession() +#salome_session = SalomeSession() salome.salome_init() +salome.myStudyManager.Close(salome.myStudy) file_name = os.path.join(os.path.dirname(sys.argv[0]), "test1.hdf") opened_study = salome.myStudyManager.Open(file_name) salome.myStudy = opened_study -# 2. Load PARAVIS module -import pvserver as paravis - # 3. Find IsoSurfaces from pvsimple import * obj = FindSource('IsoSurfaces') @@ -59,7 +57,7 @@ if obj is None: # 4. Remove med reader object and all other sources for obj in GetSources().values(): Delete(obj) - + # 5. Check results obj = FindSource('ScalarMap') if obj is not None: diff --git a/test/VisuPrs/imps/A1.py b/test/VisuPrs/imps/A1.py index eecabd72..118ec742 100644 --- a/test/VisuPrs/imps/A1.py +++ b/test/VisuPrs/imps/A1.py @@ -23,10 +23,8 @@ import sys import os from paravistest import datadir, pictureext, get_picture_dir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis picturedir = get_picture_dir("imps/A1") def set_prs_colored(prs, proxy, entity, field_name, vector_mode, timestamp_nb): @@ -58,7 +56,7 @@ def set_prs_colored(prs, proxy, entity, field_name, vector_mode, timestamp_nb): # 1. Import of the "Penta6.med" file print 'Import "Penta6.med" file........', file_path = datadir + "Penta6.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: raise RuntimeError, "Penta6.med was not imported!!!" diff --git a/test/VisuPrs/imps/A2.py b/test/VisuPrs/imps/A2.py index 73fb6a05..2ef8dcd4 100644 --- a/test/VisuPrs/imps/A2.py +++ b/test/VisuPrs/imps/A2.py @@ -22,10 +22,8 @@ import time from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis sleep_delay = 2 med_file = "pointe.med" @@ -36,7 +34,7 @@ timestamp = 1 # 1. Import MED file print 'Import "pointe.med"....................', med_file_path = datadir + med_file -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -63,7 +61,7 @@ print "Set Point Sprite representation" scalar_map.Representation = 'Point Sprite' data_range = get_data_range(med_reader, entity, - field_name, 'Magnitude') + field_name, 'Magnitude') mult = abs(0.1 / data_range[1]) scalar_map.RadiusScalarRange = data_range scalar_map.RadiusTransferFunctionEnabled = 1 @@ -76,5 +74,4 @@ scalar_map.RadiusIsProportional = 1 scalar_map.RadiusProportionalFactor = mult pvsimple.Render() - - +time.sleep(sleep_delay) diff --git a/test/VisuPrs/imps/A3.py b/test/VisuPrs/imps/A3.py index 5ef2b63e..5e8a0d28 100644 --- a/test/VisuPrs/imps/A3.py +++ b/test/VisuPrs/imps/A3.py @@ -21,15 +21,13 @@ from paravistest import datadir, compare_lists from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis -error =0 +error = 0 # Import MED file file_path = datadir + "fra.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -49,8 +47,8 @@ if bar.Orientation != 'Vertical': print "Error!!! Default Scalar Bar Orientation is wrong - not vertical but ", scalarmap.Orientation error = error+1 -error = error + compare_lists(bar.Position, [0.87, 0.25]) -error = error + compare_lists(bar.Position2, [0.13, 0.5]) +error = error + compare_lists(bar.Position, [0.85, 0.05]) +error = error + compare_lists(bar.Position2, [0.12, 0.43]) if error > 0: raise RuntimeError, "There is(are) some error(s) was(were) found... For more info see ERRORs above..." diff --git a/test/VisuPrs/imps/A4.py b/test/VisuPrs/imps/A4.py index 7ecc10f2..45969bdb 100644 --- a/test/VisuPrs/imps/A4.py +++ b/test/VisuPrs/imps/A4.py @@ -21,15 +21,13 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis error = 0 # Import MED file med_file_path = datadir + "fra.med" -OpenDataFile(med_file_path) +pvsimple.OpenDataFile(med_file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -37,7 +35,7 @@ if med_reader is None: error = error+1 # Create Mesh -mesh_name = 'LE_VOLUME' +mesh_name = 'LE VOLUME' cell_entity = EntityType.CELL mesh = MeshOnEntity(med_reader, mesh_name, cell_entity) if mesh is None: diff --git a/test/VisuPrs/imps/A6.py b/test/VisuPrs/imps/A6.py index 1655a721..9aa6093c 100644 --- a/test/VisuPrs/imps/A6.py +++ b/test/VisuPrs/imps/A6.py @@ -21,15 +21,13 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis error =0 # Import MED file file_path = datadir + "Bug891_Box.resu.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -41,10 +39,9 @@ scalarmap = ScalarMapOnField(med_reader, EntityType.NODE, 'RESUMECAEQUI_ELGA_SIG if scalarmap is None: print "Error!!! ScalarMap is not created" error = error+1 - + scalarmap.Visibility = 1 reset_view() if error > 0: raise RuntimeError, "There is(are) some error(s) was(were) found... For more info see ERRORs above..." - diff --git a/test/VisuPrs/imps/A9.py b/test/VisuPrs/imps/A9.py index 778c7b3c..1b54e732 100644 --- a/test/VisuPrs/imps/A9.py +++ b/test/VisuPrs/imps/A9.py @@ -23,7 +23,6 @@ from time import sleep from paravistest import tablesdir from presentations import * -import pvserver as paravis import pvsimple # Import CSV table diff --git a/test/VisuPrs/imps/B1.py b/test/VisuPrs/imps/B1.py index 99016714..fe904a0f 100644 --- a/test/VisuPrs/imps/B1.py +++ b/test/VisuPrs/imps/B1.py @@ -21,14 +21,11 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # Import MED file file_path = datadir + "fra.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() entity = EntityType.NODE diff --git a/test/VisuPrs/imps/B2.py b/test/VisuPrs/imps/B2.py index 2f3cf7eb..b9540995 100644 --- a/test/VisuPrs/imps/B2.py +++ b/test/VisuPrs/imps/B2.py @@ -21,16 +21,13 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file print 'Import "ResOK_0000.med"...............', file_path = datadir + "ResOK_0000.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -38,23 +35,45 @@ if med_reader is None: else: print "OK" + +def _extract_all_arrays_of_type(array_type, source): + import re + #sep = source.GetProperty("Separator").GetData() # "@@][@@" + arrays = source.AllArrays + result = [] + for arr in arrays: + match = re.search("ComSup[^/]*/(.*)@@\]\[@@(.*)", arr) + field_name = match.group(1) + arr_typ = match.group(2) + if arr_typ == array_type: + result += [field_name] + pass + return result +# + +def _extract_cell_arrays(source): + return _extract_all_arrays_of_type("P0", source) +# +def _extract_point_arrays(source): + return _extract_all_arrays_of_type("P1", source) +# + # 2. Get some information on the MED file -fields_on_nodes = med_reader.PointArrays +#fields_on_nodes = med_reader.PointArrays +fields_on_nodes = _extract_point_arrays(med_reader) print "Field names on NODE: ", fields_on_nodes is_ok = len(fields_on_nodes) == 2 and ("temperature" in fields_on_nodes) and ("vitesse" in fields_on_nodes) if not is_ok: raise RuntimeError, "=> Error in PointArrays property" -fields_on_cells = med_reader.CellArrays +#fields_on_cells = med_reader.CellArrays +fields_on_cells = _extract_cell_arrays(med_reader) print "Field names on CELL: ", fields_on_cells is_ok = len(fields_on_cells) == 1 and ("pression" in fields_on_cells) if not is_ok: raise RuntimeError, "=> Error in CellArrays property" -timestamps = med_reader.TimestepValues.GetData() +timestamps = med_reader.TimestepValues.GetData()[1:] print "timestamps: ", timestamps if timestamps != [17.030882013694594]: raise RuntimeError, "=> Wrong TimestepValues property value" - - - diff --git a/test/VisuPrs/united/A1.py b/test/VisuPrs/united/A1.py index f7d11dd3..33da33f5 100644 --- a/test/VisuPrs/united/A1.py +++ b/test/VisuPrs/united/A1.py @@ -21,17 +21,14 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - # 1. Import MED file print "**** Step1: Import MED file" print 'Import "ResOK_0000.med"...', file_path = datadir + "ResOK_0000.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -108,7 +105,7 @@ print "**** Step3: Import another MED file" print 'Import "Fields_group3D.med"...............', file_path = datadir + "Fields_group3D.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader1 = pvsimple.GetActiveSource() if med_reader1 is None: diff --git a/test/VisuPrs/united/A2.py b/test/VisuPrs/united/A2.py index 6ffa0b1e..a903d8e8 100644 --- a/test/VisuPrs/united/A2.py +++ b/test/VisuPrs/united/A2.py @@ -21,12 +21,9 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple from math import radians -my_paravis = paravis.myParavis - cell_entity = EntityType.CELL node_entity = EntityType.NODE @@ -35,7 +32,7 @@ print "**** Step1: Import MED file" print 'Import "fra.med"....................', file_path = datadir + "fra.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -81,7 +78,7 @@ for i in xrange(1,50): normal = get_normal_by_orientation(orient, x_angle, radians(y_angle)) slice_filter.SliceType.Normal = normal pvsimple.Render() - + print "OK" print "View Point (FRONT)..................", @@ -90,7 +87,7 @@ view.CameraPosition = [2.4453961849843453, 0.03425, 0.541] pvsimple.Render() print "OK" -print "View Point (BACK)...................", +print "View Point (BACK)...................", view.CameraPosition = [-2.0343961849843457, 0.03425, 0.541] pvsimple.Render() print "OK" @@ -112,7 +109,7 @@ view.CameraPosition = [0.2055, -2.2056461849843454, 0.541] pvsimple.Render() print "OK" -print "View Point (RIGHT) .................", +print "View Point (RIGHT) .................", view.CameraPosition = [0.2055, 2.2741461849843456, 0.541] pvsimple.Render() print "OK" diff --git a/test/VisuPrs/united/A4.py b/test/VisuPrs/united/A4.py index 508ce38f..9eeb228b 100644 --- a/test/VisuPrs/united/A4.py +++ b/test/VisuPrs/united/A4.py @@ -21,11 +21,8 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - cell_entity = EntityType.CELL node_entity = EntityType.NODE @@ -34,7 +31,7 @@ print "**** Step1: Import MED file" print 'Import "Hexa8.med"....................', file_path = datadir + "Hexa8.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader1 = pvsimple.GetActiveSource() if med_reader1 is None: @@ -42,7 +39,7 @@ if med_reader1 is None: else: print "OK" -mesh_name1 = 'Maillage_MED_HEXA8' +mesh_name1 = 'Maillage MED_HEXA8' scalar_field = 'scalar field' vectoriel_field = 'vectoriel field' view = pvsimple.GetRenderView() @@ -55,7 +52,7 @@ else: display_only(scalarmap1, view) reset_view(view) print "OK" - + print "Creating Vectors......................", vectors1 = VectorsOnField(med_reader1, cell_entity, vectoriel_field, 1) if vectors1 is None: @@ -99,7 +96,7 @@ print "OK" print "Editing Vectors.......................", glyph = vectors1.Input -glyph.SetScaleFactor = 2 +glyph.ScaleFactor = 2 vectors1.LineWidth = 2 glyph.GlyphType.Center = [0.5, 0.0, 0.0] # TAIL position print "OK" @@ -116,7 +113,7 @@ hide_all(view) print 'Importing file "cube_hexa8_quad4.med".', file_path = datadir + "cube_hexa8_quad4.med" mesh_name2 = 'CUBE_EN_HEXA8_QUAD4' -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader2 = pvsimple.GetActiveSource() if med_reader2 is None: @@ -142,7 +139,7 @@ if vectors1 is None: print "FAILED" else: glyph2 = vectors2.Input - glyph2.SetScaleFactor = 0.2 + glyph2.ScaleFactor = 0.2 vectors2.LineWidth = 2 glyph2.GlyphType.Center = [0.5, 0.0, 0.0] # TAIL position print "OK" @@ -160,14 +157,14 @@ hide_all(view) print 'Importing file "Penta6.med"...........', file_path = datadir + "Penta6.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader3 = pvsimple.GetActiveSource() if med_reader3 is None: print "FAILED" else: print "OK" - + print "Creating Cut Planes...................", cutplanes1 = CutPlanesOnField(med_reader3, cell_entity, scalar_field, 1) if cutplanes1 is None: @@ -200,7 +197,7 @@ else: print "Displaying Vectors (l.w.=2, s.f.=1.5).", glyph3 = vectors3.Input -glyph3.SetScaleFactor = 1.5 +glyph3.ScaleFactor = 1.5 vectors3.LineWidth = 2 display_only(vectors3, view) print "OK" @@ -221,7 +218,7 @@ hide_all(view) print 'Importing "Quad4.med".................', file_path = datadir + "Quad4.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader4 = pvsimple.GetActiveSource() if med_reader4 is None: @@ -269,7 +266,7 @@ print "OK" print 'Importing "Tetra4.med"................', file_path = datadir + "Tetra4.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader5 = pvsimple.GetActiveSource() if med_reader5 is None: @@ -294,7 +291,7 @@ else: print "OK" vectors5.LineWidth = 3 -vectors5.Input.SetScaleFactor = 2 +vectors5.Input.ScaleFactor = 2 print "Displaying Scalar Map and Vectoes.....", hide_all(view) @@ -305,7 +302,7 @@ print "OK" print 'Importing "Tria3.med".................', file_path = datadir + "Tria3.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader6 = pvsimple.GetActiveSource() if med_reader6 is None: @@ -353,7 +350,7 @@ else: glyph = vectors6.Input glyph.GlyphType.Center = [0.5, 0.0, 0.0] # TAIL position vectors6.LineWidth = 2 - glyph.SetScaleFactor = 1 + glyph.ScaleFactor = 1 display_only(vectors6, view) print "OK" diff --git a/test/VisuPrs/united/A5.py b/test/VisuPrs/united/A5.py index c87d30ae..ad2426fe 100644 --- a/test/VisuPrs/united/A5.py +++ b/test/VisuPrs/united/A5.py @@ -21,11 +21,8 @@ from paravistest import datadir from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - cell_entity = EntityType.CELL node_entity = EntityType.NODE @@ -34,7 +31,7 @@ print "**** Step1: Import MED file" print 'Import "ResOK_0000.med"...............', file_path = datadir + "ResOK_0000.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: @@ -107,4 +104,3 @@ print "Mesh Node color in RGB....(", color[0], ",", color[1], ",", color[2], ")" pvsimple.Render() ## Note: no special property for edge color in PARAVIS; skip link color changing ( SetLinkColor()/GetLinkColor() methods ) - diff --git a/test/VisuPrs/united/B0.py b/test/VisuPrs/united/B0.py index fa7f816b..2380c3fe 100644 --- a/test/VisuPrs/united/B0.py +++ b/test/VisuPrs/united/B0.py @@ -21,16 +21,13 @@ from paravistest import datadir, compare_lists from presentations import * -import pvserver as paravis import pvsimple -my_paravis = paravis.myParavis - error=0 # 1. Import MED file file_path = datadir + "TimeStamps.med" -OpenDataFile(file_path) +pvsimple.OpenDataFile(file_path) med_reader = pvsimple.GetActiveSource() if med_reader is None: