source: trunk/libIGCM/libIGCM_post/libIGCM_post.ksh @ 373

Last change on this file since 373 was 373, checked in by sdipsl, 14 years ago

Remove libIGCM_sys_claude.ksh and libIGCM_sys_calculo.ksh
Update/homogenize all headers usgin the new fixed-length keyword syntax regarding properties keywords
$Rev:: 13 i $: Revision of last commit
$Author:: harry $: Author of last commit
$Date:: 2006-03-15 02:33:03 -0500 (Wed, 15 Mar 2006) $: Date of last commit
Add / update original author and contact when missing

  • Property licence set to
    The following licence information concerns ONLY the libIGCM tools
    ==================================================================

    Copyright © Centre National de la Recherche Scientifique CNRS
    Commissariat à l'Énergie Atomique CEA

    libIGCM : Library for Portable Models Computation of IGCM Group.

    IGCM Group is the french IPSL Global Climate Model Group.

    This library is a set of shell scripts and functions whose purpose is
    the management of the initialization, the launch, the transfer of
    output files, the post-processing and the monitoring of datas produce
    by any numerical program on any plateforme.

    This software is governed by the CeCILL license under French law and
    abiding by the rules of distribution of free software. You can use,
    modify and/ or redistribute the software under the terms of the CeCILL
    license as circulated by CEA, CNRS and INRIA at the following URL
    "http://www.cecill.info".

    As a counterpart to the access to the source code and rights to copy,
    modify and redistribute granted by the license, users are provided only
    with a limited warranty and the software's author, the holder of the
    economic rights, and the successive licensors have only limited
    liability.

    In this respect, the user's attention is drawn to the risks associated
    with loading, using, modifying and/or developing or reproducing the
    software by the user in light of its specific status of free software,
    that may mean that it is complicated to manipulate, and that also
    therefore means that it is reserved for developers and experienced
    professionals having in-depth computer knowledge. Users are therefore
    encouraged to load and test the software's suitability as regards their
    requirements in conditions enabling the security of their systems and/or
    data to be ensured and, more generally, to use and operate it in the
    same conditions as regards security.

    The fact that you are presently reading this means that you have had
    knowledge of the CeCILL license and that you accept its terms.
  • Property svn:keywords set to Revision Author Date
