compass.landice.mesh.build_cell_width¶
- compass.landice.mesh.build_cell_width(self, section_name, gridded_dataset, flood_fill_start=[None, None])[source]¶
Determine MPAS mesh cell size based on user-defined density function.
- Parameters:
section_name (str) – Section of the config file from which to read parameters. The following options to be set in the given config section:
levels
,x_min
,x_max
,y_min
,y_max
,min_spac
,max_spac
,high_log_speed
,low_log_speed
,high_dist
,low_dist
,high_dist_bed
,low_dist_bed
,high_bed
,low_bed
,cull_distance
,use_speed
,use_dist_to_edge
,use_dist_to_grounding_line
, anduse_bed
. See the Land-Ice Framework section of the Users or Developers guide for more information about these options and their uses.gridded_dataset (str) – name of NetCDF file used to define cell spacing
flood_fill_start (list of ints) –
i
andj
indices used to define starting location for flood fill. Most cases will use[None, None]
, which will just start the flood fill in the center of the gridded dataset.
- Returns:
cell_width (numpy.ndarray) – Desired width of MPAS cells based on mesh desnity functions to pass to
mpas_tools.mesh.creation.build_mesh.build_planar_mesh()
.x1 (float) – x coordinates from gridded dataset
y1 (float) – y coordinates from gridded dataset
geom_points (jigsawpy.jigsaw_msh_t.VERT2_t) – xy node coordinates to pass to
build_planar_mesh()
geom_edges (jigsawpy.jigsaw_msh_t.EDGE2_t) – xy edge coordinates between nodes to pass to
build_planar_mesh()
flood_mask (numpy.ndarray) – mask calculated by the flood fill routine, where cells connected to the ice sheet (or main feature) are 1 and everything else is 0.