Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions ansys/mapdl/reader/mesh.py
Original file line number Diff line number Diff line change
Expand Up @@ -184,11 +184,13 @@ def _parse_vtk(self, allowable_types=None, force_linear=False,
grid = grid.extract_cells(grid.celltypes != 0)

if force_linear:
grid = grid.linear_copy()
# only run if the grid has points or cells
if grid.n_points:
grid = grid.linear_copy()

# map over element types
# Add tracker for original node numbering
ind = np.arange(grid.number_of_points)
ind = np.arange(grid.n_points)
grid.point_data['origid'] = ind
grid.point_data['VTKorigID'] = ind
return grid
Expand Down
3 changes: 2 additions & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,9 @@ def build_extensions(self):
e.extra_compile_args.append('-stdlib=libc++')

if platform.system() == 'Darwin':
# get the minor version
mac_version, _, _ = platform.mac_ver()
major, minor, patch = [int(n) for n in mac_version.split('.')]
minor = [int(n) for n in mac_version.split('.')][1]

# libstdc++ is deprecated in recent versions of XCode
if minor >= 9:
Expand Down