Page tree

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

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

Keep the following in mind when looking at the example programs included in this section:

APIs vary with different languages

  • 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 h5fdopen_f (FORTRAN)

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

HDF5 Library has its own defined types

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

 hid_t is used for object handles

 hsize_t is used for dimensions

 herr_t is used for many return values

Language specific files must be included in applications

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

C:                     Add “#include hdf5.h”

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

--- Last Modified: January 25, 2018 | 10:58 AM