from_arrays_with_metadata

s100py.s102.v2_1.utils.from_arrays_with_metadata(depth_grid, uncert_grid, metadata, output_file, nodata_value=None, overwrite=True, flip_z=False)

Creates or updates an S102File object based on numpy array/h5py datasets. Calls create_s102 then fills in the HDF5 datasets with the supplied depth_grid and uncert_grid. Fills the number of points areas and any other appropriate places in the HDF5 file per the S102 spec.

For most parameters, see S102File.load_arrays

Parameters:

output_file – Can be an S102File object or anything the h5py.File would accept, e.g. string file path, tempfile obect, BytesIO etc.

Return type:

S102File