read_format_file

cosmic.utils.read_format_file(format_file_path)[source]

Read the format file associated with the metallicity namelist

Parameters:
format_file_pathstr or Path

Path to the format file.

Returns:
fmt_dictdict

Dictionary containing format file options, e.g., column names, EEP stages, flags.

Notes

  • Booleans (.true./.false.) are converted to Python True/False.

  • Fortran-style scientific notation with ‘d’ (e.g., 1.23d-04) is converted to float.

  • Strings in quotes are stripped of the quotes.

  • Stops parsing at the Fortran namelist terminator ‘/’.