Ignore:
Timestamp:
2011-08-29T10:08:49+02:00 (13 years ago)
Author:
didier.solyga
Message:

Merge the revisions 388 to 396 from the trunk. Now the externalized version is based on ORCHIDEE_1_9_5_2

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/ORCHIDEE_EXT/ORCHIDEE_OL/SPINUP/COMP/spinup.driver

    r382 r408  
    299299 
    300300    IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/sechiba.card UserChoices sechiba_LEVEL ${spinup_UserChoices_sechiba_LEVEL} 
    301     spinup_SubJobPost_sechiba_TimeSeriesVars0=${spinup_SubJobPost_sechiba_TimeSeriesVars2D[0]} > /dev/null 2>&1 
     301    spinup_SubJobPost_sechiba_TimeSeriesVars0=${spinup_SubJobPost_sechiba_TimeSeriesVars2D[0]} 
    302302    if [ X${spinup_SubJobPost_sechiba_TimeSeriesVars0} != X${NULL_STR} ] ; then 
    303         IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/sechiba.card Post_1M_sechiba_history TimeSeriesVars2D "("$( echo ${spinup_SubJobPost_sechiba_TimeSeriesVars[@]} | sed -e "s/ /,/g" )")" 
     303        IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/sechiba.card Post_1M_sechiba_history TimeSeriesVars2D "("$( echo ${spinup_SubJobPost_sechiba_TimeSeriesVars2D[@]} | sed -e "s/ /,/g" )")" 
    304304    else 
    305305        IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/sechiba.card Post_1M_sechiba_history TimeSeriesVars2D "()" 
    306306    fi 
    307     spinup_SubJobPost_sechiba_TimeSeriesVars0=${spinup_SubJobPost_sechiba_TimeSeriesVars3D[0]} > /dev/null 2>&1 
     307    spinup_SubJobPost_sechiba_TimeSeriesVars0=${spinup_SubJobPost_sechiba_TimeSeriesVars3D[0]} 
    308308    if [ X${spinup_SubJobPost_sechiba_TimeSeriesVars0} != X${NULL_STR} ] ; then 
    309         IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/sechiba.card Post_1M_sechiba_history TimeSeriesVars3D "("$( echo ${spinup_SubJobPost_sechiba_TimeSeriesVars[@]} | sed -e "s/ /,/g" )")" 
     309        IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/sechiba.card Post_1M_sechiba_history TimeSeriesVars3D "("$( echo ${spinup_SubJobPost_sechiba_TimeSeriesVars3D[@]} | sed -e "s/ /,/g" )")" 
    310310    else 
    311311        IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/sechiba.card Post_1M_sechiba_history TimeSeriesVars3D "()" 
     
    646646 
    647647            # We Get the forcing file from the previous run of ORCHIDEE 
    648             ORCHIDEE_JobName=${LastJobName} 
    649             sed -e "s&(\${config_SBG_RestartPath}/\${config_SBG_RestartJobName}/SBG/Restart/\${config_SBG_RestartJobName}_\${Date_Restarts}_stomate_forcing.nc, stomate_forcing.nc)&(${config_SBG_RestartPath}/${ORCHIDEE_JobName}/SBG/Restart/${ORCHIDEE_JobName}_${output_PreviousStage_LastRestartDate}_stomate_forcing.nc, stomate_forcing.nc)&" ${New_SUBMIT_DIR}/COMP/sechiba.card > sechiba.card.tmp 
     648            sed -e "s&(\${config_SBG_RestartPath}/\${config_SBG_RestartJobName}/SBG/Restart/\${config_SBG_RestartJobName}_\${Date_Restarts}_stomate_forcing.nc, stomate_forcing.nc)&(${config_SBG_RestartPath}/${LastJobName}/SBG/Restart/${LastJobName}_${output_PreviousStage_LastRestartDate}_stomate_forcing.nc, stomate_forcing.nc)&" ${New_SUBMIT_DIR}/COMP/sechiba.card > sechiba.card.tmp 
    650649            IGCM_sys_Mv sechiba.card.tmp ${New_SUBMIT_DIR}/COMP/sechiba.card 
    651650 
     
    661660                fi 
    662661            done 
     662            eval IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card Post RebuildFrequency ${config_SubJob_PeriodLength} 
    663663            eval IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card Post TimeSeriesFrequency ${config_SubJob_PeriodLength} 
    664664 
     
    769769 
    770770            # We Get the forcing file from the previous run of ORCHIDEE 
    771             ORCHIDEE_JobName=${config_UserChoices_JobName}ORC_${iter} 
    772             sed -e "s&(\${config_SBG_RestartPath}/\${config_SBG_RestartJobName}/SBG/Restart/\${config_SBG_RestartJobName}_\${Date_Restarts}_stomate_forcing.nc, stomate_forcing.nc)&(${config_SBG_RestartPath}/${ORCHIDEE_JobName}/SBG/Restart/${ORCHIDEE_JobName}_${output_PreviousStage_LastRestartDate}_stomate_forcing.nc, stomate_forcing.nc)&" ${New_SUBMIT_DIR}/COMP/sechiba.card > sechiba.card.tmp 
     771            sed -e "s&(\${config_SBG_RestartPath}/\${config_SBG_RestartJobName}/SBG/Restart/\${config_SBG_RestartJobName}_\${Date_Restarts}_stomate_forcing.nc, stomate_forcing.nc)&(${config_SBG_RestartPath}/${LastJobName}/SBG/Restart/${LastJobName}_${output_PreviousStage_LastRestartDate}_stomate_forcing.nc, stomate_forcing.nc)&" ${New_SUBMIT_DIR}/COMP/sechiba.card > sechiba.card.tmp 
    773772            IGCM_sys_Mv sechiba.card.tmp ${New_SUBMIT_DIR}/COMP/sechiba.card 
    774773 
     
    784783                fi 
    785784            done 
     785            eval IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card Post RebuildFrequency ${config_SubJob_PeriodLength} 
    786786            eval IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card Post TimeSeriesFrequency ${config_SubJob_PeriodLength} 
    787787 
     
    812812 
    813813            # We Get the forcing file from the previous run of ORCHIDEE 
    814             ORCHIDEE_JobName=${config_UserChoices_JobName}${output_PreviousStage_LastExtName} 
    815814            IGCM_card_DefineVariableFromOption ${SUBMIT_DIR}/output.card PreviousStage LastRestartDate 
    816             if ( [ X${spinup_UserChoices_DEBUG_SPIN} = Xn ] ) ; then   
    817                 last_Cforcing=${config_SBG_RestartPath}/${config_UserChoices_JobName}/SPIN/Output/${ORCHIDEE_JobName}/SBG/Restart/${ORCHIDEE_JobName}_${output_PreviousStage_LastRestartDate}_stomate_Cforcing.nc 
    818             else 
    819                 last_Cforcing=${config_SBG_RestartPath}/${ORCHIDEE_JobName}/SBG/Restart/${ORCHIDEE_JobName}_${output_PreviousStage_LastRestartDate}_stomate_Cforcing.nc 
    820             fi 
    821             ls -lrt ${last_Cforcing} 
    822             IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/stomate.card BoundaryFiles ListNonDel "(${last_Cforcing}, stomate_Cforcing.nc), \\" 
     815 
     816            IGCM_card_WriteOption ${New_SUBMIT_DIR}/COMP/stomate.card BoundaryFiles ListNonDel \ 
     817                    "(${config_SBG_RestartPath}/${LastJobName}/SBG/Restart/${LastJobName}_${output_PreviousStage_LastRestartDate}_stomate_Cforcing.nc, stomate_Cforcing.nc), \\" 
    823818 
    824819            # Nb years for forcing FORCESOIL 
     
    959954    echo "SECHIBA WriteFrequency : " ${config_SRF_WriteFrequency} 
    960955    if ( [ X${StageName} != X"TSTOINI" ] && [ X${StageName} != X"TSTO" ] && [ X${StageName} != X"FORC" ] ) ; then 
    961     IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card SRF WriteFrequency "${config_SRF_WriteFrequency}" 
     956        IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card SRF WriteFrequency "${config_SRF_WriteFrequency}" 
    962957    fi 
    963958    if [ X"${spinup_UserChoices_ok_stomate}" = "Xy" ] ; then 
    964959        echo "STOMATE WriteFrequency : " ${config_SBG_WriteFrequency} 
    965         IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card SBG WriteFrequency "${config_SBG_WriteFrequency}" 
     960        case $StageName in 
     961            "TSTOINI"|"TSTO") 
     962                IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card SBG WriteFrequency "1Y" 
     963                ;; 
     964            *) 
     965                IGCM_card_WriteOption ${New_SUBMIT_DIR}/config.card SBG WriteFrequency "${config_SBG_WriteFrequency}" 
     966        esac 
    966967    fi 
    967968 
     
    10051006    # Did it finish ? 
    10061007    if [ X${run_Configuration_PeriodState} != X"Completed" ] ; then 
    1007         IGCM_debug_Exit "SPIN_update Error Run SubJob : " ${SubJobName} 
     1008        IGCM_debug_Exit "SPIN_update Error Run SubJob : " ${SubJobName} ${run_Configuration_PeriodState} 
    10081009    fi 
    10091010    IGCM_debug_Verif_Exit 
     
    10231024    if [ X${StageName} = X"FORC" ] ; then 
    10241025        # This must be done on the ARCHIVE HOST. 
    1025         if ( [ X${spinup_UserChoices_DEBUG_SPIN} = Xn ] ) ; then   
    1026             last_restart=${config_SBG_RestartPath}/${config_UserChoices_JobName}/SPIN/Output/${ORCHIDEE_JobName}/SRF/Restart/${ORCHIDEE_JobName}_${output_PreviousStage_LastRestartDate}_sechiba_rest.nc 
    1027         else 
    1028             last_restart=${config_SBG_RestartPath}/${ORCHIDEE_JobName}/SRF/Restart/${ORCHIDEE_JobName}_${output_PreviousStage_LastRestartDate}_sechiba_rest.nc 
    1029         fi 
    10301026        IGCM_sys_MkdirArchive ${config_SBG_RestartPath}/${SubJobName}/SRF/Restart 
    1031         IGCM_sys_RshArchive "cp -fp ${last_restart} ${config_SBG_RestartPath}/${SubJobName}/SRF/Restart/${SubJobName}_${This_Job_DateEnd}_sechiba_rest.nc" 
     1027        IGCM_sys_RshArchive \ 
     1028            "cp -fp ${config_SBG_RestartPath}/${LastJobName}/SRF/Restart/${LastJobName}_${output_PreviousStage_LastRestartDate}_sechiba_rest.nc"\ 
     1029                  " ${config_SBG_RestartPath}/${SubJobName}/SRF/Restart/${SubJobName}_${This_Job_DateEnd}_sechiba_rest.nc" 
    10321030    fi 
    10331031 
     
    10471045        fi 
    10481046 
    1049         IGCM_sys_RshArchive "mv -f ${R_OUT}/${config_UserChoices_TagName}/${config_UserChoices_JobName}${output_PreviousStage_LastExtName} ${R_OUT}/${config_UserChoices_TagName}/${config_UserChoices_JobName}/SPIN/Output/" 
     1047        IGCM_sys_RshArchive "mv -f ${R_OUT}/${config_UserChoices_TagName}/${config_UserChoices_JobName}${output_PreviousStage_LastExtName}"\ 
     1048                                 " ${R_OUT}/${config_UserChoices_TagName}/${config_UserChoices_JobName}/SPIN/Output/" 
    10501049    fi 
    10511050 
Note: See TracChangeset for help on using the changeset viewer.