]> SALOME platform Git repositories - tools/solverlab.git/commitdiff
Salome HOME
Updated python script with new MEDCoupling int64 types
authormichael <michael@localhost.localdomain>
Fri, 5 Nov 2021 21:58:00 +0000 (22:58 +0100)
committermichael <michael@localhost.localdomain>
Fri, 5 Nov 2021 21:58:00 +0000 (22:58 +0100)
CDMATH/tests/ressources/scripts/weird_mesh.py

index b26afcb12530cbff852b144133b47df5046882b7..6a5c7704a225ef2335fd8d013314b91fb3d2614f 100644 (file)
@@ -36,7 +36,7 @@ def getWeirdMesh(xmin, xmax, ymin, ymax, lx, ly, str, func=None, extr=-1, unpo=F
         off += len(p)\r
     mesh.finishInsertingCells()\r
 \r
-    pts = [p for i in xange(len(polys)) for p in polys[i]]\r
+    pts = [p for i in range(len(polys)) for p in polys[i]]\r
     co = ml.DataArrayDouble(pts, len(pts), 2)\r
     mesh.setCoords(co)\r
 \r
@@ -76,7 +76,7 @@ def getWeirdMesh(xmin, xmax, ymin, ymax, lx, ly, str, func=None, extr=-1, unpo=F
             for idx, b in enumerate(bf):\r
                 if abs(b[i] - [[xmin, xmax], [ymin, ymax], [0., 1.]][i][j]) < 1e-5:\r
                     g.append(idx)\r
-            grp = ml.DataArrayIdType.New(g)\r
+            grp = ml.DataArrayInt64.New(g)\r
             grp.setName(noms_cl[i][j])\r
             mm.addGroup(-1, grp)\r
 \r