model_to_h5

Contents

model_to_h5#

scarlet2.io.model_to_h5(model, filename, id=0, path='.', overwrite=False)[source]#

Save the scene model to a HDF5 file

Parameters:
  • filename (str) – Name of the HDF5 file to create

  • model (Module) – Scene to be stored

  • id (int) – HDF5 group to store this model under

  • path (str, optional) – Explicit path for filename. If not set, uses local directory

  • overwrite (bool, optional) – Whether to overwrite an existing file with the same path and filename

Return type:

None

Notes

This is not a pure function hence cannot be utilized within a JAX JIT compilation.