Add index file support for sliced output to CarpetIOHDF5

Issue #1081 closed
Ian Hinder created an issue

CarpetIOHDF5 has support for writing an "index" file alongside the normal HDF5 output files. This is an HDF5 file in which the datasets are present but contain no data. This index file is much faster to read than the full HDF5 file (due to locality of data in the index file and block reads on slow filesystems) and can significantly speed up analysis of the data.

Index files are currently written for the "standard" (typically 3D) data in Output.cc, but are not written for the "sliced" data in OutputSlice.cc. Since visualisation of 2D data is very common, OutputSlice.cc should be modified to output index files as well.

Keyword:

Comments (7)

  1. Erik Schnetter
    • removed comment

    I did not check the logic itself; I assume that it has been copied from Output.cc, and is self-consistent.

    Why is there a new WriteAttribute routine? Shouldn't this attribute be an integer, since this is what Cactus uses internally anyway? This routine currently creates an attribute of type H5T_NATIVE_DOUBLE -- is this intended? I would understand a new routine for long long (if supported), in case 64 bits are needed.

  2. Roland Haas
    • removed comment

    The type should be H5T_NATIVE_HSIZE since the corresponding code in the old-style HDF5 output routine (in Output.cc/AddAttributes line 845) creates tis type as well. What is written is the hdf5 shape parameter not Cactus' lsh array. Creating a double attribute is certainly wrong. I updated the patch.

  3. Log in to comment