README.md
1C++ wrapper on top of HDF5 library C interfaces
2
3Users only need `hdf_archive` class to open/close and read/write files.
4
5`hdf_wrapper_functions.h` wraps raw C functions of HDF5.
6
7`hdf_datatype.h` handles the mapping between C type and HDF5 native type.
8
9`hdf_dataspace.h` handles HDF5 multidimentional dataspace.
10
11`hdf_dataproxy` is a tempalte class to support any kind of datatype written to HDF5 file as a single dataset.
12Its specialization are
13STL containers, including vector, bitset and string, in `hdf_stl.h`;
14OhmmsPETE containers, including Vector, Matrix and Array, in `hdf_pete.h`;
15Afredo's multi container for multidimentional arrays, in `hdf_multi.h`.
16Users are recommended to include the corresponding header if a non-STL data container is used.
17
18`hdf_hyperslab.h` supports hyperslab selection in filespace. In production.
19
20`hdf_double_hyperslab.h` supports hyperslab selection in both filespace and memory space. Not completed yet due to limited demand.
21
22`hdf_hyperslab` reads from and writes into data containers which requires `../type_traits/container_traits.h`
23to support features like resizing containers.
24`container_traits` has specializations for STL vector in `container_traits.h`,
25 OhmmsPETE containers in `container_traits_ohmms.h`
26 and Afredo's multidimentional arrays `container_traits_multi.h`
27When using `hdf_hyperslab`, users are required to include the corresponding header if a non-STL data container is used.
28
29Although users need to include a few headers to operate a feature with full functionality, it reduces header file entanglement and saves compliation time.
30
31A bit more about multidimensional data. Take a datatype in memory `Matrix<TinyVector<std::complex<double>, 3>>` as an example.
32The dataset on the file has a rank of 2 (Matrix) + 1 (TinyVector) + 1 (std::complex) + 0 (double) = 4
33The Matrix container holds `TinyVector<std::complex<double>, 3>` value type.
34`getShape<TinyVector<std::complex<double>, 3>>` gives the dimensions of a matrix.
35