Step 1: Error 4#

Error Message#

Listing 272 Error message 4 when running Step 1.#
 1$ pylith step01a_gravity.cfg
 2
 3 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/apps/PyLithApp.py:77:main
 4 -- pylithapp(info)
 5 -- Running on 1 process(es).
 6 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/meshio/MeshIOObj.py:38:read
 7 -- meshiopetsc(info)
 8 -- Reading finite-element mesh
 9 >> /src/cig/pylith/libsrc/pylith/meshio/MeshIO.cc:85:void pylith::meshio::MeshIO::read(pylith::topology::Mesh *, const bool)
10 -- meshiopetsc(info)
11 -- Component 'reader': Domain bounding box:
12    (-100000, 100000)
13    (-100000, 0)
14 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/problems/Problem.py:116:preinitialize
15 -- timedependent(info)
16 -- Performing minimal initialization before verifying configuration.
17 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/problems/Solution.py:39:preinitialize
18 -- solution(info)
19 -- Performing minimal initialization of solution.
20 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/materials/RheologyElasticity.py:35:preinitialize
21 -- isotropiclinearelasticity(info)
22 -- Performing minimal initialization of elasticity rheology 'bulk_rheology'.
23 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/materials/RheologyElasticity.py:35:preinitialize
24 -- isotropiclinearelasticity(info)
25 -- Performing minimal initialization of elasticity rheology 'bulk_rheology'.
26 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/materials/RheologyElasticity.py:35:preinitialize
27 -- isotropiclinearelasticity(info)
28 -- Performing minimal initialization of elasticity rheology 'bulk_rheology'.
29 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/bc/DirichletTimeDependent.py:86:preinitialize
30 -- dirichlettimedependent(info)
31 -- Performing minimal initialization of time-dependent Dirichlet boundary condition 'bc_xneg'.
32 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/bc/DirichletTimeDependent.py:86:preinitialize
33 -- dirichlettimedependent(info)
34 -- Performing minimal initialization of time-dependent Dirichlet boundary condition 'bc_xpos'.
35 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/bc/DirichletTimeDependent.py:86:preinitialize
36 -- dirichlettimedependent(info)
37 -- Performing minimal initialization of time-dependent Dirichlet boundary condition 'bc_yneg'.
38 >> /software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/problems/Problem.py:174:verifyConfiguration
39 -- timedependent(info)
40 -- Verifying compatibility of problem configuration.
41Fatal error. Calling MPI_Abort() to abort PyLith application.
42Traceback (most recent call last):
43  File "/software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/apps/PetscApplication.py", line 55, in onComputeNodes
44    self.main(*args, **kwds)
45  File "/software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/apps/PyLithApp.py", line 101, in main
46    self.problem.verifyConfiguration()
47  File "/software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/problems/Problem.py", line 176, in verifyConfiguration
48    ModuleProblem.verifyConfiguration(self)
49  File "/software/unix/py3.12-venv/pylith-debug/lib/python3.12/site-packages/pylith/problems/problems.py", line 162, in verifyConfiguration
50    return _problems.Problem_verifyConfiguration(self)
51           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
52RuntimeError: Material label_value '3' for cell '609' does not match the label_value of any materials or interfaces.
53Abort(-1) on node 0 (rank 0 in comm 0): application called MPI_Abort(MPI_COMM_WORLD, -1) - process 0
54/software/unix/py3.12-venv/pylith-debug/bin/nemesis: mpiexec: exit 255
55/software/unix/py3.12-venv/pylith-debug/bin/pylith: /software/unix/py3.12-venv/pylith-debug/bin/nemesis: exit 1

Troubleshooting Strategy#

The output shows a Python Traceback and then the error message on Line 52. The error indicates the finite-element mesh file contains a cell with a label value of 3, but the parameter files do not have a material with a label value of 3. We examine the pylithapp.problem.materials sections of pylithapp.cfg and see that the label values are 0, 1, and 2 in the parameter file rather than 1, 2, and 3 that we set in the Gmsh Python script.

Resolution#

Listing 273 Correct error in pylithapp.cfg.#
[pylithapp.problem.materials.slab]
label_value = 1
...

[pylithapp.problem.materials.crust]
label_value = 2
...

[pylithapp.problem.materials.wedge]
label_value = 3
...