]> SALOME platform Git repositories - tools/medcoupling.git/commitdiff
Salome HOME
Shame on me
authorAnthony Geay <anthony.geay@edf.fr>
Wed, 24 Mar 2021 16:48:02 +0000 (17:48 +0100)
committerAnthony Geay <anthony.geay@edf.fr>
Wed, 24 Mar 2021 16:48:02 +0000 (17:48 +0100)
src/MEDCoupling_Swig/geom2medcoupling.py

index c9259627799a27e8dbf619d7a8e3efc245a5a927..374b418c195e5bb1faad73c5e0d5bd7a916c7ce1 100644 (file)
@@ -79,7 +79,7 @@ def compute_interpolation_P0P0_matrix_with_geom(srcMesh,trgMesh):
 
     :return: a matrix with the same format than mc.MEDCouplingRemapper.getCrudeMatrix (use mc.MEDCouplingRemapper.ToCSRMatrix to convert it into scipy sparse format)
     """
-    mat_geom = trgMesh.getNumberOfCells()*[{}]
+    mat_geom = [ {} for i in range(trgMesh.getNumberOfCells()) ]
     for j in range(trgMesh.getNumberOfCells()):
         for i in range(srcMesh.getNumberOfCells()):
             mc_src_mesh = srcMesh[i]