remove some Carpet build warnings, add run-time warnings about grid structure dataset

Issue #1428 closed
Roland Haas created an issue

the attached patch adds a level 2 warning when CarpetIOHDF5 cannot read the grid structure attribute (actually a dataset but treated as an attribute) in hdf5 files. This can happen if very old files (pre grid structure version 5) are being read or files that do not have the attribute at all. The attribute is used by the checkpoint recovery routine to reconstruct the process decomposition, but (as far as I know) ignored by the file reader for ID.

There is also one bugfix in 0002 that makes it possible to read multipatch data into a cartesian simulation as ID by using only the cartesian patch. While the patch is fairly simple please comment on whether it is fine to move the calculation of upper/lower into the loop over local maps, given that the upper/lower values are those of the patch to be read from file. The reason for the move is that the calculation needs the stride which is read from the current simulation and not from the patch (and can only be gotten if the map in question actually exists).

Keyword:

Comments (4)

  1. Erik Schnetter
    • changed status to open
    • removed comment

    0001: approved 0002: seems right-ish 0003: looks good, if this warnings handles only the filereader case. Obviously, reading a checkpoint file without grid structure needs to abort.

  2. Roland Haas reporter
    • changed status to resolved
    • removed comment

    Currently both checkpoint reader and ID file reader will silently continue past the point where I added the warning if no grid structure is found. Then, during recovery, CarpetIOHDF5 will then fail in CarpetIOHDF5_RecoverGridStructure where it checks if a grid structure could be read. Given this, I think I'd like to retract the patch (0003), since the ID file reader does not actually use the grid structure at all, so all that happens with the patch is that first one gets a level 2 warning and then an abort for recovery and a warning that is not necessary for the ID file reader. Note that the abort only happens if CarpetIOHDF5::use_grid_structure_from_checkpoint is set.

    I applied 0001 and 0002 as hash 66a468f4fc38188cd7a71261234a073f2a3e8c73 "CarpetIOHDF5: remove two compiler warnings" and 493f90970931ccdc8421bf5882bb14237508f70c "CarpetIOHDF5: check whether map exists before accessing it" of Carpet.

  3. Log in to comment