utils.load_dict_from_hdf5_attrs#

Back to Module page

Summary#

Loads a dictionary from the attributes of a hdf5 file

Signature#

def load_dict_from_hdf5_attrs(fobj, keys = None, outdict = None)
Input variables#

Name

Type

Default

Description

fobj

hdf5 file or group object

keys

None

List of keys to load. If None, load all keys

outdict

None

Dictionary to load into, if None, create a new one

Output variables#

Return annotation

Docstring type

Description

None

Dictionary with the keys and values if outdict is None, else modifies what was passed

Docstring#

Loads a dictionary from the attributes of a hdf5 file
:param fobj: hdf5 file or group object
:param keys: List of keys to load. If None, load all keys
:param outdict: Dictionary to load into, if None, create a new one
:return:
    Dictionary with the keys and values if outdict is None, else modifies
    what was passed