rizer.misc.simulation#

Functions#

parse_simulation_yaml(→ dict[str, Any])

Parse a simulation YAML file and perform minimal validation.

create_case_folder(→ pathlib.Path)

Create a folder for the case.

Module Contents#

rizer.misc.simulation.parse_simulation_yaml(path: str | pathlib.Path, expected_sections: list[str] | None = None) dict[str, Any]#

Parse a simulation YAML file and perform minimal validation.

Parameters:
  • path (str or pathlib.Path) – Path to the YAML file containing the simulation parameters.

  • expected_sections (list of str or None, optional) – List of expected top-level sections in the YAML file. If provided, the function will check that these sections are present in the YAML file. Default is None, which means no validation of sections will be performed.

Returns:

A dictionary containing the parsed simulation parameters from the YAML file.

Return type:

dict of str to Any

rizer.misc.simulation.create_case_folder(base_folder: str, case_name: str) pathlib.Path#

Create a folder for the case.