SeisSol / PUMGen

Mesh generation for SeisSol
BSD 3-Clause "New" or "Revised" License
7 stars 3 forks source link

pumgen mesh64 fails converting small mesh #61

Closed Thomas-Ulrich closed 1 year ago

Thomas-Ulrich commented 1 year ago

pumgen master:

(base) ulrich@exception:/export/dump/ulrich/PUMGEN_folder/GAB$ pumgen -s msh2 ExtendedBottom_1703_small_no_LD_seissol.msh 
Tue Oct 10 14:33:48, Info:  Using GMSH mesh format 2 (msh2) mesh 
Tue Oct 10 14:33:48, Info:  Create APF connectivity 
Tue Oct 10 14:33:49, Info:  Set coordinates in APF 
Tue Oct 10 14:33:49, Info:  Mesh size: 140019 
Tue Oct 10 14:33:49, Info:  Minimum insphere found: 0.110456 
Tue Oct 10 14:33:49, Info:  Writing cells 
Tue Oct 10 14:33:49, Info:  Writing vertices 
Tue Oct 10 14:33:49, Info:  Writing group information 
Tue Oct 10 14:33:49, Info:  Writing boundary condition 
Tue Oct 10 14:33:49, Info:  Writing XDMF file 
Tue Oct 10 14:33:49, Info:  Finished successfully 

pumgen mesh64:

Tue Oct 10 14:34:26, Info:  No filtering enabled (contiguous storage) 
Tue Oct 10 14:34:26, Info:  Using GMSH mesh format 2 (msh2) mesh 
Tue Oct 10 14:34:27, Info:  Create APF connectivity 
Tue Oct 10 14:34:27, Info:  Set coordinates in APF 
[exception:1331639] *** Process received signal ***
[exception:1331639] Signal: Segmentation fault (11)
[exception:1331639] Signal code: Address not mapped (1)
[exception:1331639] Failing at address: 0x10
[exception:1331639] [ 0] /lib/x86_64-linux-gnu/libpthread.so.0(+0x13140)[0x14ddacdc6140]
[exception:1331639] [ 1] pumgen[0xe93246]
[exception:1331639] [ 2] pumgen[0xe936ea]
[exception:1331639] [ 3] pumgen[0xe938e9]
[exception:1331639] [ 4] pumgen[0xe426fc]
[exception:1331639] [ 5] pumgen[0xe42bd8]
[exception:1331639] [ 6] pumgen[0xb83b74]
[exception:1331639] [ 7] pumgen[0x41d81d]
[exception:1331639] [ 8] /lib/x86_64-linux-gnu/libc.so.6(__libc_start_main+0xea)[0x14ddab8e8d0a]
[exception:1331639] [ 9] pumgen[0x42105a]
[exception:1331639] *** End of error message ***
Segmentation fault

ExtendedBottom_1703_small_no_LD_seissol.msh

davschneller commented 1 year ago

Tested it locally; here it works with mesh64, strangely enough

Thomas-Ulrich commented 1 year ago

ok, nevermind, It was due to my debug statements

diff --git a/src/input/SimModSuite.h b/src/input/SimModSuite.h
index b28350a..0fc54aa 100644
--- a/src/input/SimModSuite.h
+++ b/src/input/SimModSuite.h
@@ -181,6 +181,7 @@ class SimModSuite : public MeshInput {

     logInfo(PMU_rank()) << "Converting mesh to APF";
     m_mesh = apf::createMdsMesh(model, tmpMesh);
+    logInfo(PMU_rank()) << "done createMdsMesh";
     apf::destroyMesh(tmpMesh);

     // Set the boundary conditions from the geometric model
@@ -204,6 +205,7 @@ class SimModSuite : public MeshInput {
       }
     }
     m_mesh->end(it);
+    logInfo(PMU_rank()) << "done set Boundary conditions";

     // Set groups
     apf::MeshTag* groupTag = m_mesh->createIntTag("group", 1);
@@ -219,6 +221,7 @@ class SimModSuite : public MeshInput {
       m_mesh->setIntTag(element, groupTag, &i->second);
     }
     m_mesh->end(it);
+    logInfo(PMU_rank()) << "done set groups";

     AttCase_unassociate(analysisCase);

diff --git a/src/pumgen.cpp b/src/pumgen.cpp
index da506b5..59209af 100644
--- a/src/pumgen.cpp
+++ b/src/pumgen.cpp
@@ -224,7 +224,9 @@ int main(int argc, char* argv[]) {
     logError() << "Unknown source";
   }

+  logInfo(PMU_rank()) << "before getMesh";
   mesh = meshInput->getMesh();
+  logInfo(PMU_rank()) << "after getMesh";

   // Check mesh
   if (alignMdsMatches(mesh))