mkpy.h5tools module

meta private

mkpy.h5tools.get_data_group_paths(h5f)[source]

Return paths to all data groups that contain a dblock_0.

The paths are sorted lexicographically.

Parameters

h5f (str) – HDF5 file name

Returns

group_paths – List of paths to data groups

Return type

list of str

mkpy.h5tools.get_dblock_paths(h5f, h5_path)[source]

Get dblock_N paths, in acquisition order, for the group at h5_path.

Parameters
  • h5f (str) – HDF5 file name

  • h5_path (str) – Path to group under h5f containing dblocks

Returns

dblock_paths – List of paths to dblocks

Return type

list of str

Examples

>>> from mkpy import h5tools
>>> h5tools.get_dblock_paths('calstest.h5', 'calstest')
['calstest/dblock_0',
 'calstest/dblock_1',
 'calstest/dblock_2',
 'calstest/dblock_3',
 'calstest/dblock_4']