Salome HOME
Small fix
[modules/smesh.git] / src / Tools / Verima / Scripts / bb.py
1 # Get Information About Mesh by GetMeshIn
2 import salome
3 salome.salome_init()
4
5 import SMESH, SALOMEDS
6 from salome.smesh import smeshBuilder
7 smesh = smeshBuilder.New(salome.myStudy)
8
9 aMesh,aResult = smesh.CreateMeshesFromMED('/tmp/MASSIF.new.med')
10 print aResult, aMesh
11
12 monMesh=aMesh[0]
13
14 # Get Information About Group by GetMeshInfo
15 print "\nInformation about group by GetMeshInfo:"
16 lGroups=monMesh.GetGroups()
17 print lGroups
18 for g in lGroups :
19     print g.GetName()
20 info = smesh.GetMeshInfo(lGroups[0])
21 keys = info.keys(); keys.sort()
22 for i in keys:
23   print "  %s  :  %d" % ( i, info[i] )
24   pass
25 #