slm_circ_icesheet
The slm_circ_icesheet test group (compass.landice.tests.slm_circ_icesheet.SlmCircIcesheet) adds a
framework for evaluating coupled MALI and Sea-Level Model (SLM) behavior.
The group contains two test cases:
mesh_convergence(compass.landice.tests.slm_circ_icesheet.circ_icesheet.CircIcesheetTest), which compares MALI-derived and SLM-derived estimates of sea-level change across a parameter sweep of mesh and SLM resolutions.smoke_test, a minimal test case intended for quick validation and CI.
framework
The shared config options for this group are documented in slm_circ_icesheet in the User’s Guide.
The configure() method of CircIcesheetTest parses two comma-delimited
parameter lists from the config:
mali_resfrom the[circ_icesheet]section, andslm_nglvfrom the[slm]section.
The test case then creates one setup_mesh and one run_model step for
each (mali_res, slm_nglv) pair. Step names follow the pattern
mali<res>km_slm<nglv>/<step>. A single visualize step is then added
to summarize and compare all runs.
setup_mesh
The class
compass.landice.tests.slm_circ_icesheet.circ_icesheet.setup_mesh.SetupMesh
builds all inputs required by MALI and SLM coupling for each
(mali_res, slm_nglv) combination:
creates a planar hex mesh and culls it,
converts the mesh to a MALI grid and writes
graph.info,applies idealized circular initial conditions,
writes an SMB forcing file (either radial or vertical forcing), and
builds MALI<->SLM mapping files with ESMF.
The mapping workflow creates an SLM SCRIP grid from slm_nglv and
slm_res, creates a MALI SCRIP file from the generated MALI grid, and then
builds both mapping_file_mali_to_slm.nc and
mapping_file_slm_to_mali.nc.
run_model
The class
compass.landice.tests.slm_circ_icesheet.circ_icesheet.run_model.RunModel
consumes the mesh, graph, SMB forcing, and mapping files from setup_mesh
and runs MALI with SLM coupling options enabled in namelist.landice.
During setup(), the step also:
creates
OUTPUT_SLMandICELOAD_SLMdirectories,renders
namelist.sealevelfrom the Jinja templatecompass.landice.tests.slm_circ_icesheet.namelist.sealevel.template, andfills SLM input paths from the
slm_input_rootconfig option.
The expected structure beneath slm_input_root is:
icemodel/GL<nglv>/ice_noGrIS_GL<nglv>/others/GL<nglv>/earthmodel/
visualize
The class
compass.landice.tests.slm_circ_icesheet.circ_icesheet.visualize.Visualize
collects all output.nc files produced by the parameter sweep and computes
diagnostic quantities for coupled MALI-SLM comparison.
For each run combination, the analysis computes grounded-ice mass change,
sea-level contributions with and without the z0 term, and percent-error
metrics relative to SLM outputs. The step can generate:
per-case time-series plots,
per-resolution error curves over
slm_nglv, anda heat map of mean percent error.
The [circ_icesheet_viz] section controls plot output (save/hide figures)
and provides constant ocean-area values used as analysis fallbacks.