bag.simulation.hdf5
Module Contents
Functions
|
|
|
Saves the given MDArray as a HDF5 file. |
|
Read simulation results from HDF5 file. |
Attributes
- bag.simulation.hdf5._set_chunk_args(kwargs: Dict[str, Any], chunk_size_mb: int, shape: Tuple[int, Ellipsis], unit_size: int) None [source]
- bag.simulation.hdf5.save_sim_data_hdf5(data: bag.simulation.data.SimData, hdf5_path: pathlib.Path, compress: bool = True, chunk_size_mb: int = 2, cache_size_mb: int = 20, cache_modulus: int = 2341) None [source]
Saves the given MDArray as a HDF5 file.
The simulation environments are stored as fixed length byte strings, and the sweep parameters are stored as dimension label for each data.
- Parameters:
data (SimData) – the data.
hdf5_path (Path) – the hdf5 file path.
compress (str) – HDF5 compression method. Defaults to ‘lzf’ for speed (use ‘gzip’ for space).
chunk_size_mb (int) – HDF5 data chunk size, in megabytes. 0 to disable.
cache_size_mb (int) – HDF5 file chunk cache size, in megabytes.
cache_modulus (int) – HDF5 file chunk cache modulus.
- bag.simulation.hdf5.load_sim_data_hdf5(path: pathlib.Path, cache_size_mb: int = 20, cache_modulus: int = 2341) bag.simulation.data.SimData [source]
Read simulation results from HDF5 file.