roms_tools.Grid.update_topography

roms_tools.Grid.update_topography#

Grid.update_topography(topography_source: dict | None = None, hmin: float | None = None, verbose: bool = False) None#

Update the grid dataset with processed topography.

This method performs the following operations:

  1. Regrids the topography from the specified source.

  2. Applies domain-wide and local smoothing.

  3. Enforces the minimum depth constraint hmin.

  4. Updates the internal dataset (self.ds) with the processed bathymetry.

Parameters:
  • topography_source (dict, optional) –

    Dictionary specifying the topography data source with keys:

    • "name" (str): Name of the topography dataset (e.g. "SRTM15")

    • "path" (str or pathlib.Path): Path to the raw data file

    If not provided, topography_source will remain unchanged (i.e., the existing value will not be overwritten).

  • hmin (float, optional) – Minimum ocean depth in meters. If not provided, hmin will remain unchanged (i.e., the existing value will not be overwritten).

  • verbose (bool, optional) – If True, print detailed information about the processing steps and timing. Defaults to False.

Returns:

None – Updates self.ds in place.