From ac107579219b08914567f79c6a27bc1efb05b264 Mon Sep 17 00:00:00 2001 From: Christian Van Wambeke Date: Wed, 26 Feb 2020 10:51:29 +0100 Subject: [PATCH] comment examples/ghs3dprh_multithread_cube_one_face.py --- .../ghs3dprh_multithread_cube_one_face.py | 22 +++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) rename {example => examples}/ghs3dprh_multithread_cube_one_face.py (83%) diff --git a/example/ghs3dprh_multithread_cube_one_face.py b/examples/ghs3dprh_multithread_cube_one_face.py similarity index 83% rename from example/ghs3dprh_multithread_cube_one_face.py rename to examples/ghs3dprh_multithread_cube_one_face.py index 5899c3a..27f72f8 100644 --- a/example/ghs3dprh_multithread_cube_one_face.py +++ b/examples/ghs3dprh_multithread_cube_one_face.py @@ -1,5 +1,16 @@ #!/usr/bin/env python +""" +| usage: +| salome/File/Load_script ${GHS3DPRLPLUGIN_ROOT_DIR}/example +| +| result should be a tetrahedric meshed cube with one group of faces named Group_1 +| - with .SetMultithread(0) in 4 files med +| with mg-tetra_hpc.exe mpi results files are in /tmp/DOMAIN_*.med +| - with .SetMultithread(1) in 1 file med +| with mg-tetra_hpc.exe multithread result files are in /tmp/DOMAIN_1.med +""" + ### ### This file is generated automatically by SALOME v9.4.0 with dump python functionality ### @@ -8,9 +19,10 @@ import sys import salome salome.salome_init() -import salome_notebook -notebook = salome_notebook.NoteBook() -sys.path.insert(0, r'/volatile2/wambeke/SALOME-master-CO7-SRC') +# import salome_notebook +# notebook = salome_notebook.NoteBook() +# sys.path.insert(0, r'...') + ### ### GEOM component @@ -59,9 +71,11 @@ NETGEN_2D_Simple_Parameters_1.SetAllowQuadrangles( 0 ) MG_Tetra_HPC = Mesh_1.Tetrahedron(algo=smeshBuilder.MG_Tetra_Parallel) MG_Tetra_HPC_Parameters_1 = MG_Tetra_HPC.Parameters() MG_Tetra_HPC_Parameters_1.SetMEDName( 'DOMAIN' ) -MG_Tetra_HPC_Parameters_1.SetNbPart( 4 ) +MG_Tetra_HPC_Parameters_1.SetNbPart( 4 ) # MPI: 4 files, Multithread: 4 threads MG_Tetra_HPC_Parameters_1.SetKeepFiles( 1 ) MG_Tetra_HPC_Parameters_1.SetBackground( 0 ) +# Multithread: have to load only one file DOMAIN_1.med +# MPI: have to load 4 file DOMAIN_1.med -> DOMAIN_4.med MG_Tetra_HPC_Parameters_1.SetMultithread( 1 ) MG_Tetra_HPC_Parameters_1.SetGradation( 1.05 ) MG_Tetra_HPC_Parameters_1.SetMinSize( 0 ) -- 2.39.2