|
1 | 1 | from compass.validate import compare_variables, compare_timers
|
2 | 2 | from compass.ocean.tests.global_ocean.forward import ForwardTestCase, \
|
3 | 3 | ForwardStep
|
| 4 | +from compass.ocean.inactive_top_cells import remove_inactive_top_cells_output |
4 | 5 |
|
5 | 6 |
|
6 | 7 | class PerformanceTest(ForwardTestCase):
|
@@ -61,6 +62,18 @@ def validate(self):
|
61 | 62 | compare_variables(test_case=self, variables=variables,
|
62 | 63 | filename1='forward/output.nc')
|
63 | 64 |
|
| 65 | + if self.config.has_option('vertical_grid', 'inactive_top_cells'): |
| 66 | + offset = self.config.getint('vertical_grid', 'inactive_top_cells') |
| 67 | + if offset > 0: |
| 68 | + remove_inactive_top_cells_output('forward/output.nc', |
| 69 | + inactive_top_cells=offset) |
| 70 | + variables = [ |
| 71 | + 'temperature', 'salinity', 'layerThickness', 'normalVelocity'] |
| 72 | + compare_variables(test_case=self, variables=variables, |
| 73 | + filename1='forward/output_crop.nc', |
| 74 | + filename2='forward/output_comp.nc', |
| 75 | + quiet=False, check_outputs=False) |
| 76 | + |
64 | 77 | if self.mesh.with_ice_shelf_cavities:
|
65 | 78 | variables = [
|
66 | 79 | 'ssh', 'landIcePressure', 'landIceDraft', 'landIceFraction',
|
|
0 commit comments