File size: 35.9 KB
Line 
1#!/bin/ksh
2
3#**************************************************************
4# Author: Sebastien Denvil
5# Contact: Sebastien.Denvil__at__ipsl.jussieu.fr
6# $Revision::                                          $ Revision of last commit
7# $Author::                                            $ Author of last commit
8# $Date::                                              $ Date of last commit
9# IPSL (2006)
10#  This software is governed by the CeCILL licence see libIGCM/libIGCM_CeCILL.LIC
11#
12#**************************************************************
13
14#=======================================================================
15
16function IGCM_post_Configure
17{
18    IGCM_debug_PushStack "IGCM_post_Configure"
19
20    # Debug Print :
21    echo
22    IGCM_debug_Print 1 "IGCM_post_Configure :"
23    echo
24
25    typeset NbDays PeriodEndJul PostEndJul PeriodPost
26    RebuildFrequency=false
27
28    if ( [ ! X${config_Post_RebuildFrequency} = X${NULL_STR} ] && [ ! X${config_Post_RebuildFrequency} = XNONE ] ) ; then
29
30        IGCM_debug_Print 1 "Asynchronous rebuild has been activated."
31        echo
32
33        case ${config_Post_RebuildFrequency} in
34            *y|*Y)
35                PeriodYear=$( echo ${config_Post_RebuildFrequency} | sed -e "s/[yY]//" )
36                case ${config_UserChoices_PeriodLength} in
37                    *Y|*y)
38                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[yY]//" )
39                        if [ ${PeriodPost} -le ${PeriodYear} ] ; then
40                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} )) % ${PeriodYear}  ) -eq 0 ] ;  then
41                                RebuildFrequency=true
42                                NbRebuildDir=$( expr ${PeriodYear} / ${PeriodPost} )
43                            fi
44                        else
45                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
46                            IGCM_debug_Print 3 "RebuildFrequency frequency : ${config_Post_RebuildFrequency}"
47                        fi ;;
48                    *M|*m)
49                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[mM]//" )
50                        if [ ${PeriodPost} -le $(( ${PeriodYear} * 12 )) ] ; then
51                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} )) % $(( ${PeriodYear} * 12 )) ) -eq 0 ] ; then
52                                RebuildFrequency=true
53                                NbRebuildDir=$( expr $(( 12 * ${PeriodYear} )) / ${PeriodPost} )
54                            fi
55                        else
56                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
57                            IGCM_debug_Print 3 "RebuildFrequency frequency : ${config_Post_RebuildFrequency}"
58                        fi ;;
59                    *D|*d)
60                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[dD]//" )
61                        NbDays=$( IGCM_date_DaysInYear ${year} )
62                        if [ ${config_UserChoices_CalendarType} = 360d ] || [ ${config_UserChoices_CalendarType} = noleap ] ; then
63                            if [ ${PeriodPost} -le $(( ${PeriodYear} * ${NbDays} )) ] ; then
64                                if [ $( expr ${CumulPeriod} % $( expr \( ${NbDays} \* ${PeriodYear} \/ ${PeriodPost} \) ) ) -eq 0 ] ; then
65                                    RebuildFrequency=true
66                                    NbRebuildDir=$( expr $(( ${NbDays} * ${PeriodYear} )) / ${PeriodPost} )
67                                fi
68                            else
69                                IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
70                                IGCM_debug_Print 3 "RebuildFrequency frequency : ${config_Post_RebuildFrequency}"
71                            fi
72                        else
73#                           if [ ${PeriodYear} -eq 1 ] ; then
74#                               PeriodEndJul=$( IGCM_date_ConvertGregorianDateToJulian ${PeriodDateEnd} )
75#                               PostEndJul=${year}${NbDays}
76#                               #echo "PeriodYear=${PeriodYear} NbDays=${NbDays}"
77#                               #echo "PeriodEndJul=${PeriodEndJul} PostEndJul=${PostEndJul}"
78#                               if [ ${PostEndJul} -eq ${PeriodEndJul} ] ; then
79#                                   RebuildFrequency=true
80#                                   NbRebuildDir=$( expr ${NbDays} / ${PeriodPost} )
81#                               fi
82#                           else
83                            IGCM_debug_Print 3 "For RebuildFrequency with leap calendar:"
84                            IGCM_debug_Print 3 "We have a daily PeriodLength frequency and RebuildFrequency=${PeriodYear}Y."
85                            IGCM_debug_Print 3 "No post-treatment. Case not properly handle at this moment."
86#                           fi
87                        fi;;
88                esac ;;
89            *M|*m)
90                PeriodMonth=$( echo ${config_Post_RebuildFrequency} | sed -e "s/[mM]//" )
91                case ${config_UserChoices_PeriodLength} in
92                    *Y|*y)
93                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
94                        IGCM_debug_Print 3 "RebuildFrequency frequency ${config_Post_RebuildFrequency}" ;;
95                    *M|*m)
96                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[mM]//" )
97                        if [ ${PeriodPost} -le ${PeriodMonth} ] ; then
98                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} )) % ${PeriodMonth}  ) -eq 0 ] ;  then
99                                RebuildFrequency=true
100                                NbRebuildDir=$( expr ${PeriodMonth} / ${PeriodPost} )
101                            fi
102                        else
103                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
104                            IGCM_debug_Print 3 "RebuildFrequency frequency : ${config_Post_RebuildFrequency}"
105                        fi ;;
106                    *D|*d)
107                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
108                        IGCM_debug_Print 3 "RebuildFrequency frequency : ${config_Post_RebuildFrequency}" ;;
109                esac
110                ;;
111            *D|*d)
112                PeriodDay=$( echo ${config_Post_RebuildFrequency} | sed -e "s/[dD]//" )
113                case ${config_UserChoices_PeriodLength} in
114                    *Y|*y)
115                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
116                        IGCM_debug_Print 3 "RebuildFrequency frequency ${config_Post_RebuildFrequency}" ;;
117                    *M|*m)
118                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
119                        IGCM_debug_Print 3 "RebuildFrequency frequency ${config_Post_RebuildFrequency}" ;;
120                    *D|*d)
121                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[dD]//" )
122                        if [ ${PeriodPost} -le ${PeriodDay} ] ; then
123                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} )) % ${PeriodDay}  ) -eq 0 ] ;  then
124                                RebuildFrequency=true
125                                NbRebuildDir=$( expr ${PeriodDay} / ${PeriodPost} )
126                            fi
127                        else
128                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
129                            IGCM_debug_Print 3 "RebuildFrequency frequency : ${config_Post_RebuildFrequency}"
130                        fi ;;
131
132                esac
133                ;;
134            NONE|none)
135                ;;
136            *)
137                IGCM_debug_Print 3 "KeyWord not allowed for RebuildFrequency in config.card"
138                ;;
139        esac
140    else
141        #
142        IGCM_debug_Print 1 "Asynchronous rebuild has not been activated"
143        IGCM_debug_Print 1 "Proceed with standard post-treatment pathway"
144        echo
145        #
146    fi
147
148    IGCM_debug_Print 1 "RebuildFrequency flag value : ${RebuildFrequency}"
149    IGCM_post_Initialize
150
151    IGCM_debug_PopStack "IGCM_post_Configure"
152}
153
154function IGCM_post_Initialize
155{
156    IGCM_debug_PushStack "IGCM_post_Initialize"
157
158    # Debug Print :
159    echo
160    IGCM_debug_Print 1 "IGCM_post_Initialize :"
161    echo
162
163    typeset NbDays PeriodEndJul PostEndJul
164    #
165    # Initialize
166    #
167    POST=false
168    TimeSeriesFrequency=false
169    SeasonalFrequency=false
170    #
171    # ONLY IF SOMETHING NEEDS TO BE DONE (EATHER TIME SERIES OR SEASONAL) COMPUTE THE MODULOS
172    #
173    if ( [ X${TimeSeries} = Xtrue ] || [ X${TimeSeries2D} = Xtrue ] || [ X${TimeSeries3D} = Xtrue ] ) ; then
174        list_post=TimeSeriesFrequency
175    fi
176    #
177    if [ X${Seasonal} = Xtrue ] ; then
178        list_post="${list_post} SeasonalFrequency"
179    fi
180    #
181    # READ TIME SERIES OR SEASONAL FREQUENCY
182    # AND TURN ON THE SUBMISSION FLAG WHEN MODULO IS ZERO
183    #
184    for post_freq in ${list_post} ; do
185        #
186        # Extract frequency from previously defined variable
187        #
188        config_Post_post_freq=$( eval echo \${config_Post_${post_freq}} )
189        #
190        # Offset for Seasonal Average starting period
191        #
192        if [ ${post_freq} = SeasonalFrequency ] ; then
193            if ( [ X${config_Post_SeasonalFrequencyOffset} = X${NULL_STR} ] || [ X${config_Post_SeasonalFrequencyOffset} = XNONE ] || [ X${config_Post_SeasonalFrequencyOffset} = X ] ) ; then
194                PeriodOffset=0
195            else
196                PeriodOffset=${config_Post_SeasonalFrequencyOffset}
197            fi
198        else
199            PeriodOffset=0
200        fi
201        #
202        if ( [ X${config_Post_post_freq} = X${NULL_STR} ] || [ X${config_Post_post_freq} = XNONE ] ) ; then
203            #
204            continue
205            #
206        fi
207        #
208        case ${config_Post_post_freq} in
209            *y|*Y)
210                PeriodYear=$( echo ${config_Post_post_freq} | sed -e "s/[yY]//" )
211                #
212                case ${config_UserChoices_PeriodLength} in
213                    *Y|*y)
214                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[yY]//" )
215                        if [ ${PeriodPost} -le ${PeriodYear} ] ; then
216                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} )) % ${PeriodYear} ) -eq 0 ] ;  then
217                                [ $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} )) -ne 0 ] && eval ${post_freq}=true
218                                [ $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} )) -ne 0 ] && POST=true
219                            fi
220                        else
221                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
222                            IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} "
223                        fi ;;
224                    *M|*m)
225                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[mM]//" )
226                        if [ ${PeriodPost} -le $(( ${PeriodYear} * 12 )) ] ; then
227                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} * 12 )) % $(( ${PeriodYear} * 12 )) ) -eq 0 ] ; then
228                                [ $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} * 12 )) -ne 0 ] && eval ${post_freq}=true
229                                [ $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} * 12 )) -ne 0 ] && POST=true
230                            fi
231                        else
232                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
233                            IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} "
234                        fi ;;
235                    *D|*d)
236                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[dD]//" )
237                        NbDays=$( IGCM_date_DaysInYear ${year} )
238                        if [ ${config_UserChoices_CalendarType} = 360d ] | [ ${config_UserChoices_CalendarType} = noleap ] ; then
239                            if [ ${PeriodPost} -le $(( ${PeriodYear} * ${NbDays} )) ] ; then
240                                if [ $( expr $(( ${CumulPeriod} - ( ${PeriodOffset} * ${NbDays} / ${PeriodPost} ) )) % \
241                                    $(( ${NbDays} * ${PeriodYear} / ${PeriodPost} )) ) -eq 0 ] ; then
242                                    [ $(( ${CumulPeriod} - ( ${PeriodOffset} * ${NbDays} / ${PeriodPost} ) )) -ne 0 ] && eval ${post_freq}=true
243                                    [ $(( ${CumulPeriod} - ( ${PeriodOffset} * ${NbDays} / ${PeriodPost} ) )) -ne 0 ] POST=true
244                                fi
245                            else
246                                IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
247                                IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} "
248                            fi
249                        else
250#                                           if [ ${PeriodYear} -eq 1 ] ; then
251#                                               PeriodEndJul=$( IGCM_date_ConvertGregorianDateToJulian ${PeriodDateEnd} )
252#                                               PostEndJul=${year}${NbDays}
253#                                                #echo "PeriodYear=${PeriodYear} NbDays=${NbDays}"
254#                                               #echo PeriodEndJul=${PeriodEndJul} PostEndJul=${PostEndJul}"
255#                                               if [ ${PostEndJul} -le ${PeriodEndJul} ] ; then
256#                                                   eval ${post_freq}=true
257#                                                   POST=true
258#                                               fi
259#                                           else
260                            IGCM_debug_Print 3 "For ${post_freq} with leap calendar, for ${comp} and ${file_in} :"
261                            IGCM_debug_Print 3 "We have a daily PeriodLength frequency and RebuildFrequency=${PeriodYear}Y."
262                            IGCM_debug_Print 3 "No post-treatment. Case not properly handle at this moment."
263#                                           fi
264                        fi;;
265                esac ;;
266            *M|*m)
267                PeriodMonth=$( echo ${config_Post_post_freq} | sed -e "s/[mM]//" )
268                case ${config_UserChoices_PeriodLength} in
269                    *Y|*y)
270                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
271                        IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} " ;;
272                    *M|*m)
273                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[mM]//" )
274                        if [ ${PeriodPost} -le ${PeriodMonth} ] ; then
275                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} -  ${PeriodOffset} )) % ${PeriodMonth}  ) -eq 0 ] ;  then
276                                [ $(( ${CumulPeriod} * ${PeriodPost} -  ${PeriodOffset} )) -ne 0 ] && eval ${post_freq}=true
277                                [ $(( ${CumulPeriod} * ${PeriodPost} -  ${PeriodOffset} )) -ne 0 ] && POST=true
278                            fi
279                        else
280                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
281                            IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} "
282                        fi;;
283                    *D|*d)
284                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
285                        IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} " ;;
286                esac ;;
287            *D|*d)
288                PeriodDay=$( echo ${config_Post_post_freq} | sed -e "s/[dD]//" )
289                case ${config_UserChoices_PeriodLength} in
290                    *Y|*y)
291                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
292                        IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} " ;;
293                    *M|*m)
294                        IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
295                        IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} " ;;
296                    *D|*d)
297                        PeriodPost=$( echo ${config_UserChoices_PeriodLength} | sed -e "s/[dD]//" )
298                        if [ ${PeriodPost} -le ${PeriodDay} ] ; then
299                            if [ $( expr $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} )) % ${PeriodDay}  ) -eq 0 ] ;  then
300                                [ $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} )) -ne 0 ] && eval ${post_freq}=true
301                                [ $(( ${CumulPeriod} * ${PeriodPost} - ${PeriodOffset} )) -ne 0 ] && POST=true
302                            fi
303                        else
304                            IGCM_debug_Print 3 "PeriodLength frequency ${config_UserChoices_PeriodLength} not compatbile with"
305                            IGCM_debug_Print 3 "${flag_post} frequency : ${config_Post_post_freq} "
306                        fi;;
307                esac ;;
308            NONE|none)
309                ;;
310            *)
311                IGCM_debug_Print 3 "KeyWord not allowed for ${post_freq} in config.card"
312                ;;
313        esac
314    done
315    #
316    if ( [ ! X${config_Post_TimeSeriesFrequency} = X${NULL_STR} ] && \
317         [ ! X${config_Post_TimeSeriesFrequency} = XNONE ]        && \
318         [ ${SimulationLengthInDays} -ge ${ExperienceLengthInDays} ] ) ; then
319        TimeSeriesFrequency=true
320        POST=true
321    fi
322
323    if ( [ ! X${config_Post_RebuildFrequency} = X${NULL_STR} ] && \
324         [ ! X${config_Post_RebuildFrequency} = XNONE ]        && \
325         [ ${SimulationLengthInDays} -ge ${ExperienceLengthInDays} ] ) ; then
326        RebuildFrequency=true
327        POST=true
328    fi
329
330    #
331    IGCM_debug_Print 1 "POST-TREATEMENT flag value : ${POST}"
332    #
333    IGCM_post_Submit
334
335    IGCM_debug_PopStack "IGCM_post_Initialize"
336}
337
338function IGCM_post_Submit
339{
340    IGCM_debug_PushStack "IGCM_post_Submit"
341
342    POST_DIR=${R_OUT_POST}/${config_UserChoices_TagName}/${config_UserChoices_JobName}
343
344    if [ ${POST} = true ]; then
345        echo
346        IGCM_debug_Print 1 "IGCM_post_Submit :"
347        echo
348        IGCM_debug_Print 1 "POST_DIR = ${POST_DIR}"
349    fi
350
351    #============ TIME SERIES POST-TREATMENT ===========#
352    if [ ${TimeSeriesFrequency} = true ] ; then
353
354        IGCM_debug_Print 2 "TIME SERIES POST-PROCESSING ACTIVATED :"
355        echo
356
357
358
359        # Get information from last execution
360        IGCM_card_DefineVariableFromOption ${SUBMIT_DIR}/run.card PostProcessing TimeSeriesCompleted
361        CompletedFlag=${run_PostProcessing_TimeSeriesCompleted}
362        #
363
364
365
366        typeset listVarEnv
367        listVarEnv="DEBUG_debug,MODIPSL,libIGCM,libIGCM_SX,SUBMIT_DIR,POST_DIR,MASTER,RebuildFrequency,DateBegin,PeriodDateEnd,StandAlone,CompletedFlag,TsTask,CompToRead,FlagToRead,RESOL_ATM,RESOL_OCE,RESOL_ICE,RESOL_MBG,RESOL_SRF,RESOL_SBG,config_UserChoices_JobName,R_SAVE"
368        #
369        jLoop=${#ListDimension[*]}
370        j=0
371        until [ $j -ge ${jLoop} ]; do
372            Dimension=${ListDimension[${j}]}
373            #
374            if [ X$( eval echo \${TimeSeries${Dimension}} ) = Xtrue ] ; then
375                #
376                IGCM_debug_Print 2 "TIME SERIES POST-PROCESSING ${Dimension} ACTIVATED :"
377                echo
378                #
379                if [ X${Dimension} = X ] ; then
380                    TsTask="empty"
381                else
382                    TsTask=${Dimension}
383                fi
384                #
385                if [ ${RebuildFrequency} = true ] && [ ${DRYRUN} -le 1 ] ; then
386                    #
387                    if [ -f ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh ] ; then
388                        echo "export DEBUG_debug=${DEBUG_debug}            " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
389                        echo "export MODIPSL=${MODIPSL}                    " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
390                        echo "export libIGCM_SX=${libIGCM}                 " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
391                        echo "export libIGCM=${libIGCM_POST}               " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
392                        echo "export SUBMIT_DIR=${SUBMIT_DIR}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
393                        echo "export POST_DIR=${POST_DIR}                  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
394                        echo "export MASTER=${MASTER}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
395                        echo "export RebuildFrequency=${RebuildFrequency}  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
396                        echo "export DateBegin=${DateBegin}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
397                        echo "export PeriodDateEnd=${PeriodDateEnd}        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
398                        echo "export StandAlone=false                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
399                        echo "export CompletedFlag=${CompletedFlag}        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
400                        echo "export TsTask=${TsTask}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
401                        echo "export RESOL_ATM=${RESOL_ATM}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
402                        echo "export RESOL_OCE=${RESOL_OCE}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
403                        echo "export RESOL_ICE=${RESOL_ICE}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
404                        echo "export RESOL_MBG=${RESOL_MBG}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
405                        echo "export RESOL_SRF=${RESOL_SRF}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
406                        echo "export RESOL_SBG=${RESOL_SBG}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
407                        echo "export config_UserChoices_JobName=${config_UserChoices_JobName} " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
408                        echo "export R_SAVE=${R_SAVE}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
409                        echo "export listVarEnv=${listVarEnv}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
410                        echo "IGCM_sys_MkdirWork ${POST_DIR}               " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
411                        echo "IGCM_debug_Verif_Exit                        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
412                        echo "IGCM_sys_QsubPost create_ts                  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
413                    fi
414                    #
415                else
416                    #
417                    IGCM_sys_RshPost <<-EOF
418                    export DEBUG_debug=${DEBUG_debug}
419                    export MODIPSL=${MODIPSL}
420                    export libIGCM_SX=${libIGCM}
421                    export libIGCM=${libIGCM_POST}
422                    export SUBMIT_DIR=${SUBMIT_DIR}
423                    export POST_DIR=${POST_DIR}
424                    export MASTER=${MASTER}
425                    export RebuildFrequency=${RebuildFrequency}
426                    export DateBegin=${DateBegin}
427                    export PeriodDateEnd=${PeriodDateEnd}
428                    export StandAlone=false
429                    export CompletedFlag=${CompletedFlag}
430                    export TsTask=${TsTask}
431                    export RESOL_ATM=${RESOL_ATM}
432                    export RESOL_OCE=${RESOL_OCE}
433                    export RESOL_ICE=${RESOL_ICE}
434                    export RESOL_MBG=${RESOL_MBG}
435                    export RESOL_SRF=${RESOL_SRF}
436                    export RESOL_SBG=${RESOL_SBG}
437                    export config_UserChoices_JobName=${config_UserChoices_JobName}
438                    export R_SAVE=${R_SAVE}
439                    export listVarEnv=${listVarEnv}
440                    . ${libIGCM_POST}/libIGCM_debug/libIGCM_debug.ksh
441                    . ${libIGCM_POST}/libIGCM_sys/libIGCM_sys.ksh
442                    IGCM_sys_MkdirWork ${POST_DIR}
443                    IGCM_debug_Verif_Exit
444                    IGCM_sys_QsubPost create_ts
445EOF
446                fi
447            fi
448            #
449            if [ X$( eval echo \${TimeSeriesChunck${Dimension}} ) = Xtrue ] ; then
450                #
451                IGCM_debug_Print 2 "TIME SERIES POST-PROCESSING ${Dimension} WITH CHUNCK ACTIVATED :"
452                echo
453                # Need to Remember This One
454                SavedDateBegin=${DateBegin}
455                # Kind of task create_ts will perform
456                TsTask=Chunck${Dimension}
457                # Number of chunck jobs to configure and submit
458                eval NbJob=\${#CHUNCK${Dimension}_COMP[@]}
459                typeset i
460                i=0
461                until [ $i -ge $NbJob ]; do
462                    CompToRead=$( eval echo \${CHUNCK${Dimension}_COMP[\${i}]} )
463                    FlagToRead=$( eval echo \${CHUNCK${Dimension}_FLAG[\${i}]} )
464                    ChunckSize=$( eval echo \${CHUNCK${Dimension}_SIZE[\${i}]} )
465                    # Chunck Length (mandatory in Year)
466                    YearsChunckLength=$( echo ${ChunckSize} | sed -e "s/[yY]//" )
467                    #
468                    IGCM_date_GetYearMonth ${DateBegin}     YearBegin MonthBegin
469                    #
470                    IGCM_date_GetYearMonth ${PeriodDateEnd} YearEnd   MonthEnd
471                    # How many chunck in total since simulation began
472                    NbYearsChunckLoop=$(( ( ${YearEnd} - ${YearBegin} + 1 ) / ${YearsChunckLength} ))
473                    #  Tweak special case
474                    [ $(( ( ${YearEnd} - ${YearBegin} + 1 ) % ${YearsChunckLength} )) = 0 ] && NbYearsChunckLoop=$(( ${NbYearsChunckLoop} - 1 ))
475                    # Starting Year of the current chunck
476                    ChunckTsYearBegin=$(( ${NbYearsChunckLoop} *  ${YearsChunckLength} + ${YearBegin} ))
477                    # Starting date of the current chunck
478                    ChunckTsDateBegin=${ChunckTsYearBegin}${MonthBegin}01
479                    #
480                    if [ ${RebuildFrequency} = true ] && [ ${DRYRUN} -le 1 ] ; then
481                        #
482                        if [ -f ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh ] ; then
483                            echo "export DEBUG_debug=${DEBUG_debug}            " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
484                            echo "export MODIPSL=${MODIPSL}                    " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
485                            echo "export libIGCM_SX=${libIGCM}                 " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
486                            echo "export libIGCM=${libIGCM_POST}               " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
487                            echo "export SUBMIT_DIR=${SUBMIT_DIR}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
488                            echo "export POST_DIR=${POST_DIR}                  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
489                            echo "export MASTER=${MASTER}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
490                            echo "export RebuildFrequency=${RebuildFrequency}  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
491                            echo "export DateBegin=${ChunckTsDateBegin}        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
492                            echo "export PeriodDateEnd=${PeriodDateEnd}        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
493                            echo "export StandAlone=false                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
494                            echo "export CompletedFlag=${CompletedFlag}        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
495                            echo "export TsTask=${TsTask}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
496                            echo "export CompToRead=${CompToRead}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
497                            echo "export FlagToRead=${FlagToRead}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
498                            echo "export RESOL_ATM=${RESOL_ATM}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
499                            echo "export RESOL_OCE=${RESOL_OCE}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
500                            echo "export RESOL_ICE=${RESOL_ICE}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
501                            echo "export RESOL_MBG=${RESOL_MBG}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
502                            echo "export RESOL_SRF=${RESOL_SRF}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
503                            echo "export RESOL_SBG=${RESOL_SBG}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
504                            echo "export config_UserChoices_JobName=${config_UserChoices_JobName} " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
505                            echo "export R_SAVE=${R_SAVE}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
506                            echo "export listVarEnv=${listVarEnv}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
507                            echo "IGCM_sys_MkdirWork ${POST_DIR}               " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
508                            echo "IGCM_debug_Verif_Exit                        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
509                            echo "IGCM_sys_QsubPost create_ts                  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
510                        fi
511                        #
512                    else
513                        #
514                        IGCM_sys_RshPost <<-EOF
515                        export DEBUG_debug=${DEBUG_debug}
516                        export MODIPSL=${MODIPSL}
517                        export libIGCM_SX=${libIGCM}
518                        export libIGCM=${libIGCM_POST}
519                        export SUBMIT_DIR=${SUBMIT_DIR}
520                        export POST_DIR=${POST_DIR}
521                        export MASTER=${MASTER}
522                        export RebuildFrequency=${RebuildFrequency}
523                        export DateBegin=${ChunckTsDateBegin}
524                        export PeriodDateEnd=${PeriodDateEnd}
525                        export StandAlone=false
526                        export CompletedFlag=${CompletedFlag}
527                        export TsTask=${TsTask}
528                        export CompToRead=${CompToRead}
529                        export FlagToRead=${FlagToRead}
530                        export RESOL_ATM=${RESOL_ATM}
531                        export RESOL_OCE=${RESOL_OCE}
532                        export RESOL_ICE=${RESOL_ICE}
533                        export RESOL_MBG=${RESOL_MBG}
534                        export RESOL_SRF=${RESOL_SRF}
535                        export RESOL_SBG=${RESOL_SBG}
536                        export config_UserChoices_JobName=${config_UserChoices_JobName}
537                        export R_SAVE=${R_SAVE}
538                        export listVarEnv=${listVarEnv}
539                        . ${libIGCM_POST}/libIGCM_debug/libIGCM_debug.ksh
540                        . ${libIGCM_POST}/libIGCM_sys/libIGCM_sys.ksh
541                        IGCM_sys_MkdirWork ${POST_DIR}
542                        IGCM_debug_Verif_Exit
543                        IGCM_sys_QsubPost create_ts
544EOF
545                        #
546                    fi
547                    #
548                    export DateBegin=${SavedDateBegin}
549                    #
550                    (( i=i+1 ))
551                    #
552                done
553            fi
554            (( j=j+1 ))
555        done
556    fi
557
558    #=============  SEASONAL POST-TREATMENT ============#
559    if [ ${SeasonalFrequency} = true ] ; then
560        #
561        IGCM_debug_Print 2 "SEASONNAL POST-TREATMENT :"
562        echo
563        #
564        typeset listVarEnv
565        listVarEnv="DEBUG_debug,MODIPSL,libIGCM,libIGCM_SX,SUBMIT_DIR,POST_DIR,MASTER,RebuildFrequency,DateBegin,PeriodDateEnd,StandAlone,RESOL_ATM,RESOL_OCE,RESOL_ICE,RESOL_MBG,RESOL_SRF,RESOL_SBG,config_UserChoices_JobName,R_SAVE"
566
567        if [ ${RebuildFrequency} = true ] && [ ${DRYRUN} -le 1 ] ; then
568            #
569            echo "export DEBUG_debug=${DEBUG_debug}            " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
570            echo "export MODIPSL=${MODIPSL}                    " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
571            echo "export libIGCM_SX=${libIGCM}                 " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
572            echo "export libIGCM=${libIGCM_POST}               " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
573            echo "export SUBMIT_DIR=${SUBMIT_DIR}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
574            echo "export POST_DIR=${POST_DIR}                  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
575            echo "export MASTER=${MASTER}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
576            echo "export RebuildFrequency=${RebuildFrequency}  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
577            echo "export DateBegin=${DateBegin}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
578            echo "export PeriodDateEnd=${PeriodDateEnd}        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
579            echo "export StandAlone=false                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
580            echo "export RESOL_ATM=${RESOL_ATM}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
581            echo "export RESOL_OCE=${RESOL_OCE}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
582            echo "export RESOL_ICE=${RESOL_ICE}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
583            echo "export RESOL_MBG=${RESOL_MBG}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
584            echo "export RESOL_SRF=${RESOL_SRF}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
585            echo "export RESOL_SBG=${RESOL_SBG}                " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
586            echo "export config_UserChoices_JobName=${config_UserChoices_JobName} " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
587            echo "export R_SAVE=${R_SAVE}                      " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
588            echo "export listVarEnv=${listVarEnv}              " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
589            echo "IGCM_sys_MkdirWork ${POST_DIR}               " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
590            echo "IGCM_debug_Verif_Exit                        " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
591            echo "IGCM_sys_QsubPost create_se                  " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
592            #
593        else
594            #
595            IGCM_sys_RshPost <<-EOF
596            export DEBUG_debug=${DEBUG_debug}
597            export MODIPSL=${MODIPSL}
598            export libIGCM_SX=${libIGCM}
599            export libIGCM=${libIGCM_POST}
600            export SUBMIT_DIR=${SUBMIT_DIR}
601            export POST_DIR=${POST_DIR}
602            export MASTER=${MASTER}
603            export RebuildFrequency=${RebuildFrequency}
604            export DateBegin=${DateBegin}
605            export PeriodDateEnd=${PeriodDateEnd}
606            export StandAlone=false
607            export RESOL_ATM=${RESOL_ATM}
608            export RESOL_OCE=${RESOL_OCE}
609            export RESOL_ICE=${RESOL_ICE}
610            export RESOL_MBG=${RESOL_MBG}
611            export RESOL_SRF=${RESOL_SRF}
612            export RESOL_SBG=${RESOL_SBG}
613            export config_UserChoices_JobName=${config_UserChoices_JobName}
614            export R_SAVE=${R_SAVE}
615            export listVarEnv=${listVarEnv}
616            . ${libIGCM_POST}/libIGCM_debug/libIGCM_debug.ksh
617            . ${libIGCM_POST}/libIGCM_sys/libIGCM_sys.ksh
618            IGCM_sys_MkdirWork ${POST_DIR}
619            IGCM_debug_Verif_Exit
620            IGCM_sys_QsubPost create_se
621EOF
622        #
623        fi
624    fi
625
626    #============== REBUILD POST-TREATMENT =============#
627    if ( [ ! X${config_Post_RebuildFrequency} = X${NULL_STR} ] && [ ! X${config_Post_RebuildFrequency} = XNONE ] ) ; then
628        # -----------------------------------------------------------------------------------
629        # Function IGCM_FlushRebuild define in rebuild.ksh has not been closed yet. Do it now
630        # -----------------------------------------------------------------------------------
631        if [ ${DRYRUN} -le 1 ] ; then
632            echo "IGCM_debug_PopStack \"IGCM_FlushRebuild\" " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
633            echo "}                                       " >> ${RUN_DIR}/REBUILD_${PeriodDateBegin}/rebuild.ksh
634        fi
635        if [ ${config_Post_RebuildFromArchive} = true ] ; then
636            IGCM_sys_Put_Dir REBUILD_${PeriodDateBegin} ${REBUILD_DIR}
637        else
638            IGCM_sys_Mv      REBUILD_${PeriodDateBegin} ${REBUILD_DIR}
639        fi
640    fi
641    #
642    if [ ${RebuildFrequency} = true ] ; then
643        #
644        if ( [ ${config_Post_RebuildFromArchive} = true ] ) ; then
645            #
646            IGCM_debug_Print 2 "REBUILD POST-TREATMENT FROM ARCHIVE:"
647            echo
648            #
649            typeset listVarEnv
650            listVarEnv="DEBUG_debug,MODIPSL,libIGCM,libIGCM_SX,SUBMIT_DIR,REBUILD_DIR,POST_DIR,MASTER,RebuildFromArchive,DateBegin,PeriodDateBegin,PeriodDateEnd,NbRebuildDir,StandAlone,RESOL_ATM,RESOL_OCE,RESOL_ICE,RESOL_MBG,RESOL_SRF,RESOL_SBG,config_UserChoices_JobName,R_SAVE"
651            IGCM_sys_RshPost <<-EOF
652            export DEBUG_debug=${DEBUG_debug}
653            export MODIPSL=${MODIPSL}
654            export libIGCM_SX=${libIGCM}
655            export libIGCM=${libIGCM_POST}
656            export SUBMIT_DIR=${SUBMIT_DIR}
657            export REBUILD_DIR=${REBUILD_DIR}
658            export POST_DIR=${POST_DIR}
659            export MASTER=${MASTER}
660            export RebuildFromArchive=${config_Post_RebuildFromArchive}
661            export DateBegin=${DateBegin}
662            export PeriodDateBegin=${PeriodDateBegin}
663            export PeriodDateEnd=${PeriodDateEnd}
664            export NbRebuildDir=${NbRebuildDir}
665            export StandAlone=false
666            export RESOL_ATM=${RESOL_ATM}
667            export RESOL_OCE=${RESOL_OCE}
668            export RESOL_ICE=${RESOL_ICE}
669            export RESOL_MBG=${RESOL_MBG}
670            export RESOL_SRF=${RESOL_SRF}
671            export RESOL_SBG=${RESOL_SBG}
672            export config_UserChoices_JobName=${config_UserChoices_JobName}
673            export R_SAVE=${R_SAVE}
674            export listVarEnv=${listVarEnv}
675            . ${libIGCM_POST}/libIGCM_debug/libIGCM_debug.ksh
676            . ${libIGCM_POST}/libIGCM_sys/libIGCM_sys.ksh
677            IGCM_sys_MkdirWork ${POST_DIR}
678            IGCM_debug_Verif_Exit
679            IGCM_sys_QsubPost rebuild_fromArchive
680EOF
681        else
682            #
683            IGCM_debug_Print 2 "REBUILD POST-TREATMENT FROM WORKDIR:"
684            echo
685            #
686            typeset listVarEnv
687            listVarEnv="DEBUG_debug,MODIPSL,libIGCM,libIGCM_SX,SUBMIT_DIR,REBUILD_DIR,POST_DIR,MASTER,RebuildFromArchive,DateBegin,PeriodDateBegin,PeriodDateEnd,NbRebuildDir,StandAlone,RESOL_ATM,RESOL_OCE,RESOL_ICE,RESOL_MBG,RESOL_SRF,RESOL_SBG,config_UserChoices_JobName,R_SAVE"
688            IGCM_sys_RshPost <<-EOF
689            export DEBUG_debug=${DEBUG_debug}
690            export MODIPSL=${MODIPSL}
691            export libIGCM_SX=${libIGCM}
692            export libIGCM=${libIGCM_POST}
693            export SUBMIT_DIR=${SUBMIT_DIR}
694            export REBUILD_DIR=${REBUILD_DIR}
695            export POST_DIR=${POST_DIR}
696            export MASTER=${MASTER}
697            export RebuildFromArchive=${config_Post_RebuildFromArchive}
698            export DateBegin=${DateBegin}
699            export PeriodDateBegin=${PeriodDateBegin}
700            export PeriodDateEnd=${PeriodDateEnd}
701            export NbRebuildDir=${NbRebuildDir}
702            export StandAlone=false
703            export RESOL_ATM=${RESOL_ATM}
704            export RESOL_OCE=${RESOL_OCE}
705            export RESOL_ICE=${RESOL_ICE}
706            export RESOL_MBG=${RESOL_MBG}
707            export RESOL_SRF=${RESOL_SRF}
708            export RESOL_SBG=${RESOL_SBG}
709            export config_UserChoices_JobName=${config_UserChoices_JobName}
710            export R_SAVE=${R_SAVE}
711            export listVarEnv=${listVarEnv}
712            . ${libIGCM_POST}/libIGCM_debug/libIGCM_debug.ksh
713            . ${libIGCM_POST}/libIGCM_sys/libIGCM_sys.ksh
714            IGCM_sys_MkdirWork ${POST_DIR}
715            IGCM_debug_Verif_Exit
716            IGCM_sys_QsubPost rebuild_fromWorkdir
717EOF
718        fi
719    fi
720
721    IGCM_debug_PopStack "IGCM_post_Submit"
722}
Note: See TracBrowser for help on using the repository browser.