Skip to content

Loading gmsh file fails #664

@hbuesing

Description

@hbuesing

I tried to load a simple rectangular gmsh file with a hole in the middle (test1.msh):

mymesh = Mesh("test1.msh")
elt = FiniteElement("CG","triangle", 1)
CG1 = FunctionSpace(mymesh, elt)

When constructing the finite element space I get the error below. I attached the meshfile (test1.msh) and an example that reproduces the error (test.py).

Henrik

Traceback (most recent call last):
File "test.py", line 11, in
CG1 = FunctionSpace(mymesh, elt)
File "/home/hb111949/.local/lib/python2.7/site-packages/PyOP2-0.11.0_425_g64db689-py2.7-linux-x86_64.egg/pyop2/caching.py", line 161, in new
obj = make_obj()
File "/home/hb111949/.local/lib/python2.7/site-packages/PyOP2-0.11.0_425_g64db689-py2.7-linux-x86_64.egg/pyop2/caching.py", line 142, in make_obj
obj.init(_args, *_kwargs)
File "/home/hb111949/Code/firedrake/firedrake/functionspace.py", line 578, in init
mesh.init()
File "/home/hb111949/Code/firedrake/firedrake/mesh.py", line 480, in init
self._callback(self)
File "/home/hb111949/Code/firedrake/firedrake/mesh.py", line 404, in callback
old_to_new = self._plex.getOrdering(PETSc.Mat.OrderingType.RCM).indices
File "PETSc/DMPlex.pyx", line 601, in petsc4py.PETSc.DMPlex.getOrdering (src/petsc4py.PETSc.c:224945)
petsc4py.PETSc.Error: error code 77
[0] DMPlexGetOrdering() line 136 in /rwthfs/rz/cluster/home/hb111949/Code/petsc/src/dm/impls/plex/plexreorder.c
[0] DMPlexCreateOrderingClosure_Static() line 43 in /rwthfs/rz/cluster/home/hb111949/Code/petsc/src/dm/impls/plex/plexreorder.c
[0] Petsc has generated inconsistent data
[0] Number of depth 1 faces 40 does not match permuted nubmer 38

from firedrake import *
import time

parameters["pyop2_options"]["log_level"] = "WARNING"

# Load mesh
mymesh = Mesh("test1.msh")

# Construction of FV mesh
elt = FiniteElement("CG","triangle", 1)
CG1 = FunctionSpace(mymesh, elt)

test1.msh.txt

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions