Page tree

The license could not be verified: License Certificate has expired!

Versions Compared


  • This line was added.
  • This line was removed.
  • Formatting was changed.


  • C routines begin with the prefix “H5*” where * is a single letter indicating the object on which the operation is to be performed:
    File Interface:              H5Fopen
    Dataset Interface:       H5Dopen

  • FORTRAN routines are similar; they begin with “h5*” and end with “_f”:
    File Interface:              h5fopen_f
    Dataset Interface:       H5Dopen (C) and h5fdopenh5dopen_f (FORTRAN)

  • APIS for languages like C++, Java, and Python use methods associated with specific objects.


For portability, the HDF5 library has its own defined types.  Some common types that you will see in the example code are:

 hid hid_t is used for object handles

 hsize hsize_t is used for dimensions

 herr herr_tis used for many return values

Language specific files must be included in applications

Python:            Add “import h5py” / “import numpy”

C:                     Add “#include #include hdf5.h”h

FORTRAN:       Add “USE HDF5” USE HDF5 and  call h5open_f and h5close_f to initialize and close the HDF5 FORTRAN  interface

Python:            Add import h5py / import numpy