Provides the utilities required to load .hst files from Pegasus++.
- pegasustools.loading_hst.load_hst_file(hst_path)¶
Load the contents of a .hst files as a Polars dataframe.
Automatically corrects for any overlap due to restarts by only accepting the newest/latest data.
- Parameters:
hst_path (Path) – The path to the .hst file
- Returns:
The Polars dataframe that contains the data from the .hst file. Note that the contents are all in FP32 since the .hst files don’t contain enough precision for FP64.
- Return type:
pl.DataFrame
- Raises:
RuntimeError – Raised if the .hst files doesn’t have the proper header. Namely it checks that the first line is ‘# Athena++ history datan’ as a quick indicator if this is the proper file type.