fgmax_tools module for working with topography data

Documentation auto-generated from the module docstrings

fgmax_tools module: $CLAW/geoclaw/src/python/geoclaw/fgmax_tools.py

Tools to specify an fgmax grid for keeping track of maximum flow depth, etc. and to read in the fgmax output after doing a GeoClaw run.

class clawpack.geoclaw.fgmax_tools.FGmaxGrid

New class introduced in 5.2.1 to keep store information both about the fgmax input data and the output generated by a GeoClaw run.

interp_dz(dtopo_path, dtopo_type)

Compute approximate values of deformation dz on X,Y grid using a specified dtopo file. Also calculates B0 = B - dz, attempting to recover the pre-event topography from the GeoClaw run topography stored in B.


for point_style==4, convert lists of fgmax values into masked arrays based on the topo_style==3 file self.xy_fname that was used to specify the fgmax points in the GeoClaw run.

read_fgmax_grids_data(fgno, data_file='fgmax_grids.data')

Read input info for fgmax grid number fgno from the data file fgmax_grids.data, which should have been created by setrun.py. This file now contains info about all fgmax grids.

read_output(fgno=None, outdir=None, verbose=True)

Read the GeoClaw results on the fgmax grid numbered fgno.

clawpack.geoclaw.fgmax_tools.adjust_fgmax_1d(x1_desired, x2_desired, x1_domain, dx)
  • x1_desired, x2_desired: approximate desired limits of fgmax grid

  • x1_domain: lower edge of computational domain

  • dx: Mesh spacing on fine grid that fgmax grid should conform to

  • x1_new, x2_new: limits to set so (x2-x1) is integer multiple of dx and points are at cell centers of computational grid

  • npoints: number of points