marmot.utils.dataio.write_metadata_to_h5#

write_metadata_to_h5(df: pandas.core.frame.DataFrame, file_name: pathlib.Path, key: str, partition: str = 'model_metadata', mode: str = 'a', **kwargs) None[source]#

Save metadata to formatted h5 file.

Parameters
  • df (pd.DataFrame) – Dataframe to save

  • file_name (Path) – name of hdf5 file

  • key (str) – metadata key, e.g objects/generators

  • partition (str, optional) – metadata partition. Defaults to “model_metadata”.

  • mode (str, optional) – file access mode.

  • "a". (Defaults to) –

  • **kwargs – These parameters will be passed pandas.to_hdf function.