Skip to content

Commit 7eeae91

Browse files
authored
fix: dtype in newPointsArray initialization (#224)
Updated newPointsArray initialization to preserve dtype. ---------
1 parent 91f6699 commit 7eeae91

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

mesh-doctor/src/geos/mesh_doctor/actions/generateFractures.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,7 @@ def __copyFieldsSplitMesh( oldMesh: vtkUnstructuredGrid, splitMesh: vtkUnstructu
326326
# Reshape oldPointsArray if it is 1-dimensional
327327
if len( oldPointsArray.shape ) == 1:
328328
oldPointsArray = oldPointsArray.reshape( ( oldNrows, 1 ) )
329-
newPointsArray = empty( ( newNumberPoints, oldNcols ) )
329+
newPointsArray = empty( ( newNumberPoints, oldNcols ), dtype=oldPointsArray.dtype )
330330
newPointsArray[ :oldNrows, : ] = oldPointsArray
331331
for newAndOldId in addedPointsWithOldId:
332332
newPointsArray[ newAndOldId[ 0 ], : ] = oldPointsArray[ newAndOldId[ 1 ], : ]

0 commit comments

Comments
 (0)