-
Notifications
You must be signed in to change notification settings - Fork 0
/
seaice_grid.py
144 lines (129 loc) · 5.61 KB
/
seaice_grid.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
"""A realm grid sepecialization.
For further information goto http://wordpress.es-doc.org/cmip6-model-specializations.
"""
# --------------------------------------------------------------------
# INTERNAL (do not change)
# --------------------------------------------------------------------
from collections import OrderedDict
DETAILS = OrderedDict()
ENUMERATIONS = OrderedDict()
# --------------------------------------------------------------------
# DESCRIPTION: Short description of the specialization.
# --------------------------------------------------------------------
DESCRIPTION = 'Sea Ice grid'
# --------------------------------------------------------------------
# DISCRETISATION: Description of the horizontal discretization and numerics.
# --------------------------------------------------------------------
DETAILS['discretisation'] = {
'description': 'Sea ice discretisation'
}
DETAILS['discretisation:horizontal'] = {
'description': 'Sea ice discretisation in the horizontal',
'properties': [
('grid', 'ENUM:horizontal_grid', '1.1',
"On which grid is the sea ice horizontal discretisation?"),
('grid_type', 'ENUM:grid_structure', '1.1',
"What is the structure type of the sea ice grid?"),
('scheme', 'ENUM:numerical_scheme', '1.1',
"What is the horizontal discretization (advection) scheme?"),
('thermodynamics_time_step', 'int', '1.1',
"What is the time step in the sea ice model thermodynamic component in seconds."),
('dynamics_time_step', 'int', '1.1',
"What is the time step in the sea ice model dynamic component in seconds."),
('additional_details', 'l-str', '0.1',
"Specify any additional horizontal discretisation details.")
]
}
DETAILS['discretisation:vertical'] = {
'description': 'Sea ice vertical properties',
'properties': [
('layering', 'ENUM:vertical_layering', '1.N',
"What type of sea ice vertical layers are implemented for purposes of thermodynamic calculations?"),
('number_of_layers', 'int', '1.1',
"If using multi-layers specify how many."),
('additional_details', 'l-str', '0.1',
"Specify any additional vertical grid details.")
]
}
# --------------------------------------------------------------------
# SEAICE-CATEGROIES: Description of sea ice categories.
# --------------------------------------------------------------------
DETAILS['seaice_categories'] = {
'description': 'What method is used to represent sea ice categories?',
'properties': [
('has_mulitple_categories', 'bool', '1.1',
"Set to true if the sea ice model has multiple sea ice categories."),
('number_of_categories', 'int', '1.1',
"If using sea ice categories specify how many."),
('category_limits', 'cs-str', '1.1',
"If using sea ice categories specify each of the category limits."),
('ice_thickness_distribution', 'l-str', '1.1',
"Describe the sea ice thickness distribution."),
('other', 'l-str', '0.1',
"""If the sea ice model does not use sea ice categories specify any
additional details. For example models that paramterise
the ice thickness distribution ITD (i.e there is no explicit ITD) but
there is assumed distribution and fluxes are computed accordingly."""),
]
}
# --------------------------------------------------------------------
# Snow on ice grid information
# --------------------------------------------------------------------
DETAILS['snow_on_seaice'] = {
'description': 'Snow on sea ice details',
'properties': [
('has_snow_on_ice', 'bool', '1.1',
"Is snow on ice represented in this model?"),
('number_of_snow_levels', 'int', '1.1',
"Number of vertical levels of snow on ice?"),
('snow_fraction', 'l-str', '1.1',
"Describe how the snow fraction on sea ice is determined."),
('additional_details', 'l-str', '0.1',
"Specify any additional details related to snow on ice.")
]
}
# --------------------------------------------------------------------
# ENUMERATIONS
# --------------------------------------------------------------------
ENUMERATIONS['horizontal_grid'] = {
'description': 'Horizontal discretisation grids',
'is_open': True,
'members': [
('Ocean grid',
'Sea ice is horizontally discretised on the ocean grid.'),
('Atmosphere Grid',
'Sea ice is horizontally discretised on the atmospheric grid.'),
('Own Grid',
'Sea ice is horizontally discretised on its own independent grid.'),
]
}
ENUMERATIONS['vertical_layering'] = {
'description': 'Sea ice layering types',
'is_open': True,
'members': [
('Zero-layer',
'Simulation has no internal ice thermodynamics.'),
('Two-layers',
'Simulation uses two layers (i.e. one ice and one snow layer).'),
('Multi-layers',
'Simulation uses more than two layers.'),
]
}
ENUMERATIONS['numerical_scheme'] = {
'description': 'Numerical advection schemes',
'is_open': True,
'members': [
('Finite differences', None),
('Finite elements', None),
('Finite volumes', None),
]
}
ENUMERATIONS['grid_structure'] = {
'description': 'Grid structure types',
'is_open': True,
'members': [
('Structured grid', None),
('Unstructured grid', None),
('Adaptive grid', 'Computational grid changes during the run'),
]
}