Skip to content

Commit

Permalink
Merge branch 'ticket539' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
wd15 committed Mar 20, 2013
2 parents 8c51478 + 9ae4801 commit 0c8a5a6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion fipy/meshes/gmshMesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -856,7 +856,8 @@ def read(self):

# convert lists of cell vertices to a properly oriented masked array
maxVerts = max([len(v) for v in cellsToVertIDs])
cellsToVertIDs = [nx.concatenate((v, [-1] * (maxVerts-len(v)))) for v in cellsToVertIDs]
# ticket:539 - NumPy 1.7 casts to array before concatenation and empty array defaults to float
cellsToVertIDs = [nx.concatenate((v, nx.array([-1] * (maxVerts-len(v)), dtype=int))) for v in cellsToVertIDs]
cellsToVertIDs = nx.MA.masked_equal(cellsToVertIDs, value=-1).swapaxes(0,1)

parprint("Done with cells and faces.")
Expand Down

0 comments on commit 0c8a5a6

Please sign in to comment.