import os
from blocFissure import gmu
-dicoParams = dict(nomCas = 'cubeCoin',
- maillageSain = os.path.join(gmu.pathBloc, 'materielCasTests/cubeFin.med'),
- brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests/cubeFin_Coin.brep"),
+dicoParams = dict(nomCas = "cubeCoin",
+ maillageSain = os.path.join(gmu.pathBloc, "materielCasTests", "cubeFin.med"),
+ brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests", "cubeFin_Coin.brep"),
edgeFissIds = [6],
lgInfluence = 50,
meshBrep = (5,10),
import os
from blocFissure import gmu
-dicoParams = dict(nomCas = 'cubeMilieu',
- maillageSain = os.path.join(gmu.pathBloc, 'materielCasTests/cubeFin.med'),
- brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests/cubeFin_Milieu.brep"),
+dicoParams = dict(nomCas = "cubeMilieu",
+ maillageSain = os.path.join(gmu.pathBloc, "materielCasTests", "cubeFin.med"),
+ brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests", "cubeFin_Milieu.brep"),
edgeFissIds = [6],
lgInfluence = 50,
meshBrep = (5,10),
import os
from blocFissure import gmu
-dicoParams = dict(nomCas = 'cubeTransverse',
- maillageSain = os.path.join(gmu.pathBloc, 'materielCasTests/cubeFin.med'),
- brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests/cubeFin_Transverse.brep"),
+dicoParams = dict(nomCas = "cubeTransverse",
+ maillageSain = os.path.join(gmu.pathBloc, "materielCasTests", "cubeFin.med"),
+ brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests", "cubeFin_Transverse.brep"),
edgeFissIds = [6],
lgInfluence = 50,
meshBrep = (5,10),
"""
logging.info("genereMaillageSain %s", self.nomCas)
- ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/CylindreSain.med"))
+ ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "CylindreSain.med"))
smesh.SetName(objetSain.GetMesh(), 'objetSain')
return [objetSain, True] # True : maillage hexa
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/FissInCylindre2.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "FissInCylindre2.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [6])
geompy.addToStudy( shellFiss, 'shellFiss' )
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/FissInCylindre.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "FissInCylindre.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [3])
geompy.addToStudy( shellFiss, 'shellFiss' )
from blocFissure import gmu
dicoParams = dict(nomCas = 'disque',
- maillageSain = os.path.join(gmu.pathBloc, 'materielCasTests/disque.med'),
- brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests/ellipse_disque.brep"),
+ maillageSain = os.path.join(gmu.pathBloc, "materielCasTests", "disque.med"),
+ brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests", "ellipse_disque.brep"),
edgeFissIds = [3],
lgInfluence = 10,
meshBrep = (0.5,2.5),
def genereMaillageSain(self, geometriesSaines, meshParams):
logging.info("genereMaillageSain %s", self.nomCas)
- ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/boiteSaine.med"))
+ ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "boiteSaine.med"))
smesh.SetName(objetSain.GetMesh(), 'objetSain')
return [objetSain, True] # True : maillage hexa
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/ellipse1.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "ellipse1.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [3])
geompy.addToStudy( shellFiss, 'shellFiss' )
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/ellipse1_pb.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "ellipse1_pb.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [3])
geompy.addToStudy( shellFiss, 'shellFiss' )
def genereMaillageSain(self, geometriesSaines, meshParams):
logging.info("genereMaillageSain %s", self.nomCas)
- ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/EprouvetteCourbe.med"))
+ ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "EprouvetteCourbe.med"))
smesh.SetName(objetSain.GetMesh(), 'objetSain')
return [objetSain, True] # True : maillage hexa
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/EprouvetteCourbeFiss.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "EprouvetteCourbeFiss.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [8])
geompy.addToStudy( shellFiss, 'shellFiss' )
def genereMaillageSain(self, geometriesSaines, meshParams):
logging.info("genereMaillageSain %s", self.nomCas)
- ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/eprouvetteDroite.med"))
+ ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "eprouvetteDroite.med"))
smesh.SetName(objetSain.GetMesh(), 'objetSain')
return [objetSain, True] # True : maillage hexa
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/EprouvetteDroiteFiss_1.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "EprouvetteDroiteFiss_1.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [8])
geompy.addToStudy( shellFiss, 'shellFiss' )
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/EprouvetteDroiteFiss_2.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "EprouvetteDroiteFiss_2.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [10])
geompy.addToStudy( shellFiss, 'shellFiss' )
def genereMaillageSain(self, geometriesSaines, meshParams):
logging.info("genereMaillageSain %s", self.nomCas)
- ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/faceGaucheSain.med"))
+ ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "faceGaucheSain.med"))
smesh.SetName(objetSain.GetMesh(), 'objetSain')
return [objetSain, True] # True : maillage hexa
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/faceGaucheFiss.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "faceGaucheFiss.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [6])
geompy.addToStudy( shellFiss, 'shellFiss' )
def genereMaillageSain(self, geometriesSaines, meshParams):
logging.info("genereMaillageSain %s", self.nomCas)
- ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests/boiteSaine.med"))
+ ([objetSain], status) = smesh.CreateMeshesFromMED(os.path.join(gmu.pathBloc, "materielCasTests", "boiteSaine.med"))
smesh.SetName(objetSain.GetMesh(), 'objetSain')
return [objetSain, True] # True : maillage hexa
lgInfluence = shapeFissureParams['lgInfluence']
- shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests/faceGauche2FissCoupe.brep"))
+ shellFiss = geompy.ImportBREP(os.path.join(gmu.pathBloc, "materielCasTests", "faceGauche2FissCoupe.brep"))
fondFiss = geompy.CreateGroup(shellFiss, geompy.ShapeType["EDGE"])
geompy.UnionIDs(fondFiss, [14, 9])
geompy.addToStudy( shellFiss, 'shellFiss' )
from blocFissure.gmu.casStandard import casStandard
-dicoParams = dict(nomCas = 'angleCube',
- maillageSain = os.path.join(gmu.pathBloc, 'materielCasTests/CubeAngle.med'),
- brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests/CubeAngleFiss.brep"),
+dicoParams = dict(nomCas = "angleCube",
+ maillageSain = os.path.join(gmu.pathBloc, "materielCasTests", "CubeAngle.med"),
+ brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests", "CubeAngleFiss.brep"),
edgeFissIds = [4],
lgInfluence = 20,
meshBrep = (5,10),
def initDefaut(self):
self.defaut = dict( \
- nomCas = 'angleCube', \
- maillageSain = os.path.join(gmu.pathBloc, 'materielCasTests/CubeAngle.med'), \
- brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests/CubeAngleFiss.brep"), \
+ nomCas = "angleCube", \
+ maillageSain = os.path.join(gmu.pathBloc, "materielCasTests", "CubeAngle.med"), \
+ brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests", "CubeAngleFiss.brep"), \
edgeFissIds = [3], \
lgInfluence = 20, \
meshBrep = (5,10), \
nbSegCercle = 32, \
areteFaceFissure = 10, \
areteVives = 0, \
- reptrav = '.', \
- nomres = 'maillage_avec_fissure', \
+ reptrav = os.curdir, \
+ nomres = "maillage_avec_fissure", \
verbosite = 0)
return incomplet
def fileDefault(self):
- filedef = os.path.expanduser("~/.config/salome/dialogFissureGenerale.dic")
+ filedef = os.path.expanduser( os.path.join(os.environ["HOME"],".config", "salome", "dialogFissureGenerale.dic") )
print(filedef)
return filedef
f.write(str(dico))
def genereExemples(self):
- maillageSain = os.path.join(gmu.pathBloc, 'materielCasTests/CubeAngle.med')
- brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests/CubeAngleFiss.brep")
+ maillageSain = os.path.join(gmu.pathBloc, "materielCasTests", "CubeAngle.med")
+ brepFaceFissure = os.path.join(gmu.pathBloc, "materielCasTests", "CubeAngleFiss.brep")
if (os.path.exists(maillageSain) and os.path.exists(brepFaceFissure)):
self.initDialog(self.defaut)
else: