inspect_file_structure¶
-
support.hdf5_util.
inspect_file_structure
(f_path_or_f_obj)¶ Get a dictionary that reports the structure of some HDF5 file.
Examples:
import numpy as np import h5py from support.hdf5_util import inspect_file_structure file_path = "example.hdf5" with h5py.File(file_path, "w") as f: g = f.create_group("group0") g.create_dataset("dataset0",data=np.zeros(10)) report, f_obj = inspect_file_structure(file_path) f_obj.close print(report)
This outputs the following dictionary:
{u'group0': {u'dataset0': (10,)}}