<div dir="ltr"><div>I'm trying to improve the checkpointing functionality in the Firedrake library, which currently uses the HDF5 viewer to store PetscVec objects. The problem with this approach is that a lot of context about the stored vector (e.g. the mesh and finite element space that it came from) is lost and we'd like to save that too.</div><div><br></div><div style="text-align:left">In order to make a sensible hierarchy inside the file, I'd like to be able to write a DMPlex to a group, say `/meshes/<mesh_name>`, within the file rather than at the root `/`. I tried using the `PETScViewerHDF5PushGroup` function; I thought that this will change the current group of the file to whatever name you give and all subsequent dataset writes will go under that group until you call the matching pop. This doesn't seem to be the case and all of the mesh data gets written under `/`. From reading the source code, it looks like the HDF5 writer pushes the group `/topology` to write out the DMPlex cells (and likewise for coordinates etc) which then clobbers whatever I pushed before it instead of concatenating.<br></div><div style="text-align:left"><br></div><div style="text-align:left">I've attached a minimal example using petsc4py to demonstrate. I get the same results when I use some extra functionality in Firedrake to ensure that the `/meshes` group is created in the first place, which I can then verify with h5ls.<br></div><div style="text-align:left"><br></div><div style="text-align:left">Is there a way to do what I want and if so how? If there isn't, is that because no one has needed this before or is there a fundamental reason why you shouldn't be doing this in the first place?</div><div style="text-align:left"><br></div><div style="text-align:left">Thanks!</div><div style="text-align:left">Daniel<br></div></div>