Skip to content

Commit

Permalink
clean up some formatting issues
Browse files Browse the repository at this point in the history
  • Loading branch information
hollyhan committed Aug 31, 2024
1 parent d115cc0 commit 77d6c8a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 15 deletions.
10 changes: 2 additions & 8 deletions compass/landice/tests/slm/circ_icesheet/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,6 @@ class CircIcesheetTest(TestCase):
This test generates an idealized, circular ice sheet that has a
prescribed thickness evolution for testing coupling between MALI
and the Sea-Level Model.
Attributes
----------
"""

def __init__(self, test_group):
Expand All @@ -20,12 +17,9 @@ def __init__(self, test_group):
Parameters
----------
test_group : compass.landice.tests.dome.Dome
test_group : compass.landice.tests.slm.Slm
The test group that this test case belongs to
The resolution or type of mesh of the test case
name : str, optional
the name of the test case
"""
name = 'circular_icesheet_test'
subdir = name
Expand All @@ -51,7 +45,7 @@ def configure(self):
for nglv in slm_nglv:
self.add_step(SetupMesh(test_case=self,
name=f'mali{res}km_slm{nglv}/'
f'setup_mesh', res=res, nglv=nglv))
'setup_mesh', res=res, nglv=nglv))
if (int(res) <= 16 and int(res) > 2):
ntasks = 256
elif (int(res) <= 2):
Expand Down
7 changes: 4 additions & 3 deletions compass/landice/tests/slm/circ_icesheet/circ_icesheet.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,10 @@ r0 = 2000000.0
h0 = 3000.0

# 'True' if manually want to set bedTopography elevation
# bed topography elevation in meters (provide a positive/negative float value
# for grounded above land/marine-based ice)
# if 'False' topography will be set to 0 everywhere (flat bed at sea level)
set_topo_elev = True
# flat bed topography elevation in meters
# (positive value => land, negative => ocean)
topo_elev = -1500.0

# Whether to center the circular ice in the center of the cell that is closest to the
Expand Down Expand Up @@ -47,7 +48,7 @@ dhdt = -20.0
coupling = True

# List of the number of Gauss-Legendre points in latitude
# delimited by ',' without space
# list delimited by ',' without space
slm_nglv = 512

# Max spherical harmonics degree and order
Expand Down
6 changes: 2 additions & 4 deletions compass/landice/tests/slm/circ_icesheet/run_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,8 @@
class RunModel(Step):
"""
A step for performing forward MALI runs as part of dome test cases.
Attributes
----------
"""

def __init__(self, test_case, res, nglv, ntasks, name='run_model',
subdir=None, min_tasks=None, openmp_threads=1):
"""
Expand Down Expand Up @@ -93,7 +91,7 @@ def setup(self):
'namelist.sealevel.template'))
text = template.render(nglv=self.nglv)

# write out the namelise.sealevel file
# write out the namelist.sealevel file
file_slm_nl = os.path.join(self.work_dir, 'namelist.sealevel')
with open(file_slm_nl, 'w') as handle:
handle.write(text)
Expand Down

0 comments on commit 77d6c8a

Please sign in to comment.