def save_configuration_dict(h5_file, configuation_name, configuration, **kwargs):
def save_conf():<EOL><INDENT>try:<EOL><INDENT>h5_file.remove_node(h5_file.root.configuration, name=configuation_name)<EOL><DEDENT>except tb.NodeError:<EOL><INDENT>pass<EOL><DEDENT>try:<EOL><INDENT>configuration_group = h5_file.create_group(h5_file.root, "<STR_LIT>")<EOL><DEDENT>except tb.NodeError:<EOL><INDENT>configuration_group = h5_file.root.configuration<EOL><DEDENT>scan_param_table = h5_file.create_table(configuration_group, name=configuation_name, description=NameValue, title=configuation_name)<EOL>row_scan_param = scan_param_table.row<EOL>for key, value in dict.iteritems(configuration):<EOL><INDENT>row_scan_param['<STR_LIT:name>'] = key<EOL>row_scan_param['<STR_LIT:value>'] = str(value)<EOL>row_scan_param.append()<EOL><DEDENT>scan_param_table.flush()<EOL><DEDENT>if isinstance(h5_file, tb.file.File):<EOL><INDENT>save_conf()<EOL><DEDENT>else:<EOL><INDENT>if os.path.splitext(h5_file)[<NUM_LIT:1>].strip().lower() != "<STR_LIT>":<EOL><INDENT>h5_file = os.path.splitext(h5_file)[<NUM_LIT:0>] + "<STR_LIT>"<EOL><DEDENT>with tb.open_file(h5_file, mode="<STR_LIT:a>", title='<STR_LIT>', **kwargs) as h5_file:<EOL><INDENT>save_conf()<EOL><DEDENT><DEDENT>
Stores any configuration dictionary to HDF5 file.

    Parameters
    ----------
    h5_file : string, file
        Filename of the HDF5 configuration file or file object.
    configuation_name : str
        Configuration name. Will be used for table name.
    configuration : dict
        Configuration dictionary.