1 | \newpage |
---|
2 | |
---|
3 | \chapter{Changes between the different versions of OASIS3-MCT} |
---|
4 | \label{sec_changes} |
---|
5 | |
---|
6 | The evolution between the different versions of OASIS3-MCT can be |
---|
7 | followed in real-time by registering on the Redmine project management |
---|
8 | site at https://inle.cerfacs.fr/ (see "Register" at the right top of |
---|
9 | the page). On this site, registered users can browse the sources and |
---|
10 | consult tickets describing bug fixes and developments. To follow day |
---|
11 | to day evolution of the OASIS3-MCT sources, it is also possible to |
---|
12 | have your e-mail added to the list of addresses to which the log files |
---|
13 | of the SVN checkins are automatically sent; please contact |
---|
14 | oasishelp@cerfacs.fr if you wish to be added to that list. |
---|
15 | |
---|
16 | \section{Changes between OASIS3-MCT\_1.0 and OASIS3-MCT\_2.0} |
---|
17 | \label{sec_oa1_oa2} |
---|
18 | |
---|
19 | The main changes and bug fixes new in OASIS3-MCT\_2.0 are the |
---|
20 | following: |
---|
21 | \begin{itemize} |
---|
22 | |
---|
23 | \item Support of {\tt BICUBIC} interpolation, see paragraph {\tt |
---|
24 | BICUBIB} in section \ref{subsec_interp}. If the source grid |
---|
25 | is not a gaussian reduced grid (D), the gradient in the first dimension, |
---|
26 | the gradient in the second dimension, and the cross-gradient |
---|
27 | of the coupling field must be calculated by the model and |
---|
28 | given as arguments to {\tt oasis\_put}, as explained in section \ref{prismput}. |
---|
29 | If the source grid is a gaussian reduced grid (D), OASIS3-MCT\_2.0 |
---|
30 | can calculate the interpolated field using only the values of the source |
---|
31 | field points. |
---|
32 | |
---|
33 | \item Support of {\tt CONSERV/SECOND} regridding, see paragraph {\tt |
---|
34 | CONSERV/SECOND} in section \ref{subsec_interp}. |
---|
35 | |
---|
36 | \item Support of components exchanging data on only a subdomain of the |
---|
37 | global grid: a new optional argument, ig\_size was added to |
---|
38 | oasis\_def\_partition, that provides the user with the ability to |
---|
39 | define the total number of grid cells on the grid (see section |
---|
40 | \ref{subsubsec_Partition}). |
---|
41 | |
---|
42 | %\item The CPP key "balance" in mod\_oasis\_advance was added; this |
---|
43 | % option can be used to produce timestamps in OASIS debug file (see |
---|
44 | % section \ref{subsec_cpp}). |
---|
45 | |
---|
46 | \item The variable {\tt TIMER\_Debug} controlling the amount of time |
---|
47 | statistics written out is now an optional argument read in the {\it |
---|
48 | namcouple}; see the {\tt NLOGPRT} line in |
---|
49 | \ref{subsec_namcouplefirst} and all details about time statistics in |
---|
50 | section \ref{timestat}. |
---|
51 | |
---|
52 | \item Specific problems in writing out the time statistics when all |
---|
53 | the processors are not coupling were solved (see Redmine issue |
---|
54 | \#497) |
---|
55 | |
---|
56 | \item The problem with restart files when one coupling field is sent |
---|
57 | to 2 target components was solved (see Redmine ticket \#522) |
---|
58 | |
---|
59 | \item A memory leak in mod\_oasis\_getput\_interface.F90 was fixed |
---|
60 | thanks to R. Hill from the MetOffice (see Redmine ticket \#437) |
---|
61 | |
---|
62 | \item A bug fix was provided to ensure that the nearest neighbour |
---|
63 | option is activated when the option {\tt FRACNNEI} is defined in the |
---|
64 | {\it namcouple} for the conservative interpolation . |
---|
65 | |
---|
66 | \item The behaviour of OASIS3-MCT was changed in the case a |
---|
67 | component model tries to send with {\tt oasis\_put} a field declared |
---|
68 | with a {\tt oasis\_def\_var} but not defined in the configuration |
---|
69 | file {\it namcouple}; this will now lead to an abort. In this case, |
---|
70 | the field ID returned by the {\tt oasis\_def\_var} is equal to -1 |
---|
71 | and the corresponding {\tt oasis\_put} should not be called. |
---|
72 | |
---|
73 | \item OASIS3-MCT developments are now continuously tested and |
---|
74 | validated on different computers with a test suite under Buildbot, |
---|
75 | which is a software written in Python to automate compile and test |
---|
76 | cycles required in software project (see |
---|
77 | https://inle.cerfacs.fr/projects/oasis3-mct/wiki/Buildbot on the |
---|
78 | Redmine site). |
---|
79 | |
---|
80 | \end{itemize} |
---|
81 | |
---|
82 | \section{Changes between OASIS3.3 and OASIS3-MCT\_1.0} |
---|
83 | |
---|
84 | \subsection{General architecture} |
---|
85 | \label{sec_changes_gen} |
---|
86 | |
---|
87 | \begin{itemize} |
---|
88 | \item OASIS3-MCT is (only) a coupling library |
---|
89 | |
---|
90 | Much of the underlying implementation of OASIS3 was refactored to |
---|
91 | leverage the Model Coupling Toolkit (MCT). OASIS3-MCT is a coupling |
---|
92 | library to be linked to the component models and that |
---|
93 | carries out the coupling field transformations (e.g. remappings/interpolations) |
---|
94 | in parallel on either the source or target processes and that performs |
---|
95 | all communication in parallel directly between the component models; there |
---|
96 | is no central coupler executable anymore\footnote{As with OASIS3.3, |
---|
97 | the ``put'' calls are non-blocking but the ``get'' calls are |
---|
98 | blocking. As before, the user has to take care of implementing a coupling |
---|
99 | algorithm that will result in matching ``put'' and ``get'' calls to |
---|
100 | avoid deadlocks (see section \ref{subsubsec_sendingreceiving}). The lag (LAG) index works as |
---|
101 | before in OASIS3.3 (see section \ref{subsubsec_Algoritms})}. |
---|
102 | |
---|
103 | \item {\tt MAPPING} transformation to use a pre-defined mapping file |
---|
104 | |
---|
105 | With {\tt MAPPING}, OASIS3-MCT has the ability to read a predefined |
---|
106 | set of weights and addresses (mapping file) specified in the {\it |
---|
107 | namcouple} to perform the interpolation/remapping. The user also has |
---|
108 | the flexibility to choose the location and the parallelization strategy of the |
---|
109 | remapping with specific {\tt MAPPING} options (see section \ref{subsec_interp}). |
---|
110 | |
---|
111 | \item Mono-process mapping file generation with the SCRIP library |
---|
112 | |
---|
113 | But as before, OASIS3-MCT\_1.0 can |
---|
114 | also generate the mapping file using the SCRIP library |
---|
115 | \citep{Jones99}. When this is the case, the mapping file generation is |
---|
116 | done on one process of the model components; all previous {\tt SCRIPR} remapping |
---|
117 | schemes available in OASIS3.3 are still supported besides {\tt |
---|
118 | BICUBIC} and {\tt CONSERV/SECOND}. (Note: these remapping schemes, not available in OASIS3-MCT\_1.0 |
---|
119 | were reactivated in OASIS3-MCT\_2.0, see \ref{sec_oa1_oa2}.) |
---|
120 | |
---|
121 | \item MPI2 job launching is NOT supported. |
---|
122 | |
---|
123 | Only MPI1 start mode is allowed. As before with the MPI1 mode, all |
---|
124 | component models must be started by the user in the job script in a |
---|
125 | pseudo-MPMD mode; in this case, they will automatically share the |
---|
126 | same {\tt MPI\_COMM\_WORLD} communicator and an internal |
---|
127 | communicator created by OASIS3-MCT needs to be used for internal |
---|
128 | parallelization (see section \ref{subsec_MPI1}). |
---|
129 | |
---|
130 | \end{itemize} |
---|
131 | |
---|
132 | \subsection{Changes in the coupling interface in the component models} |
---|
133 | \label{sec_changes_API} |
---|
134 | |
---|
135 | \begin{itemize} |
---|
136 | |
---|
137 | \item Use statement |
---|
138 | |
---|
139 | The different OASIS3.3 {\tt USE} statements were gathered into one {\tt |
---|
140 | USE mod\_oasis} (or one {\tt USE mod\_prism}), therefore much |
---|
141 | simpler to use. |
---|
142 | |
---|
143 | \item Support of previous {\tt prism\_xxx} and new {\tt oasis\_xxx} |
---|
144 | interfaces |
---|
145 | |
---|
146 | OASIS3-MCT retains prior interface names of OASIS3.3 |
---|
147 | (e.g. {\tt prism\_put\_proto}) to ensure full backward |
---|
148 | compatibility. However, new interface names such as {\tt |
---|
149 | oasis\_put} are also available and should be prefered. Both |
---|
150 | routine names are listed in chapter \ref{sec_modelinterfacing}. |
---|
151 | |
---|
152 | \item Auxiliary routines not supported yet |
---|
153 | |
---|
154 | Auxiliary routines {\tt prism\_put\_inquire}, {\tt |
---|
155 | prism\_put\_restart\_proto}, {\tt prism\_get\_freq} are not |
---|
156 | supported yet. |
---|
157 | |
---|
158 | \item Support of components for which only a subset of processes |
---|
159 | participate in the coupling |
---|
160 | |
---|
161 | New routines {\tt oasis\_create\_couplcomm} and {\tt |
---|
162 | oasis\_set\_couplcomm} are now available to create or set a coupling |
---|
163 | communicator in the case only a subset of the component processes |
---|
164 | participate in the coupling (see section \ref{subsec_subset}). But |
---|
165 | even in this case, all OASIS3-MCT interface routines, besides the |
---|
166 | grid definition (see section \ref{subsubsec_griddef}) and the |
---|
167 | ``put'' and `` get'' call per se (see section |
---|
168 | \ref{subsubsec_sendingreceiving}), are collective and must be called |
---|
169 | by all processes. |
---|
170 | |
---|
171 | \item New routines {\tt oasis\_get\_debug} and {\tt oasis\_set\_debug} |
---|
172 | |
---|
173 | New routines {\tt oasis\_get\_debug} and {\tt oasis\_set\_debug} |
---|
174 | are now available to respectively retrieve the current OASIS3-MCT |
---|
175 | internal debug level (set by {\tt \$NLOGPRT} in the {\it namcouple}) or to change it (see section |
---|
176 | \ref{subsubsec_auxroutines}). |
---|
177 | |
---|
178 | \end{itemize} |
---|
179 | |
---|
180 | \subsection{Functionality not offered anymore} |
---|
181 | \label{sec_changes_old} |
---|
182 | |
---|
183 | \begin{itemize} |
---|
184 | |
---|
185 | \item {\tt SCRIPR/BICUBIC} and {\tt SCRIPR/CONSERV/SECOND} remappings |
---|
186 | |
---|
187 | As in OASIS3.3, the SCRIP library can be used to generate the |
---|
188 | remapping/interpolation weights and addresses and write them to a |
---|
189 | mapping file. All previous {\tt SCRIPR} remapping |
---|
190 | schemes available in OASIS3.3 are still supported in OASIS3-MCT\_1.0 besides {\tt |
---|
191 | BICUBIC} and {\tt CONSERV/SECOND} because these remapping involve |
---|
192 | at each source grid point the value of the field but also the value of the |
---|
193 | gradients of the field (which are not known or calculated). (Note: these remapping schemes, |
---|
194 | not available in OASIS3-MCT\_1.0 were reactivated in OASIS3-MCT\_2.0, see \ref{sec_oa1_oa2}.) |
---|
195 | |
---|
196 | \item Vector field remapping |
---|
197 | |
---|
198 | Vector field remapping is not and will not be supported (see ``Support |
---|
199 | of vector fields with the SCRIPR remappings'' in section \ref{subsec_interp}). |
---|
200 | |
---|
201 | \item Automatic calculation of grid mesh corners in {\tt SCRIPR/CONSERV} |
---|
202 | |
---|
203 | For {\tt SCRIPR/CONSERV} remapping, grid mesh corners will not |
---|
204 | be compute automatically if they are needed but not provided. |
---|
205 | |
---|
206 | \item Other transformations not supported |
---|
207 | |
---|
208 | \begin{itemize} |
---|
209 | |
---|
210 | \item The following transformations are not available in OASIS3.3 |
---|
211 | and will most probably not be implemented as it should be not |
---|
212 | too difficult to implement the equivalent operations in the component |
---|
213 | models themselves: {\tt CORRECT}, {\tt FILLING}, {\tt SUBGRID}, {\tt MASKP} |
---|
214 | |
---|
215 | \item {\tt LOCTRANS/ONCE} is not explicitely offered as it is equivalent to |
---|
216 | defining a coupling period equal to the total runtime. |
---|
217 | |
---|
218 | \item The following transformations are not available as they were already |
---|
219 | deprecated in OASIS3.3 (see OASIS3.3 User Guide): {\tt REDGLO}, {\tt INVERT}, |
---|
220 | {\tt REVERSE}, {\tt GLORED} |
---|
221 | |
---|
222 | \item {\tt MASK} and {\tt EXTRAP} are not available but the corresponding |
---|
223 | linear extrapolation can be replaced by the more efficient option |
---|
224 | using the nearest non-masked source neighbour for target points having |
---|
225 | their original neighbours all masked. This is now the default option for {\tt SCRIPR/}{\tt DISTWGT}, {\tt GAUSWGT} and {\tt BILINEAR} interpolations. It is |
---|
226 | also included in \newline {\tt SCRIPR/CONSERV} if {\tt FRACNNEI} |
---|
227 | normalization option is chosen (see section \ref{subsec_interp}). |
---|
228 | |
---|
229 | \item {\tt INTERP} interpolations are not available; {\tt SCRIPR} |
---|
230 | should be used instead. |
---|
231 | |
---|
232 | \item {\tt MOZAIC} is not available as {\tt MAPPING} should be used |
---|
233 | instead. |
---|
234 | |
---|
235 | \item{\tt NOINTERP} does not need to be specified anymore if no |
---|
236 | interpolation is required. |
---|
237 | |
---|
238 | \item Field combination with {\tt BLASOLD} and {\tt BLASNEW}; these |
---|
239 | transformations only support multiplication and addition terms to |
---|
240 | the fields (see section \ref{subsec_preproc}). |
---|
241 | |
---|
242 | \end{itemize} |
---|
243 | |
---|
244 | \item Using the coupler in interpolator-only mode |
---|
245 | |
---|
246 | This is not possible anymore as OASIS3-MCT is now only a coupling |
---|
247 | library. However, it is planned, in a further release, to provide a |
---|
248 | toy coupled model that could be use to check the quality of the |
---|
249 | remapping for any specific couple of grids. |
---|
250 | |
---|
251 | \item Coupling field CF standard names |
---|
252 | |
---|
253 | The file cf\_name\_table.txt is not needed or used anymore. The CF |
---|
254 | standard names of the coupling fields are not written to the debug |
---|
255 | files. |
---|
256 | |
---|
257 | \item Binary auxiliay files |
---|
258 | |
---|
259 | All auxiliary files, besides the {\it namcouple} must be NetCDF; |
---|
260 | binary files are not supported anymore. |
---|
261 | \end{itemize} |
---|
262 | |
---|
263 | \subsection{New functionality offered} |
---|
264 | \label{sec_changes_new} |
---|
265 | |
---|
266 | \begin{itemize} |
---|
267 | |
---|
268 | \item Better support of components for which only a subset of processes |
---|
269 | participate in the coupling |
---|
270 | |
---|
271 | In OASIS3.3, components for which only a subset of processes |
---|
272 | participated in the coupling were supported in a very restricted |
---|
273 | way. In fact, this subset had to be composed of the N first |
---|
274 | processes and N had to be specified in the {\it namcouple}. Now, the |
---|
275 | subset of processes can be composed of any of the component |
---|
276 | processes and does not have to be pre-defined in the {\it |
---|
277 | namcouple}. New routines {\tt oasis\_create\_couplcomm} and {\tt |
---|
278 | oasis\_set\_couplcomm} are now available to create or set a coupling |
---|
279 | communicator gathering only these processes (see section \ref{subsec_subset}). |
---|
280 | |
---|
281 | \item Exact restart for {\tt LOCTRANS} transformations |
---|
282 | |
---|
283 | If needed, LOCTRANS transformations write partially |
---|
284 | transformed fields in the coupling restart file at the end of a run |
---|
285 | to ensure an exact restart of the next run (see section |
---|
286 | \ref{subsec_timetrans}). For that |
---|
287 | reason, coupling restart filenames are now required for all {\it |
---|
288 | namcouple} entries that use LOCTRANS (with non INSTANT |
---|
289 | values). This is the reason an optional restart file is now provided |
---|
290 | on the OUTPUT {\it namcouple} input line. If the coupling periods of |
---|
291 | two (or more) coupling fields are different, it is necessary to define |
---|
292 | two (or more) restart files, one for each field. |
---|
293 | |
---|
294 | \item Support to couple multiple fields via a single communication. |
---|
295 | |
---|
296 | This is supported through colon |
---|
297 | delimited field lists in the {\it namcouple}, for example |
---|
298 | |
---|
299 | {\tt ATMTAUX:ATMTAUY:ATMHFLUX TAUX:TAUY:HEATFLUX 1 3600 3 rstrt.nc EXPORTED} |
---|
300 | |
---|
301 | in a single {\it namcouple} entry. All fields will use the |
---|
302 | {\it namcouple} settings for that entry. In the component model codes, |
---|
303 | these fields are still sent (``put'') or received (``get'') one at a |
---|
304 | time. Inside OASIS3-MCT, the fields are stored and a single mapping |
---|
305 | and send or receive instruction is executed for all fields. This is |
---|
306 | useful in cases where multiple fields have the same coupling |
---|
307 | transformations and to reduce communication costs by aggregating multiple |
---|
308 | fields into a single communication. If a LOCTRAN transformation is needed |
---|
309 | for these multiple fields, it is necessary to define a restart file for |
---|
310 | these multiple fields. {\bf The coupling fields must be sent and received in the same order |
---|
311 | as they are defined in the corresponding single entry of the namcouple}. |
---|
312 | |
---|
313 | \item Matching one source filed with multiple targets |
---|
314 | |
---|
315 | A coupling field sent by a source component model can be associated |
---|
316 | with more than one target field and model (get). In that case, the |
---|
317 | source model needs to send (``put'') the field only once and the |
---|
318 | corresponding data will arrive at multiple targets as specified in |
---|
319 | the {\it namcouple} configuration file. Different coupling |
---|
320 | frequencies and transformations are allowed for different coupling |
---|
321 | exchanges of the same field. If coupling restart files are required |
---|
322 | (either if a {\tt LAG} or if a {\tt LOCTRANS} transformation is |
---|
323 | specified), it is mandatory to specify different files for the |
---|
324 | different fields. |
---|
325 | |
---|
326 | %In addition, a single |
---|
327 | % coupling field can be sent to the same destination model using |
---|
328 | % multiple transforms as long as the destination field name is |
---|
329 | % unique. |
---|
330 | The inverse feature is not allowed, i.e. a single target (get) field |
---|
331 | CANNOT be associated with multiple source (put) fields. |
---|
332 | |
---|
333 | \item The debug files |
---|
334 | |
---|
335 | The debug mode was greatly improved as compared to OASIS3.3. The level |
---|
336 | of debug information written out to the OASIS3-MCT debug files for |
---|
337 | each model process is defined by the \$NLOGPRT value in the {\it |
---|
338 | namcouple}. All details are provided in section |
---|
339 | \ref{subsec_namcouplefirst}. |
---|
340 | |
---|
341 | \end{itemize} |
---|
342 | |
---|
343 | \subsection{Changes in the configuration file {\it namcouple}} |
---|
344 | \label{sec_changes_namcouple} |
---|
345 | |
---|
346 | \begin{itemize} |
---|
347 | |
---|
348 | \item The {\it namcouple} configuration file of OASIS3-MCT is fully backward |
---|
349 | compatible with OASIS3.3. However, several {\it namcouple} keywords |
---|
350 | have been deprecated even if they are still |
---|
351 | allowed. These keywords are noted ``UNUSED'' in sections |
---|
352 | \ref{subsec_namcouplefirst} and \ref{subsec_namcouplesecond} and are |
---|
353 | not fully described. Information below these keywords will not be read |
---|
354 | and will not be used: \$SEQMODE , \$CHANNEL, \$JOBNAME, \$INIDATE, |
---|
355 | \$MODINFO, \$CALTYPE. |
---|
356 | |
---|
357 | \item Also the following inputs should not appear in the {\it namcouple} |
---|
358 | anymore as the related functionality are not supported anymore in |
---|
359 | OASIS3-MCT (see above): field status AUXILARY, time transformation |
---|
360 | ONCE, REDGLO, INVERT, MASK, EXTRAP, CORRECT, INTERP, MOZAIC, FILLING, |
---|
361 | SUBGRID, MASKP, REVERSE, GLORED. |
---|
362 | |
---|
363 | \item To get 2D fields in the debug output NetCDF files, the 2D dimensions of the |
---|
364 | grids must be provided in the {\it namcouple} (except if the field |
---|
365 | has the status OUTPUT); otherwise, the fields in the debug output files will be 1D. |
---|
366 | |
---|
367 | \end{itemize} |
---|
368 | |
---|
369 | \subsection{Other differences} |
---|
370 | \label{sec_changes_other} |
---|
371 | |
---|
372 | \begin{itemize} |
---|
373 | |
---|
374 | \item IGNORED and IGNOUT fields are converted to EXPORTED and EXPOUT |
---|
375 | respectively. |
---|
376 | |
---|
377 | \item The file {\tt areas.nc} is not needed anymore to calculate some |
---|
378 | statistics with options CHECKIN and/or CHECKOUT (see section \ref{subsec_preproc}). |
---|
379 | |
---|
380 | \item SEQ index is no longer needed to ensure correct coupling |
---|
381 | sequencing within the coupler. Use of SEQ allows the coupling layer |
---|
382 | to detect potential deadlocks before they happen and to exit |
---|
383 | gracefully (see section \ref{subsec_sec}). |
---|
384 | |
---|
385 | \item The I/O library mpp\_io is no longer used to write the restart and output files. |
---|
386 | |
---|
387 | |
---|
388 | \end{itemize} |
---|