diff --git a/src/hdf5_ops.py b/src/hdf5_ops.py index 57aed5f..3dccd37 100644 --- a/src/hdf5_ops.py +++ b/src/hdf5_ops.py @@ -19,6 +19,16 @@ import json import copy class HDF5DataOpsManager(): + + """ + A class to handle HDF5 file operations. + + Parameters: + path_to_file : str + path/to/hdf5file. + mode : str + 'r' or 'r+' read or read/write mode only when file exists + """ def __init__(self, file_path, mode = 'r+') -> None: if mode in ['r','r+']: @@ -549,11 +559,5 @@ def get_groups_at_a_level(file: h5py.File, level: str): return groups -def annotate_root_dir(filename,annotation_dict: dict): - with h5py.File(filename,'r+') as file: - file.attrs.update(annotation_dict) - #for key in annotation_dict: - # file.attrs.create('metadata_'+key, annotation_dict[key]) -