Proto
|
Public Member Functions | |
HDF5Handler () | |
Default Constructor. | |
template<typename T , unsigned int C, MemType MEM, unsigned int CTR, typename... Args> | |
void | readLevel (LevelBoxData< T, C, MEM, CTR > &a_data, std::string a_filename, Args... a_params) |
Read Level Box Data. More... | |
template<typename T , unsigned int C, MemType MEM, unsigned int CTR, typename... Args> | |
void | writeLevel (std::vector< std::string > a_varnames, array< double, DIM > a_dx, const LevelBoxData< T, C, MEM, CTR > &a_data, std::string a_filename, Args... a_params) |
Write Level Box Data. More... | |
template<typename T , unsigned int C, MemType MEM, unsigned int CTR, typename... Args> | |
void | writeLevel (std::vector< std::string > a_varnames, double a_dx, const LevelBoxData< T, C, MEM, CTR > &a_data, std::string a_filename, Args... a_params) |
Write Level Box Data (scalar DX) More... | |
template<typename T , unsigned int C, MemType MEM, unsigned int CTR, typename... Args> | |
void | writeLevel (array< double, DIM > a_dx, const LevelBoxData< T, C, MEM, CTR > &a_data, std::string a_filename, Args... a_params) |
Write Level Box Data (No Varnames) More... | |
template<typename T , unsigned int C, MemType MEM, unsigned int CTR, typename... Args> | |
void | writeLevel (double a_dx, const LevelBoxData< T, C, MEM, CTR > &a_data, std::string a_filename, Args... a_params) |
Write Level Box Data (No Varnames, scalar DX) More... | |
template<typename T , unsigned int C, MemType MEM, unsigned int CTR, typename... Args> | |
void | writeLevel (std::vector< std::string > a_varnames, const LevelBoxData< T, C, MEM, CTR > &a_data, std::string a_filename, Args... a_params) |
Write Level Box Data (No DX) More... | |
template<typename T , unsigned int C, MemType MEM, unsigned int CTR, typename... Args> | |
void | writeLevel (const LevelBoxData< T, C, MEM, CTR > &a_data, std::string a_filename, Args... a_params) |
Write Level Box Data (No DX, Varnames) More... | |
template<typename T , unsigned int C, MemType MEM, typename... Args> | |
void | writePatch (std::vector< std::string > a_varnames, array< double, DIM > a_dx, const BoxData< T, C, MEM > &a_data, std::string a_filename, Args... a_params) |
Write Box Data. More... | |
template<typename T , unsigned int C, MemType MEM, typename... Args> | |
void | writePatch (std::vector< std::string > a_varnames, const BoxData< T, C, MEM > &a_data, std::string a_filename, Args... a_params) |
Write Box Data (No DX) More... | |
template<typename T , unsigned int C, MemType MEM, typename... Args> | |
void | writePatch (const BoxData< T, C, MEM > &a_data, std::string a_filename, Args... a_params) |
Write Box Data (No DX, Varnames) More... | |
|
inline |
Read Level Box Data.
Read a LevelBoxData from an appropriately constructed HDF5 file. This function should be compatible with files created using Chombo's HDF5 I/O system.
The input LevelBoxData is REDEFINED when calling this function, and a new DisjointBoxLayout is built. Because of this, knowledge of the way in which the input data was constructed is not needed.
The filename and following variadic arguments are used in the same way as printf-style functions. For example:
readLevel(data, "filename_%i.hdf5", 42) -> read from "filename_42.hdf5"
Compatible with MPI if PR_MPI=TRUE.
|
inline |
Write Level Box Data.
Write's a LevelBoxData to an HDF5 file which is compatible with Chombo's HDF5 I/O as well as VisIt.
The filename and following variadic arguments are used in the same way as printf-style functions. For example:
writeLevel(data, {"rho", "vx", "vy"}, dx, "Euler_T%i.hdf5", 0) -> writes to "Euler_T0.hdf5"
Compatible with MPI if PR_MPI=TRUE.
|
inline |
Write Level Box Data (scalar DX)
A convenient overload. Grid spacing is isotropic.
|
inline |
Write Level Box Data (No Varnames)
A convenient overload.
|
inline |
Write Level Box Data (No Varnames, scalar DX)
A convenient overload. Grid spacing is isotropic.
|
inline |
Write Level Box Data (No DX)
A convenient overload. Grid spacing defaults to 1.
|
inline |
Write Level Box Data (No DX, Varnames)
A convenient overload. Grid spacing defaults to 1 and variable names are generated automatically.
|
inline |
Write Box Data.
Writes a single BoxData to an HDF5 file compatible with Chombo's HDF5 I/O and VisIt.
The filename and following variadic arguments are used in the same way as printf-style functions. For example:
writePatch(data, {"rho", "vx", "vy"}, dx, "Euler_T%i.hdf5", 0) -> writes to "Euler_T0.hdf5"
Written patches are shifted such that their domain is at (0,...,0) by necessity and, if they were originally part of a LevelBoxData, have no notion of ghost cells or their previous location in the Box layout.
Ghost cells ARE printed, but appear with the rest of the data (they are not hidden by default in VisIt).
This function should only be used for simple debugging needs wherein it is inconvenient to print an entire LevelBoxData.
TODO: Does not currently work with MPI.
|
inline |
Write Box Data (No DX)
A convenient overload. Grid spacing defaults to 1.
|
inline |
Write Box Data (No DX, Varnames)
A convenient overload. Grid spacing defaults to 1 and variable names are generated automatically.