[petsc-dev] XDMF viewers

Brad Aagaard baagaard at usgs.gov
Sat Dec 3 15:51:55 CST 2011


For PyLith we create datasets with dimensions of the form
[ntimesteps, npoints, ncomponents] where ntimesteps has a maximum 
dimension of unlimited. This allows us to append data to the dataset at 
any number of timesteps. We store the timestamps in a separate dataset.
In processing the output, we can slice in either time or space with 
minimal effort.

In writing the XDMF files, we just read the HDF5 file and write the 
info. This makes it easy to regenerate the XDMF file any time we wish, 
including incomplete ones (i.e., we stop the simulation in the middle so 
that we don't have all of the timesteps) or ones where we rename the 
HDF5 file.

Brad


On 12/3/11 1:32 PM, Tim Gallagher wrote:
> XDMF has collections and a time tag, so you can assign a time step to
> each dataset and create a collection of those datasets. You can put the
> data either in the same HDF5 file or different HDF5 file each time step,
> with a single XML file that points in the right place for each time step.
>
> We (usually) do not have a changing grid, so we have a grid HDF5 file
> that is pointed to in each dataset with different data files for each.
> But instead of specifying different files, you can specify different
> groups inside an HDF5 file.
>
> Is that what you mean by storing time steps?
>
> Tim
>
> ------------------------------------------------------------------------
> *From: *"Matthew Knepley" <knepley at gmail.com>
> *To: *"For users of the development version of PETSc"
> <petsc-dev at mcs.anl.gov>
> *Sent: *Saturday, December 3, 2011 4:25:19 PM
> *Subject: *Re: [petsc-dev] XDMF viewers
>
> On Sat, Dec 3, 2011 at 3:24 PM, Jed Brown <jedbrown at mcs.anl.gov
> <mailto:jedbrown at mcs.anl.gov>> wrote:
>
>     On Sat, Dec 3, 2011 at 15:20, Matthew Knepley <knepley at gmail.com
>     <mailto:knepley at gmail.com>> wrote:
>
>         Does that matter? The same things are stored at each step.
>
>
>     Sure (if the mesh doesn't change, which is okay with me now), but
>     you have to put the data somewhere. I don't see how you would do
>     that with the current API, but it should be simple to accommodate.
>
>
> Brad did it, but I believe he uses HDF5 attributes
>
> Matt
>
> --
> What most experimenters take for granted before they begin their
> experiments is infinitely more interesting than any results to which
> their experiments lead.
> -- Norbert Wiener
>




More information about the petsc-dev mailing list