source: CMIP6/DAMIP/CM61-LR-hist-GHG-03.2150/POST2/TimeSeries_Checker.job

Last change on this file was 4486, checked in by ggalod, 5 years ago

sauvegarde exp DAMIP

File size: 21.6 KB
Line 
1#!/bin/ksh
2
3#**************************************************************
4# Author: Sebastien Denvil
5# Contact: Sebastien.Denvil__at__ipsl.jussieu.fr
6# $Revision:: 1437                                     $ Revision of last commit
7# $Author:: jgipsl                                     $ Author of last commit
8# $Date:: 2018-04-11 18:15:06 +0200 (Wed, 11 Apr 2018) $ Date of last commit
9# IPSL (2006)
10#  This software is governed by the CeCILL licence see libIGCM/libIGCM_CeCILL.LIC
11#
12#**************************************************************
13# ID of your genci project. Curie only : post-processing jobs need it to run properly
14export BRIDGE_MSUB_PROJECT=daacmip6
15
16#D- Task type DO NOT CHANGE (computing, post-processing or checking)
17TaskType=checking
18
19#D- Low level debug : to perform lib test checks, stack construction and IO functions instrumentation
20DEBUG_debug=false
21
22#D- Messaging : all activities and call stacks will be sent to ipsl servers
23BigBrother=false
24
25# Check that everything went well during time series production
26# Display a short report
27# Launch what's missing
28# For use during a run (not on the end : PeriodState=Completed), it will complete
29# all TS to last PeriodDateEnd value, give by run.card->Configuration->(PeriodDateBegin - 1).
30
31#D- Path to libIGCM
32#D- Default : value from AA_job if any
33libIGCM=${libIGCM:=/ccc/cont003/dsku/perle2/home/app/gencmip6/p86ggas/DAMIP/modipsl_060918/modipsl/libIGCM}
34
35# répertoire courrant
36CURRENT_DIR=$( pwd )
37
38# Emplacement des cartes
39CARD_DIR=${CARD_DIR:=${CURRENT_DIR}}
40
41# répertoire de stockage des sorties des create_ts
42POST_DIR=${POST_DIR:=${CARD_DIR}/OutScript}
43
44if [ ! -d ${CARD_DIR} ]; then
45  echo "No ${CARD_DIR}, we stop here"
46  exit
47fi
48
49########################################################################
50
51. ${libIGCM}/libIGCM_debug/libIGCM_debug.ksh
52. ${libIGCM}/libIGCM_card/libIGCM_card.ksh
53. ${libIGCM}/libIGCM_date/libIGCM_date.ksh
54#-------
55. ${libIGCM}/libIGCM_sys/libIGCM_sys.ksh
56. ${libIGCM}/libIGCM_config/libIGCM_config.ksh
57#-------
58( ${DEBUG_debug} ) && IGCM_debug_Check
59( ${DEBUG_debug} ) && IGCM_card_Check
60( ${DEBUG_debug} ) && IGCM_date_Check
61
62########################################################################
63
64#set -vx
65
66echo "Hi I'm here to help you complete the time series production you planned according to your *.card."
67echo "This action can potentially submit numbers of jobs (up to 50)"
68echo "This action can potentially remove unnecessary files but I will ALWAYS ask permission to do so"
69echo -e "\033[1;31mDo you want me to run in dryrun mode just telling what I would submit?\033[m"
70echo -e "\033[1;31mOr do you want me to submit job for real? Answer yes in this case.\033[m"
71echo -n " Run for real (y/n) :"
72read ActionAnswer
73
74case ${ActionAnswer} in
75oui|OUI|o|y|yes|YES)
76  echo "OK. I will submit jobs but ask permissions before removing files"
77  action=true
78  ;;
79non|NON|n|no|NO)
80  echo "OK. I won't submit jobs and only print out files I could remove"
81  action=false
82  ;;
83*)
84  echo "I did not recognize your answer. I will stop here."
85  echo "Please respond: oui|OUI|o|y|yes|YES"
86  echo "Or please respond: non|NON|n|no|NO"
87  exit
88  ;;
89esac
90
91#==================================
92# First of all
93#
94# Read libIGCM compatibility version in config.card
95# Read UserChoices section
96# Read Ensemble section
97# Read Post section
98# Define all netcdf output directories
99#==================================
100IGCM_config_CommonConfiguration ${CARD_DIR}/config.card
101
102#==================================
103# Read ListOfComponents section:
104IGCM_card_DefineArrayFromSection ${CARD_DIR}/config.card ListOfComponents
105
106if [ -f ${CARD_DIR}/run.card ] ; then
107  IGCM_card_DefineVariableFromOption ${CARD_DIR}/run.card Configuration PeriodState
108  IGCM_card_DefineVariableFromOption ${CARD_DIR}/run.card Configuration PeriodDateBegin
109  IGCM_card_DefineVariableFromOption ${CARD_DIR}/run.card PostProcessing TimeSeriesCompleted
110  IGCM_debug_Print 1 "DefineVariableFromOption  : run_Configuration"
111  IGCM_debug_PrintVariables 3 run_Configuration_PeriodState
112  IGCM_debug_Print 1 "DefineVariableFromOption  : run_PostProcessing"
113  IGCM_debug_PrintVariables 3 run_PostProcessing_TimeSeriesCompleted
114  if [ X${run_Configuration_PeriodState} != X"Completed" ] ; then
115    DateEnd=$( IGCM_date_AddDaysToGregorianDate $( IGCM_date_ConvertFormatToGregorian ${run_Configuration_PeriodDateBegin} ) -1 )
116  else
117    DateEnd=$( IGCM_date_ConvertFormatToGregorian ${config_UserChoices_DateEnd} )
118  fi
119  CompletedFlag=${run_PostProcessing_TimeSeriesCompleted}
120else
121  DateEnd=$( IGCM_date_ConvertFormatToGregorian ${config_UserChoices_DateEnd} )
122  CompletedFlag=""
123fi
124SavedCompletedFlag=${CompletedFlag}
125DateBegin=$( IGCM_date_ConvertFormatToGregorian ${config_UserChoices_DateBegin} )
126
127IGCM_date_GetYearMonth ${DateBegin} YearBegin MonthBegin
128IGCM_date_GetYearMonth ${DateEnd}   YearEnd   MonthEnd
129
130echo
131IGCM_debug_Print 1 "DateBegin for TimeSeries_Checker : "${DateBegin}
132IGCM_debug_Print 1 "DateEnd   for TimeSeries_Checker : "${DateEnd}
133IGCM_debug_Print 1 "CompletedFlag = "${CompletedFlag}
134echo
135
136for comp in ${config_ListOfComponents[*]} ; do
137  # Debug Print
138  IGCM_debug_Print 1 ${comp}
139  # Define component
140  IGCM_card_DefineArrayFromOption ${CARD_DIR}/config.card ListOfComponents ${comp}
141  eval compname=\${config_ListOfComponents_${comp}[0]} > /dev/null 2>&1
142  eval comptagname=\${config_ListOfComponents_${comp}[1]} > /dev/null 2>&1
143
144  # Read libIGCM compatibility version in ${compname}.card
145  card=${CARD_DIR}/COMP/${compname}.card
146
147  # Read and Build Output File stuff
148  #IGCM_debug_Print 1 "DefineArrayFromOption  : ${compname}_OutputFiles ${card}"
149  IGCM_card_DefineArrayFromOption ${card} OutputFiles List
150  ListFilesName=${compname}_OutputFiles_List
151  eval FileName0=\${${ListFilesName}[0]} > /dev/null 2>&1
152  #
153  if [ X${FileName0} != X${NULL_STR} ] ; then
154    #
155    #IGCM_debug_Print 1 "Component      : ${compname}"
156    #
157    # INITIALISATION
158    #
159    eval NbFiles=\${#${ListFilesName}[@]} > /dev/null 2>&1
160    i=2
161    #
162    until [ $i -ge $NbFiles ]; do
163      #
164      eval flag_post=\${${ListFilesName}[$i]} > /dev/null 2>&1
165      #
166      if [ X${flag_post} != XNONE ] ; then
167        #
168        # First of all
169        #
170        IGCM_card_DefineArrayFromSection ${card} ${flag_post}
171        #
172        IGCM_card_DefineArrayFromOption ${card} ${flag_post} TimeSeriesVars
173        IGCM_card_DefineArrayFromOption ${card} ${flag_post} Patches
174        if [ X"$( eval echo \${${compname}_${flag_post}_TimeSeriesVars[*]} )" = X"Option not" ] ; then
175          # New TimeSeriesVar description, with 2D, 3D and associate ChunckJob.
176          unset ListDimension
177          ListDimension[0]=2D
178          ListDimension[1]=3D
179          TimeSeries=false
180          TimeSeries2D=false
181          TimeSeries3D=false
182          chunck=false
183          iLoop=${#ListDimension[*]}
184          j=0
185          until [ $j -ge ${iLoop} ]; do
186            Dimension=${ListDimension[${j}]}
187            IGCM_card_DefineArrayFromOption ${card} ${flag_post} TimeSeriesVars${Dimension}
188            IGCM_card_DefineVariableFromOption ${card} ${flag_post} ChunckJob${Dimension}
189            #
190            # Time series WITHOUT chunk
191            #
192            if [ ! $( eval echo \${${compname}_${flag_post}_TimeSeriesVars${Dimension}} ) = ${NULL_STR} ] ; then
193              if [ $( eval echo \${${compname}_${flag_post}_ChunckJob${Dimension}} ) = NONE ] ; then
194                IGCM_debug_Print 2 "${Dimension} time series activated for ${flag_post}"
195                eval TimeSeries${Dimension}=true
196                chunck=false
197              fi
198            fi
199            #
200            # Time series WITH chunk
201            #
202            if [ ! $( eval echo \${${compname}_${flag_post}_TimeSeriesVars${Dimension}} ) = ${NULL_STR} ] ; then
203              chunck_size=$( eval echo \${${compname}_${flag_post}_ChunckJob${Dimension}} )
204              if [ ! ${chunck_size} = NONE ] &&  [ ! ${chunck_size} = OFF ] ; then
205                IGCM_debug_Print 2 "${Dimension} time series activated with ${chunck_size} chunck for ${flag_post}"
206                eval TimeSeriesChunck${Dimension}=true
207                chunck=true
208              fi
209            fi
210            (( j=j+1 ))
211            #
212            # If TimeSeriesVars list is empty or OFF we skip
213            #
214            if ( [ $( eval echo \${${compname}_${flag_post}_TimeSeriesVars${Dimension}} ) = ${NULL_STR} ] || \
215              [ ${chunck_size} = OFF ] ) ; then
216              #IGCM_debug_Print 2 "Empty TS : ${compname}_Post_${FILE}_TimeSeriesVars${Dimension}"
217              #(( i=i+3 ))
218              continue
219            fi
220            #
221            #  ICI ON TESTE QUE LES FICHIERS TS SONT LA!
222            #
223            FILE=$( echo ${flag_post} | awk "-FPost_" '{print $2}' )
224            IGCM_card_DefineArrayFromOption ${card}    Post_${FILE} TimeSeriesVars${Dimension}
225            IGCM_card_DefineVariableFromOption ${card} Post_${FILE} ChunckJob${Dimension}
226            #
227            FlagDir=$( echo ${FILE} | awk -F "_" '{print $1}' )
228            case ${FlagDir} in
229            *Y)  TS_Dir=TS_YE  ;;
230            *M)  TS_Dir=TS_MO  ;;
231            *D)  TS_Dir=TS_DA  ;;
232            3H|HF)  TS_Dir=TS_HF  ;;
233            INS) TS_Dir=TS_INS ;;
234            esac
235            #
236            # We need LIST of variables not allready produced (useful for standalone mode)
237            #
238            DateBegin=$( IGCM_date_ConvertFormatToGregorian ${config_UserChoices_DateBegin} )
239            IGCM_date_GetYearMonth ${DateBegin} YearBegin MonthBegin
240
241            # Si on n'a pas de chunck, dans ce cas chunck_size=la durée de la simulation en années
242            YearsChunckLength=$( echo ${chunck_size} | sed -e "s/[yY]//" )
243            [ ${chunck} = false ] && YearsChunckLength=$(( YearEnd - YearBegin + 1 ))
244
245            NbYearsChunckLoop=$(( ( YearEnd - YearBegin + 1 ) / YearsChunckLength ))
246            Reste=$(( ( YearEnd - YearBegin + 1 ) % YearsChunckLength ))
247
248            if [ ${Reste} -ne 0 ] ; then
249              NbYearsChunckLoop=$(( NbYearsChunckLoop + 1 ))
250            fi
251
252            if [ ${NbYearsChunckLoop} -eq 1 ] ; then
253              PeriodDateEnd=${DateEnd}
254            else
255              Length=$( IGCM_date_DaysInCurrentPeriod ${DateBegin} ${YearsChunckLength}Y )
256              PeriodDateEnd=$( IGCM_date_AddDaysToGregorianDate ${DateBegin} ${Length}-1 )
257            fi
258            #
259            DIRECTORY=${R_SAVE}/${comp}/Analyse/${TS_Dir}
260            YearsChunckLoop=1
261            ChunckDebut=${DateBegin}
262            ChunckFin=${PeriodDateEnd}
263            while [ ${YearsChunckLoop} -le ${NbYearsChunckLoop} ] ; do
264              countTotal=0
265              countGood=0
266              countBad=0
267              unset RemoveList
268              unset PotentialCompletedFlag
269              for var in $( eval echo \${${compname}_Post_${FILE}_TimeSeriesVars${Dimension}[*]} ) ; do
270                TestedFile=${config_UserChoices_JobName}_${ChunckDebut}_${ChunckFin}_${FlagDir}_${var}.nc
271                #
272                DEBUG_sys=false IGCM_sys_TestDirArchive ${DIRECTORY}
273                if [ $? = 0 ] ; then
274                  Candidat=$( find ${DIRECTORY} -name "${config_UserChoices_JobName}_${ChunckDebut}_*_${FlagDir}_${var}.nc" )
275                else
276                  Candidat=""
277                fi
278                #
279                BestCandidat=${ChunckDebut}
280                #
281                FoundCandidat=false
282                if [ ! "X${Candidat}" = "X" ] ; then
283                  for candid in ${Candidat} ; do
284                    #IGCM_debug_Print 1 -e "\033[1;32m[CompletedFlag CANDIDAT MATCH FOUND]\033[m $( basename ${candid} )"
285                    CandidatEnd=$( echo ${candid}   | awk -F${config_UserChoices_JobName} '{print $3}' | awk -F_ '{print $3}' )
286                    if [ ${CandidatEnd} -gt ${ChunckFin} ] ; then
287                      #IGCM_debug_Print 3 -e "File $( basename ${candid} ) should be suppress"
288                      set +A RemoveList ${RemoveList[*]} ${candid}
289                    elif [ ${CandidatEnd} -lt ${ChunckFin} ] ; then
290                      #IGCM_debug_Print 3 -e "File $( basename ${candid} ) should be suppress or used as a CompletedFlag baseline"
291                      # We keep the best candidat and remove the others
292                      if [ ${BestCandidat} -lt ${CandidatEnd} ] ; then
293                        if [ ${FoundCandidat} = true ] ; then
294                          set +A RemoveList ${RemoveList[*]} ${DIRECTORY}/${config_UserChoices_JobName}_${ChunckDebut}_${BestCandidat}_${FlagDir}_${var}.nc
295                        else
296                          FoundCandidat=true
297                        fi
298                        BestCandidat=${CandidatEnd}
299                      else
300                        set +A RemoveList ${RemoveList[*]} ${candid}
301                      fi
302                    fi
303                  done
304                else
305                  # No CompletedFlag candidat found
306                  CandidatCompletedFlag=""
307                fi
308                #
309                if [ ! -f ${DIRECTORY}/${TestedFile} ] ; then
310                  (( countBad = countBad + 1 ))
311                  [ ${countBad} = 1 ] && IGCM_debug_Print 3 "Missing time series from ${FILE} in ${DIRECTORY} :"
312                  IGCM_debug_Print 3 ${TestedFile}
313                  # Then we keep a track of the Best Candidat
314                  if [ ${FoundCandidat} = true ] ; then
315                    if [ ${chunck} = true ] ; then
316                      set +A PotentialCompletedFlag ${PotentialCompletedFlag[*]} ${BestCandidat}
317                    else
318                      eval set +A PotentialCompletedFlag${Dimension} \${PotentialCompletedFlag${Dimension}[*]} \${BestCandidat}
319                    fi
320                  fi
321                else
322                  (( countGood = countGood + 1 ))
323                  # Then we do not need the best candidat if any
324                  [ ${FoundCandidat} = true ] && set +A RemoveList ${RemoveList[*]} ${DIRECTORY}/${config_UserChoices_JobName}_${ChunckDebut}_${BestCandidat}_${FlagDir}_${var}.nc
325                fi
326                (( countTotal = countTotal + 1 ))
327              done
328
329              SuccessRate=$(( countGood * 100 / countTotal ))
330              if [ ${SuccessRate} -ne 100 ] ; then
331                IGCM_debug_Print 2 -e "\033[1;31m${SuccessRate}% files OK.\033[m for period ${ChunckDebut}-${ChunckFin}"
332              else
333                IGCM_debug_Print 2 -e "\033[1;32m${SuccessRate}% files OK.\033[m for period ${ChunckDebut}-${ChunckFin}"
334              fi
335              echo
336
337              # Remove what's in the RemoveList
338              if [ ${RemoveList} ] ; then
339                IGCM_debug_Print 2 "File(s) that will be removed ${RemoveList[*]}"
340                if [ ${action} = true ] ; then
341                  echo -e "\033[1;32mDo you want to remove them?\033[m"
342                  echo -n " Your answer (y/n) : "
343                  read RemoveAnswer
344                  case ${RemoveAnswer} in
345                  oui|OUI|o|y|yes|YES)
346                    echo "OK. I will erase them"
347                    IGCM_sys_Rm -f ${RemoveList[*]}
348                    ;;
349                  non|NON|n|no|NO)
350                    echo "OK. I won't erase them"
351                    ;;
352                  *)
353                    echo "I did not recognize your answer."
354                    echo "Please respond: oui|OUI|o|y|yes|YES"
355                    echo "Or please respond: non|NON|n|no|NO"
356                    exit
357                    ;;
358                  esac
359                fi
360              fi
361              #[ ${FoundCandidat} = true ] && IGCM_debug_Print 2 "Potentials CompletedFlag: ${PotentialCompletedFlag[*]}"
362              #
363              # TO REWRITE BEGIN
364              #
365              if ( [ ${chunck} = true ] && [ ${SuccessRate} -ne 100 ] ) ; then
366                NbCandidats=${#PotentialCompletedFlag[@]}
367                countCandid=1
368                if [ ${NbCandidats} -eq 0 ] ; then
369                  ChunckCompletedFlag=""
370                  IGCM_debug_Print 2 -e "\033[1;31mNO CompletedFlag\033[m"
371                elif [ ${NbCandidats} -eq 1 ] ; then
372                  ChunckCompletedFlag=${PotentialCompletedFlag[0]}
373                  IGCM_debug_Print 2 -e "\033[1;32mCompletedFlag=${ChunckCompletedFlag}\033[m"
374                elif [ ${NbCandidats} -gt 1 ] ; then
375                  k=1
376                  until [ $k -ge ${NbCandidats} ]; do
377                    ((k_m1=k-1))
378                    if [ ${PotentialCompletedFlag[${k_m1}]} = ${PotentialCompletedFlag[${k}]} ] ; then
379                      ((countCandid=countCandid+1))
380                    fi
381                    ((k=k+1))
382                  done
383                  if [ ${NbCandidats} -eq ${countCandid} ] ; then
384                    ChunckCompletedFlag=${PotentialCompletedFlag[0]}
385                    IGCM_debug_Print 2 -e "\033[1;32mCompletedFlag=${ChunckCompletedFlag}\033[m"
386                  else
387                    ChunckCompletedFlag=${PotentialCompletedFlag[0]}
388                    IGCM_debug_Print 2 -e "\033[1;31mToo Many Potential CompletedFlag\033[m Let start with first CompletedPeriod"
389                    IGCM_debug_Print 2 -e "\033[1;31mYou will have to redo TimeSeries_Checker\033[m for other period."
390                  fi
391                fi
392                #
393                # TO REWRITE END
394                #
395                if [ ${action} = true ] ; then
396                  IGCM_debug_Print 2 -e "\033[1;31mSubmit ${FILE} chunck ${Dimension}\033[m period ${ChunckDebut}-${ChunckFin} and CompletedFlag=${ChunckCompletedFlag}"
397                  listVarEnv="DEBUG_debug,BigBrother,libIGCM,SUBMIT_DIR,POST_DIR,Script_Post_Output,DateBegin,PeriodDateEnd,CompletedFlag,TsTask,CompToRead,FlagToRead"
398                  export DEBUG_debug=${DEBUG_debug}
399                  export BigBrother=${BigBrother}
400                  export libIGCM=${libIGCM}
401                  export SUBMIT_DIR=${CARD_DIR}
402                  export POST_DIR=${POST_DIR}
403                  export DateBegin=${ChunckDebut}
404                  export PeriodDateEnd=${ChunckFin}
405                  export CompletedFlag=${ChunckCompletedFlag}
406                  export TsTask=Chunck${Dimension}
407                  export CompToRead=${comp}
408                  export FlagToRead=${i}
409                  export NameToRead=${flag_post}
410                  export listVarEnv=${listVarEnv}
411                  export Script_Post_Output=create_ts.${PeriodDateEnd}.${TsTask}.${CompToRead}.${NameToRead}
412                  IGCM_sys_MkdirWork ${POST_DIR}
413                  IGCM_debug_Verif_Exit
414                  IGCM_sys_QsubPost create_ts
415                  echo
416                else
417                  IGCM_debug_Print 2 -e "\033[1;31mI should NOW submit ${FILE} chunck ${Dimension}\033[m period ${ChunckDebut}-${ChunckFin} and CompletedFlag=${ChunckCompletedFlag}"
418                fi
419              fi
420
421              if ( [ ${chunck} = false ] && [ ${SuccessRate} -ne 100 ] ) ; then
422                eval Launch${Dimension}=true
423              fi
424
425              # Date update
426              ChunckDebut=$( IGCM_date_AddDaysToGregorianDate ${ChunckFin} 1 )
427
428              (( YearsChunckLoop = YearsChunckLoop + 1 ))
429
430              if [ ${YearsChunckLoop} -eq ${NbYearsChunckLoop} ] ; then
431                ChunckFin=${DateEnd}
432              else
433                Length=$( IGCM_date_DaysInCurrentPeriod ${ChunckDebut} ${YearsChunckLength}Y )
434                ChunckFin=$( IGCM_date_AddDaysToGregorianDate ${ChunckDebut} ${Length}-1 )
435              fi
436            done
437          done
438        else
439          ListDimension[0]=""
440          TimeSeries=true
441          TimeSeries2D=false
442          TimeSeries3D=false
443          TimeSeriesChunck2D=false
444          TimeSeriesChunck3D=false
445        fi
446      fi
447      (( i=i+3 ))
448    done
449  fi
450done # comp loop
451
452echo
453
454DateBegin=$( IGCM_date_ConvertFormatToGregorian ${config_UserChoices_DateBegin} )
455IGCM_date_GetYearMonth ${DateBegin} YearBegin MonthBegin
456CompletedFlag=${SavedCompletedFlag}
457
458unset CompToRead
459unset FlagToRead
460
461if [ X${Launch2D} = Xtrue ] ; then
462  if [ ${action} = true ] ; then
463    #IGCM_debug_Print 2 "Potentials CompletedFlag: ${PotentialCompletedFlag2D[*]}"
464    IGCM_debug_Print 2 -e "\033[1;31mSubmit 2D\033[m without chunck period ${DateBegin}-${DateEnd}"
465    listVarEnv="DEBUG_debug,BigBrother,libIGCM,SUBMIT_DIR,POST_DIR,Script_Post_Output,DateBegin,PeriodDateEnd,CompletedFlag,TsTask"
466    export DEBUG_debug=${DEBUG_debug}
467    export BigBrother=${BigBrother}
468    export libIGCM=${libIGCM}
469    export SUBMIT_DIR=${CARD_DIR}
470    export POST_DIR=${POST_DIR}
471    export DateBegin=${DateBegin}
472    export PeriodDateEnd=${DateEnd}
473    export CompletedFlag=${CompletedFlag}
474    export TsTask=2D
475    export listVarEnv=${listVarEnv}
476    export Script_Post_Output=create_ts.${PeriodDateEnd}.${TsTask}
477    IGCM_sys_MkdirWork ${POST_DIR}
478    IGCM_debug_Verif_Exit
479    IGCM_sys_QsubPost create_ts
480    echo
481  else
482    IGCM_debug_Print 2 -e "\033[1;31mI should NOW submit 2D without chunck\033[m period ${DateBegin}-${DateEnd}"
483  fi
484fi
485
486if [ X${Launch3D} = Xtrue ] ; then
487  if [ ${action} = true ] ; then
488    #IGCM_debug_Print 2 "Potentials CompletedFlag: ${PotentialCompletedFlag3D[*]}"
489    IGCM_debug_Print 2 -e "\033[1;31mSubmit 3D\033[m without chunck period ${DateBegin}-${DateEnd}"
490    listVarEnv="DEBUG_debug,BigBrother,libIGCM,SUBMIT_DIR,POST_DIR,Script_Post_Output,DateBegin,PeriodDateEnd,CompletedFlag,TsTask"
491    export DEBUG_debug=${DEBUG_debug}
492    export BigBrother=${BigBrother}
493    export libIGCM=${libIGCM}
494    export SUBMIT_DIR=${CARD_DIR}
495    export POST_DIR=${POST_DIR}
496    export DateBegin=${DateBegin}
497    export PeriodDateEnd=${DateEnd}
498    export CompletedFlag=${CompletedFlag}
499    export TsTask=3D
500    export listVarEnv=${listVarEnv}
501    export Script_Post_Output=create_ts.${PeriodDateEnd}.${TsTask}
502    IGCM_sys_MkdirWork ${POST_DIR}
503    IGCM_debug_Verif_Exit
504    IGCM_sys_QsubPost create_ts
505    echo
506  else
507    IGCM_debug_Print 2 -e "\033[1;31mI should NOW submit 3D without chunck\033[m  period ${DateBegin}-${DateEnd}"
508  fi
509fi
Note: See TracBrowser for help on using the repository browser.