Changeset 1399


Ignore:
Timestamp:
07/05/17 20:18:51 (7 years ago)
Author:
sdipsl
Message:

CMIP6 workflow. Merging trunk into branch 'branch' r:1375:1398

Location:
tags/libIGCM_v3.0_beta1
Files:
1 deleted
22 edited
1 copied

Legend:

Unmodified
Added
Removed
  • tags/libIGCM_v3.0_beta1/AA_clean_latestPackperiod

    r1356 r1399  
    256256        IGCM_sys_Rm ${SUBMIT_DIR}/run.card 
    257257      else 
    258         # Update run.card 
     258        # Update run.card 
    259259        cp ${SUBMIT_DIR}/run.card ${SUBMIT_DIR}/run.card.old 
    260260        IGCM_card_WriteOption ${SUBMIT_DIR}/run.card Configuration PeriodState "OnQueue" 
     
    264264        IGCM_card_WriteOption ${SUBMIT_DIR}/run.card Configuration PeriodDateEnd \ 
    265265                              $( IGCM_date_HumanDigit ${PeriodDateEnd} ) 
    266         # Update job 
     266        # Update job 
    267267        cp Job_${config_UserChoices_JobName} Job_${config_UserChoices_JobName}.old 
    268268        sed -e "s/\(#.*Script_Output_${config_UserChoices_JobName}\.\)\([0-9]*\)\(.*\)/\1${Suffix}\3/" \ 
  • tags/libIGCM_v3.0_beta1/AA_clean_month

    r1343 r1399  
    55   
    66echo "" 
    7 echo "This script has been renamed. Now please use clean_PeriodLenght.job in libIGCM directory." 
     7echo "This script has been renamed. Now please use clean_PeriodLength.job in libIGCM directory." 
    88echo "See documentation https://forge.ipsl.jussieu.fr/igcmg_doc/wiki/DocGmonitor#Unknownerror" 
    99echo "" 
  • tags/libIGCM_v3.0_beta1/AA_create_multi_se

    r1356 r1399  
    424424     [ ${config_UserChoices_TagName} = "IPSLCM5B" ]        || \ 
    425425     [ ${config_UserChoices_TagName} = "IPSLCM5A-MR" ]     || \ 
     426     [ ${config_UserChoices_TagName} = "IPSLCM5A2" ]       || \ 
    426427     [ ${config_UserChoices_TagName} = "IPSLCM6" ] ; then 
    427428  export Script_Post_Output=atlas_ORCHIDEE.${PeriodDateEnd} ; 
  • tags/libIGCM_v3.0_beta1/AA_create_se

    r1366 r1399  
    584584     [ ${config_UserChoices_TagName} = "IPSLCM5B" ]        || \ 
    585585     [ ${config_UserChoices_TagName} = "IPSLCM5A-MR" ]     || \ 
     586     [ ${config_UserChoices_TagName} = "IPSLCM5A2" ]       || \ 
    586587     [ ${config_UserChoices_TagName} = "IPSLCM6" ] ; then 
    587588  # METRICS 
  • tags/libIGCM_v3.0_beta1/AA_create_ts

    r1356 r1399  
    736736        # 
    737737        if [ "${DEPOT}" = "TRUE" ] ; then 
    738           # YEARLY AVERAGE DERIVED FROM MONTHLY MEAN 
    739           if ( [ ${FlagDir} = "1M" ] && [ -f ${file_out} ] ) ; then 
    740             file_before_YE=${config_UserChoices_JobName}_${DateBegin}_${DATE_FIN_JOB_B}_1Y_${var}.nc 
    741             file_out_YE=${config_UserChoices_JobName}_${DATE_BUILD_END}_1Y_${var}.nc 
    742             # 
    743             # Compute yearly average considering calendar 
    744             IGCM_sys_cdo yearmonmean -selvar,${var} ${file_out} ${file_out_YE} 
    745             # Extract all ancillary variables except $var, they will be appended after the cdo command 
    746             # Needed because cdo applies calculs on all variables 
    747             IGCM_sys_ncks -Oh -x -v ${var} ${file_out} ${file_out_YE%%.nc}_tmp1.nc 
    748             # This will remove the time axis because cdo rewrites severely with only considered useful variables 
    749             IGCM_sys_cdo -mulc,1 ${file_out_YE%%.nc}_tmp1.nc ${file_out_YE%%.nc}_tmp2.nc 2>/dev/null 
    750             if [ $? -eq 0 ] ; then 
    751               # Now append all ancillary variables if previous cdo operator ok 
    752               IGCM_sys_ncks -h -A ${file_out_YE%%.nc}_tmp2.nc ${file_out_YE} 
    753             fi 
    754  
    755             # Put global history attribut 
    756             IGCM_sys_ncatted -Oh -a history,global,o,c,"build by libIGCM/create_ts" ${file_out_YE} 
    757             IGCM_debug_Verif_Exit 
    758             # 
    759             eval IGCM_sys_Put_Out ${file_out_YE} \${R_OUT_${comp}}/Analyse/TS_MO_YE/${file_out_YE} 
    760             [ "${FLAG_B}" = "TRUE" ] && eval MENAGE \${R_OUT_${comp}}/Analyse/TS_MO_YE/ ${file_before_YE} ${file_out_YE} 
    761             IGCM_sys_Rm ${file_out_YE%%.nc}_tmp*.nc 
    762           fi 
    763738          # WE PUT FINAL FILE ON FILE SYSTEM 
    764739          [ "${FLAG_B}" = "FALSE" ] && file_out=${config_UserChoices_JobName}_${DATE_BUILD}_${FlagDir}_${var}.nc 
     
    786761# DODS copy 
    787762for comp in ${config_ListOfComponents[*]} ; do 
    788   for TS_Dir in TS_YE TS_MO TS_MO_YE TS_DA TS_HF TS_INS ; do 
     763  for TS_Dir in TS_YE TS_MO TS_DA TS_HF TS_INS ; do 
    789764    IGCM_sys_TestDirArchive ${R_SAVE}/${comp}/Analyse/${TS_Dir} 
    790765    [ $? = 0 ] && IGCM_sys_Put_Dods ${comp}/Analyse/${TS_Dir} 
  • tags/libIGCM_v3.0_beta1/AA_job

    r1373 r1399  
    1111#-Q- curie #MSUB -x                    # exclusive node. To specify only for MPMD together with the one below 
    1212#-Q- curie #MSUB -E '--cpu_bind=none' 
     13#-Q- curie ##MSUB -E '--distribution cyclic'  
    1314#-Q- curie #MSUB -T 86400              # Wall clock limit (seconds) 
    1415#-Q- curie #MSUB -q standard           # thin nodes 
    15 #-Q- curie #MSUB -U medium             # priority within a project 
    1616#-Q- curie #MSUB -A ::default_project:: 
    1717#-Q- curie # Below specific options that can be activated  
  • tags/libIGCM_v3.0_beta1/AA_metrics_NEMO

    r1365 r1399  
    161161orca_grid=${DB}/grids/${opa9_UserChoices_ORCA_version}_grid.nc 
    162162 
    163 IGCM_sys_ncks --append -v bounds_lat,bounds_lon ${orca_grid} ${config_UserChoices_JobName}_SE_${YEARS}_1M_grid_T.nc 
    164 IGCM_sys_ncatted -O -a bounds,nav_lat,o,c,bounds_lat ${config_UserChoices_JobName}_SE_${YEARS}_1M_grid_T.nc 
    165 IGCM_sys_ncatted -O -a bounds,nav_lon,o,c,bounds_lon ${config_UserChoices_JobName}_SE_${YEARS}_1M_grid_T.nc 
    166  
    167 IGCM_sys_ncks --append -v bounds_lat,bounds_lon ${orca_grid} ${config_UserChoices_JobName}_SE_${YEARS}_1MVertLevels_grid_T.nc 
    168 IGCM_sys_ncatted -O -a bounds,nav_lat,o,c,bounds_lat ${config_UserChoices_JobName}_SE_${YEARS}_1MVertLevels_grid_T.nc 
    169 IGCM_sys_ncatted -O -a bounds,nav_lon,o,c,bounds_lon ${config_UserChoices_JobName}_SE_${YEARS}_1MVertLevels_grid_T.nc 
     163## IGCM_sys_ncks --append -v bounds_lat,bounds_lon ${orca_grid} ${config_UserChoices_JobName}_SE_${YEARS}_1M_grid_T.nc 
     164## IGCM_sys_ncatted -O -a bounds,nav_lat,o,c,bounds_lat ${config_UserChoices_JobName}_SE_${YEARS}_1M_grid_T.nc 
     165## IGCM_sys_ncatted -O -a bounds,nav_lon,o,c,bounds_lon ${config_UserChoices_JobName}_SE_${YEARS}_1M_grid_T.nc 
     166 
     167## IGCM_sys_ncks --append -v bounds_lat,bounds_lon ${orca_grid} ${config_UserChoices_JobName}_SE_${YEARS}_1MVertLevels_grid_T.nc 
     168## IGCM_sys_ncatted -O -a bounds,nav_lat,o,c,bounds_lat ${config_UserChoices_JobName}_SE_${YEARS}_1MVertLevels_grid_T.nc 
     169## IGCM_sys_ncatted -O -a bounds,nav_lon,o,c,bounds_lon ${config_UserChoices_JobName}_SE_${YEARS}_1MVertLevels_grid_T.nc 
    170170 
    171171#================================== 
  • tags/libIGCM_v3.0_beta1/AA_pack_restart

    r1356 r1399  
    2727#-Q- ada # pour recevoir un mail en cas de depassement du temps Elapsed (ou autre pb.) 
    2828#-Q- ada # @ notification = error 
    29 #-Q- ada # @ environment  = $DEBUG_debug ; $BigBrother ; $postProcessingStopLevel ; $MODIPSL ; $libIGCM ; $libIGCM_SX ; $POST_DIR ; $Script_Post_Output ; $SUBMIT_DIR ; $DateBegin ; $DateEnd ; $PeriodPack ; $StandAlone ; $MASTER ; wall_clock_limit=$(wall_clock_limit) 
     29#-Q- ada # @ environment  = $DEBUG_debug ; $BigBrother ; $postProcessingStopLevel ; $MODIPSL ; $libIGCM ; $libIGCM_SX ; $POST_DIR ; $Script_Post_Output ; $SUBMIT_DIR ; $PeriodDateBegin ; $DateBegin ; $DateEnd ; $PeriodPack ; $StandAlone ; $MASTER ; wall_clock_limit=$(wall_clock_limit) 
    3030#-Q- ada # @ queue 
    3131#-Q- lxiv8 ###################### 
     
    205205rm -f ${RUN_DIR}/new_liste_restart_files.txt 
    206206rm -f ${RUN_DIR}/liste_pack_*.txt 
     207rm -f ${RUN_DIR}/liste_pack_light_*.txt 
    207208 
    208209# Create sorted restart list to work with 
     
    251252      [ ${date_file} -eq ${date_end_pack} ] || echo $( readlink ${file} ) >> ${RUN_DIR}/liste_remove_pack_${date_begin_pack}_${date_end_pack}.txt 
    252253    fi 
     254    # light pack list of restarts files that will be used 
     255    if [ X${config_Post_LightRestartPack} = XTRUE ] ; then 
     256      if [ ${date_file} -le ${date_end_pack} ] && [ ${date_file} -ge ${PeriodDateBegin} ] ; then 
     257        echo $( basename ${file} ) >> ${RUN_DIR}/liste_pack_light_${date_begin_pack}_${date_end_pack}.txt 
     258      fi 
     259    fi 
    253260  done 
    254261 
    255262  # Create tar files 
    256263  IGCM_debug_Print 1 "Tar ongoing" 
    257   tar -cvf ${JobName}_${date_begin_pack}_${date_end_pack}_restart.tar --dereference --files-from ${RUN_DIR}/liste_pack_${date_begin_pack}_${date_end_pack}.txt 
     264  if [ X${config_Post_LightRestartPack} = XTRUE ] ; then 
     265    tar -cvf ${JobName}_${date_begin_pack}_${date_end_pack}_restart.tar --dereference --files-from ${RUN_DIR}/liste_pack_${date_begin_pack}_${date_end_pack}.txt 
     266  else 
     267    tar -cvf ${JobName}_${date_begin_pack}_${date_end_pack}_restart.tar --dereference --files-from ${RUN_DIR}/liste_pack_light_${date_begin_pack}_${date_end_pack}.tx 
     268  fi 
    258269  # Save it 
    259270  IGCM_sys_Put_Out ${JobName}_${date_begin_pack}_${date_end_pack}_restart.tar ${STORE_RESTART} 
  • tags/libIGCM_v3.0_beta1/AA_purge_simulation

    r1373 r1399  
    2828Verbosity=3 
    2929 
    30 #D- Low level debug : to bypass lib test checks and stack construction 
     30#D- Low level debug : to perform lib test checks, stack construction and IO functions instrumentation 
    3131#D- Default=true 
    32 DEBUG_debug=false 
     32DEBUG_debug=true 
     33 
     34#D- Messaging : all activities and call stacks will be sent to ipsl servers 
     35#D- If true will imply DEBUG_debug=true 
     36#D- Default=false 
     37#D- 
     38BigBrother=true 
     39 
    3340 
    3441#D--------------------------------------------------------------------== 
     
    5562( ${DEBUG_debug} ) && IGCM_card_Check 
    5663( ${DEBUG_debug} ) && IGCM_date_Check 
     64 
     65if [ ! -f ${SUBMIT_DIR}/config.card ] ; then 
     66  echo "A config.card is needed to proceed" 
     67  exit 
     68fi 
    5769 
    5870#================================== 
     
    8294    IGCM_debug_Print 2 -e "\033[1;31m ${dir}\033[m" 
    8395  done 
     96  IGCM_debug_Print 2 -e "\033[1;31m ${SUBMIT_DIR}/run.card\033[m" 
     97  IGCM_debug_Print 2 -e "\033[1;31m ${SUBMIT_DIR}/Debug\033[m" 
     98  IGCM_debug_Print 2 -e "\033[1;31m ${SUBMIT_DIR}/Script_Output_*.??????\033[m" 
    8499 
    85   echo -e "\033[1;32mDo you REALLY want to erase all those directories ?" 
     100  echo -e "\033[1;32mDo you REALLY want to erase all those directories and files?" 
    86101  echo -n -e " Your answer (y/n) : \033[m" 
    87102  read reponse 
  • tags/libIGCM_v3.0_beta1/ins_job

    r1371 r1399  
    218218  fi # if ( ! ${x_pm} ) 
    219219  echo MPIEnvironment is ${MPIEnvironment} 
    220 else 
    221   echo No option for Header regarding ProjectID, ProjectNode, ProjectCore or MPIEnvironment because we are not on curie or ada 
     220elif [ X"${SYSTEM}" == "Xlxiv8" ] || [ X"${SYSTEM}" == "Xifort_CICLAD" ] ; then 
     221  # obelix, ciclad, climserv 
     222  echo "" 
     223  echo "You need to check and maybe adapt headers in the main job especially the line: " 
     224  echo "  #PBS -l nodes=x:ppn=y " 
     225  echo "where x is the number of nodes, y the number of cores per node and x*y is the total number of cores for the job. " 
     226  echo "y must not be bigger than the maximum numer of cores per node on the machine (often 8 or 16)." 
    222227fi # if [ X"${SYSTEM}" == "Xcurie" ] 
    223228 
  • tags/libIGCM_v3.0_beta1/libIGCM_comp/libIGCM_comp.ksh

    r1375 r1399  
    778778              if [ X${OCE_PROC_MPI} != X ] ; then 
    779779                if [ ${OCE_PROC_MPI} -ne ${nb_restart_file} ] ; then 
    780                   IGCM_sys_rebuild ${generic_restart_file_name_out}.${extension_out} ${generic_restart_file_name_out}_????.${extension_out} 
     780                  IGCM_sys_rebuild_nemo ${generic_restart_file_name_out} ${nb_restart_file} ${extension_out} ${generic_restart_file_name_out}_????.${extension_out} 
    781781                  IGCM_sys_Rm ${generic_restart_file_name_out}_????.${extension_out} 
    782782                fi 
     
    13261326  fi 
    13271327 
    1328   # Test if keyid is set in filein, otherwise exit 
     1328  # Test if keyid is set in filein. If not exit for case all cases(blocker, force) except nonblocker. 
    13291329  if [ $( grep -w ${keyid} ${filein} | wc -l ) = 0 ] ; then 
    1330     # Variable key is not set in filein, stop. 
    1331     IGCM_debug_Exit "IGCM_comp_modifyXmlFile : ${keyid} is not set in the file. Bad syntax of ${filein} file." 
    1332     IGCM_debug_PopStack "IGCM_comp_modifyXmlFile" 
    1333     return 
     1330      if [ ${type} = nonblocker ] ; then 
     1331          # This is a nonblocker case, print warning but do nothing else 
     1332          IGCM_debug_Print 1 "IGCM_comp_modifyXmlFile: ${keyid} is not set in ${filein}. This is a nonblocker call so nothing is done." 
     1333      else 
     1334          # This is a blocker or force case : stop now 
     1335          IGCM_debug_Exit "IGCM_comp_modifyXmlFile : ${keyid} is not set in the file. Bad syntax of ${filein} file." 
     1336          IGCM_debug_PopStack "IGCM_comp_modifyXmlFile" 
     1337          return 
     1338      fi 
    13341339  fi 
    13351340 
    13361341  # Check if AUTO is set on the same line as keyid and keyattrib 
    13371342  if [  $( grep -w ${keyid} ${filein} | grep AUTO | wc -l ) = 1 ] ; then 
    1338     # Modifification will be done 
     1343    # Modification will be done 
    13391344    modify=yes 
    13401345  else 
     
    17151720          if [ X${AsynchronousRebuild} = Xfalse ] ; then 
    17161721            IGCM_debug_Print 2 "Rebuilding ${file_in} online" 
    1717             IGCM_sys_rebuild ${file_in} ${generic_file_name}_[0-9]*.nc 
     1722            # 
     1723            # for output.abort file, let use rebuild_NEMO : 13s instead of 20 mn. 
     1724            if [ ${file_in} = output.abort.nc ] ; then 
     1725              IGCM_sys_rebuild_nemo ${generic_file_name} ${nb_rebuild_file} "nc" ${generic_file_name}_[0-9]*.nc 
     1726            else 
     1727              IGCM_sys_rebuild ${file_in} ${generic_file_name}_[0-9]*.nc 
     1728            fi 
    17181729          else 
    17191730            IGCM_debug_Print 2 "Preparing offline rebuild for ${file_in}" 
  • tags/libIGCM_v3.0_beta1/libIGCM_config/libIGCM_config.ksh

    r1375 r1399  
    169169  if ( [ X${config_Post_IgnoreNonMonotonic} = X${NULL_STR} ] || [ X${config_Post_IgnoreNonMonotonic} = X ] ) ; then 
    170170    config_Post_IgnoreNonMonotonic=FALSE 
     171  fi 
     172 
     173  #==================================================== 
     174  # LightRestartPack : apply default value if not defined 
     175  if ( [ X${config_Post_LightRestartPack} = X${NULL_STR} ] || [ X${config_Post_LightRestartPack} = X ] ) ; then 
     176    config_Post_LightRestartPack=FALSE 
    171177  fi 
    172178 
     
    830836          ( IGCM_sys_TestFileBuffer  ${R_BUF_KSH}/${Potential} ) || IGCM_sys_Cp ${Potential} ${R_BUF_KSH}/${Potential}.$$ 
    831837        else 
    832           ( IGCM_sys_TestFileArchive ${R_OUT_KSH}/${Potential} ) || IGCM_sys_Cp ${Potential} ${R_OUT_KSH}/${Potential}.$$ 
     838          ( IGCM_sys_TestFileArchive ${R_OUT_KSH}/${Potential} ) || IGCM_sys_Put_Out ${Potential} ${R_OUT_KSH}/${Potential}.$$ NOCHMOD 
    833839        fi 
    834840      done 
     
    836842      IGCM_debug_Print 2 "Save current run.card" 
    837843      IGCM_card_CheckConflict run.card 
     844 
    838845      if [ X${Pack} = Xtrue ] ; then 
    839846        IGCM_sys_Cp ${SUBMIT_DIR}/run.card ${R_BUF_KSH}/run.card 
    840847      else 
    841         IGCM_sys_Cp ${SUBMIT_DIR}/run.card ${R_OUT_KSH}/run.card 
     848        IGCM_sys_Put_Out ${SUBMIT_DIR}/run.card ${R_OUT_KSH}/run.card NOCHMOD 
    842849      fi 
    843850      # 
  • tags/libIGCM_v3.0_beta1/libIGCM_debug/libIGCM_debug.ksh

    r1367 r1399  
    147147  b64_encoded_msg=$1 
    148148 
    149   mail_recipient="superviseur@ipsl.jussieu.fr" 
     149  mail_recipient="superviseur@mail.ipsl.upmc.fr" 
    150150  send_messages=0 
    151151  mail_frequency=3600 # in seconds 
  • tags/libIGCM_v3.0_beta1/libIGCM_ensemble/libIGCM_ensemble.ksh

    r1361 r1399  
    954954      ${PerturbExe} ${RUN_DIR}/${FileOut}.nc ${PerturbVar} ${PerturbAmp}  > /dev/null 2>&1 
    955955      if [ $? -ne 0 ] ; then 
    956         IGCM_debug_Exit "Abend $( basename ${PerturbExe} )" 
     956        IGCM_debug_Exit "Error with $( basename ${PerturbExe} )" 
    957957        IGCM_debug_Verif_Exit 
    958958      fi 
     
    981981      ${PerturbExe} ${RUN_DIR}/${FileOut}.nc ${PerturbVar} ${PatternFile} ${MaskFile}  > /dev/null 2>&1 
    982982      if [ $? -ne 0 ] ; then 
    983         IGCM_debug_Exit "Abend $( basename ${PerturbExe} )" 
     983        IGCM_debug_Exit "Error with $( basename ${PerturbExe} )" 
    984984        IGCM_debug_Verif_Exit 
    985985      fi 
  • tags/libIGCM_v3.0_beta1/libIGCM_post/libIGCM_post.ksh

    r1375 r1399  
    264264      export POST_DIR=${POST_DIR} 
    265265      export MASTER=${MASTER} 
     266      export PeriodDateBegin=${PeriodDateBegin} 
    266267      export DateBegin=${PackDateBegin} 
    267268      export DateEnd=${PeriodDateEnd} 
  • tags/libIGCM_v3.0_beta1/libIGCM_sys/libIGCM_sys.ksh

    r1314 r1399  
    5252case $( hostname -s ) in 
    5353    ada*) 
    54         [ ! X${TaskType} = Xchecking ] && echo "sys source ada Intel X-64 lib." 
     54        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for ada Intel X-64." 
    5555        CENTER=IDRIS 
    5656        SYSTEM=ada 
    5757        . ${libIGCM}/libIGCM_sys/libIGCM_sys_ada.ksh;; 
    5858    curie*) 
    59         [ ! X${TaskType} = Xchecking ] && echo "sys source curie Intel X-64 lib." 
     59        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for curie Intel X-64." 
    6060        CENTER=TGCC 
    6161        SYSTEM=curie 
    6262        . ${libIGCM}/libIGCM_sys/libIGCM_sys_curie.ksh;; 
    6363    airain*) 
    64         [ ! X${TaskType} = Xchecking ] && echo "sys source airain Intel X-64 lib." 
     64        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for airain Intel X-64." 
    6565        CENTER=TGCC 
    6666        SYSTEM=curie 
    6767        . ${libIGCM}/libIGCM_sys/libIGCM_sys_curie.ksh;; 
    6868    asterix*|obelix*) 
    69         [ ! X${TaskType} = Xchecking ] && echo "sys source obelix or asterix lib." 
     69        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for obelix or asterix." 
    7070        CENTER=LSCE 
    7171        SYSTEM=lxiv8 
    7272        . ${libIGCM}/libIGCM_sys/libIGCM_sys_obelix.ksh;; 
    7373    ciclad*) 
    74         [ ! X${TaskType} = Xchecking ] && echo "sys source ciclad lib for running at ciclad." 
     74        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for ciclad for running at ciclad." 
    7575        CENTER=IPSL-ciclad 
    7676        SYSTEM=ifort_CICLAD 
    7777        . ${libIGCM}/libIGCM_sys/libIGCM_sys_ciclad.ksh;; 
    7878    camelot*|loholt1*|loholt2*|merlin*) 
    79         [ ! X${TaskType} = Xchecking ] && echo "sys source ciclad lib for running at climserv." 
     79        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for ciclad for running at climserv." 
    8080        CENTER=IPSL-climserv 
    8181        SYSTEM=ifort_CICLAD 
    8282        . ${libIGCM}/libIGCM_sys/libIGCM_sys_ciclad.ksh;; 
    8383    iitm*) 
    84         [ ! X${TaskType} = Xchecking ] && echo "sys source iitm lib." 
     84        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for iitm." 
    8585        CENTER=IITM 
    8686        SYSTEM=iitm 
    8787        . ${libIGCM}/libIGCM_sys/libIGCM_sys_iitm.ksh;; 
    8888    *) 
    89         [ ! X${TaskType} = Xchecking ] && echo "sys source default lib." 
     89        [ ! X${TaskType} = Xchecking ] && echo "Source machine dependent settings for a default machine." 
    9090        CENTER=DEFAULT 
    9191        SYSTEM=default 
  • tags/libIGCM_v3.0_beta1/libIGCM_sys/libIGCM_sys_ada.ksh

    r1362 r1399  
    807807 
    808808  IGCM_debug_PopStack "IGCM_sys_GetDate_Monitoring" 
     809} 
     810 
     811#D-#================================================== 
     812#D-function IGCM_sys_Dods_Rm 
     813#D-* Purpose: DO NOTHING ! Put ${ARCHIVE} files on DODS internet protocole. 
     814#D-* Examples: 
     815#D- 
     816function IGCM_sys_Dods_Rm { 
     817  if ( $DEBUG_sys ) ; then 
     818    echo "IGCM_sys_Dods_Rm :" $@ 
     819  fi 
     820 
     821  typeset status 
     822  if [ $DRYRUN = 0 ]; then 
     823    if [ "$#" -eq 1 ]; then 
     824      rsh ${STOREHOST} exec /bin/ksh <<EOF 
     825          cd ${R_SAVE} 
     826          /arch/local/bin/dods_rm DODS/pub/${LOGIN}/${R_DODS}/${1} > /dev/null 2>&1 
     827EOF 
     828      status=$? 
     829    else 
     830      rsh ${STOREHOST} exec /bin/ksh <<EOF 
     831          cd ${R_SAVE} 
     832          /arch/local/bin/dods_rm DODS/pub/${LOGIN}/${R_DODS} > /dev/null 2>&1 
     833EOF 
     834      status=$? 
     835    fi 
     836  fi 
     837 
     838  return ${status} 
     839} 
     840 
     841#D-#================================================== 
     842#D-function IGCM_sys_Dods_Cp 
     843#D-* Purpose: Copy $(ARCHIVE) files on DODS internet protocole. 
     844#D-* Examples: 
     845#D- 
     846function IGCM_sys_Dods_Cp { 
     847  if ( $DEBUG_sys ) ; then 
     848    echo "IGCM_sys_Dods_Cp :" $@ 
     849  fi 
     850  return 0 
    809851} 
    810852 
     
    15461588} 
    15471589 
     1590#D-#================================================== 
     1591#D-function IGCM_sys_rebuild_nemo 
     1592#D-* Purpose: rebuild nemo parallel files with general rebuild 
     1593#D-* Examples: 
     1594#D- 
     1595 
     1596function IGCM_sys_rebuild_nemo { 
     1597  IGCM_debug_PushStack "IGCM_sys_rebuild_nemo" $@ 
     1598  if ( $DEBUG_sys ) ; then 
     1599    echo "IGCM_sys_rebuild_nemo :" $@ 
     1600  fi 
     1601 
     1602  nemo_generic_restart_file_name_out=${1} 
     1603  nemo_extension_out=${3} 
     1604  shift ; shift ; shift 
     1605 
     1606  IGCM_sys_rebuild -o ${nemo_generic_restart_file_name_out}.${nemo_extension_out} $@ 
     1607 
     1608  IGCM_debug_PopStack "IGCM_sys_rebuild_nemo" 
     1609} 
     1610 
     1611 
  • tags/libIGCM_v3.0_beta1/libIGCM_sys/libIGCM_sys_ciclad.ksh

    r1358 r1399  
    12331233} 
    12341234 
     1235#D-#================================================== 
     1236#D-function IGCM_sys_rebuild_nemo 
     1237#D-* Purpose: rebuild nemo parallel files with general rebuild 
     1238#D-* Examples: 
     1239#D- 
     1240 
     1241function IGCM_sys_rebuild_nemo { 
     1242  IGCM_debug_PushStack "IGCM_sys_rebuild_nemo" $@ 
     1243  if ( $DEBUG_sys ) ; then 
     1244    echo "IGCM_sys_rebuild_nemo :" $@ 
     1245  fi 
     1246 
     1247  nemo_generic_restart_file_name_out=${1} 
     1248  nemo_extension_out=${3} 
     1249  shift ; shift ; shift 
     1250 
     1251  IGCM_sys_rebuild -o ${nemo_generic_restart_file_name_out}.${nemo_extension_out} $@ 
     1252 
     1253  IGCM_debug_PopStack "IGCM_sys_rebuild_nemo" 
     1254} 
     1255 
     1256 
     1257 
  • tags/libIGCM_v3.0_beta1/libIGCM_sys/libIGCM_sys_curie.ksh

    r1364 r1399  
    178178#==================================================== 
    179179#- HOST_MPIRUN_COMMAND 
    180 typeset -r HOST_MPIRUN_COMMAND=${HOST_MPIRUN_COMMAND:="/usr/bin/time ccc_mprun -E-K1"} 
     180typeset -r HOST_MPIRUN_COMMAND=${HOST_MPIRUN_COMMAND:="/usr/bin/time ccc_mprun -E-K1 "} 
    181181 
    182182#==================================================== 
     
    922922#    fi 
    923923 
    924     /ccc/cont003/home/dsm/p86ipsl/bin/dods_rm public/${LOGIN}/${R_DODS}/${1} # > out_dods_rm 2>&1 
    925     status=$? 
     924    if [ "$#" -eq 1 ]; then 
     925      /ccc/cont003/home/dsm/p86ipsl/bin/dods_rm public/${LOGIN}/${R_DODS}/${1} # > out_dods_rm 2>&1 
     926      status=$? 
     927    else 
     928      /ccc/cont003/home/dsm/p86ipsl/bin/dods_rm public/${LOGIN}/${R_DODS} # > out_dods_rm 2>&1 
     929      status=$? 
     930    fi 
    926931 
    927932#    if [ ${status} -gt 0 ] ; then 
     
    11111116 
    11121117  elif [ ${executionType} -eq 2 ] ; then 
    1113     # MPMD + MPI + OMP 
    1114     sed -e "/::openMPthreads::/d"                  \ 
    1115         -e "s/::JobNumProcTot::/${coreNumber}/"    \ 
    1116       ${file} > ${file}.tmp 
    1117  
     1118    # MPMD + MPI + OMP : mpirun/ccc_mprun/error 
     1119    if ( [ "X${config_UserChoices_ExecutionModeOnCurie}" = "X" ] || [ "X${config_UserChoices_ExecutionModeOnCurie}" = "Xmpirun" ] ) ; then 
     1120      sed -e "/::openMPthreads::/d"                  \ 
     1121          -e "s/::JobNumProcTot::/${coreNumber}/"    \ 
     1122        ${file} > ${file}.tmp 
     1123    elif ( [ "X${config_UserChoices_ExecutionModeOnCurie}" = "Xccc_mprun" ] ) ; then 
     1124      sed -e "/::openMPthreads::/d"                  \ 
     1125          -e "s/::JobNumProcTot::/${coreNumber}/"    \ 
     1126          -e "/--cpu_bind=none/d"                    \ 
     1127        ${file} > ${file}.tmp 
     1128    else 
     1129     IGCM_debug_Print 1 "You have to set ExecutionModeOnCurie=ccc_mprun or mpirun in config.card" 
     1130     IGCM_debug_Exit "IGCM_sys_updateHeaders" 
     1131    fi 
    11181132  elif [ ${executionType} -eq 3 ] ; then 
    11191133    # SPMD + MPI/OMP 
     
    11841198  EXECUTION=${HOST_MPIRUN_COMMAND} 
    11851199 
    1186   # MPMD mode 
    11871200  if ( ${OK_PARA_MPMD} ) ; then 
    11881201 
    1189     # Only MPI (MPMD) 
     1202    # MPMD mode 
     1203    # 1 MPI only 
     1204    # 2 MPI/OpenMP mpirun method 
     1205    # 3 MPI/OpenMP ccc_mprun method 
     1206 
     1207    if [ -f run_file ] ; then 
     1208      IGCM_sys_Rm -f run_file 
     1209    fi 
     1210    touch run_file 
     1211 
     1212    # case 1 : Only MPI (MPMD) 
    11901213    if  ( ! ${OK_PARA_OMP} ) ; then 
    1191  
    1192       if [ -f run_file ] ; then 
    1193         IGCM_sys_Rm -f run_file 
    1194       fi 
    1195       touch run_file 
    11961214 
    11971215      # Build run_file 
     
    12361254      fi 
    12371255 
    1238     # MPI-OpenMP (MPMD) 
    1239     else 
     1256    elif ( [ "X${config_UserChoices_ExecutionModeOnCurie}" = "X" ] || [ "X${config_UserChoices_ExecutionModeOnCurie}" = "Xmpirun" ] ) ; then 
     1257 
     1258    # 2 MPI/OpenMP mpirun method 
    12401259 
    12411260      # Use of mpirun instead of ccc_mprun 
     
    13091328 
    13101329          #echo "./${ExeNameOut}" >> script_${ExeNameOut}.ksh 
    1311           echo "(( MYMPIRANK = OMPI_COMM_WORLD_RANK )) " >> script_${ExeNameOut}.ksh 
    1312           echo "MYMPIRANK=\$(printf '%3.3d\n' \${MYMPIRANK})" >> script_${ExeNameOut}.ksh 
    1313           echo "./${ExeNameOut} > out_${ExeNameOut}.out.\${MYMPIRANK} 2>out_${ExeNameOut}.err.\${MYMPIRANK}" >> script_${ExeNameOut}.ksh 
    1314           IGCM_sys_Chmod u+x script_${ExeNameOut}.ksh 
     1330          echo "(( MYMPIRANK = OMPI_COMM_WORLD_RANK )) " >> script_${ExeNameOut}.ksh 
     1331          echo "MYMPIRANK=\$(printf '%3.3d\n' \${MYMPIRANK})" >> script_${ExeNameOut}.ksh 
     1332          echo "./${ExeNameOut} > out_${ExeNameOut}.out.\${MYMPIRANK} 2>out_${ExeNameOut}.err.\${MYMPIRANK}" >> script_${ExeNameOut}.ksh 
     1333          IGCM_sys_Chmod u+x script_${ExeNameOut}.ksh 
    13151334 
    13161335          if [ ${init_exec} = y ] ; then 
     
    13521371        fi 
    13531372      done 
    1354     fi 
    1355  
     1373 
     1374    elif ( [ "X${config_UserChoices_ExecutionModeOnCurie}" = "Xccc_mprun" ] ) ; then 
     1375 
     1376    # 3 MPI/OpenMP ccc_mprun method 
     1377 
     1378    # MPI-OpenMP (MPMD) 
     1379    # example of run_file 
     1380    # 71-8 env OMP_NUM_THREADS=8 ./script_lmdz.x.ksh 
     1381    # 480-1 env OMP_NUM_THREADS=1 ./script_opa.xx.ksh 
     1382    # 1-1 env OMP_NUM_THREADS=1 ./script_xios.x.ksh 
     1383 
     1384      # Loop on the components 
     1385      for comp in ${config_ListOfComponents[*]} ; do 
     1386 
     1387        eval ExeNameIn=\${config_Executable_${comp}[0]} 
     1388        eval ExeNameOut=\${config_Executable_${comp}[1]} 
     1389 
     1390        # Not possible if oasis has an executable (i.e old version of oasis3) 
     1391        if ( [ "X${ExeNameOut}" != X\"\" ] &&  [ "X${comp}" = "XCPL" ] ) ; then 
     1392          IGCM_debug_Exit "ERROR MPMD with hybrid MPI-OpenMP is not available with oasis3 version" 
     1393          IGCM_debug_Print 2 "Only available with oasis3-MCT version coupler" 
     1394          IGCM_debug_Verif_Exit 
     1395        fi 
     1396 
     1397        # Only if we really have an executable for the component : 
     1398        if [ "X${ExeNameOut}" != X\"\" ] ; then 
     1399 
     1400          eval comp_proc_mpi_loc=\${${comp}_PROC_MPI} 
     1401          eval comp_proc_omp_loc=\${${comp}_PROC_OMP} 
     1402 
     1403          # Build script files 
     1404 
     1405          echo "#!/bin/ksh" > script_${ExeNameOut}.ksh 
     1406          echo ""  >> script_${ExeNameOut}.ksh 
     1407          if [ ${comp_proc_omp_loc} -gt 1 ] ; then 
     1408 
     1409            # Check if the number of threads is correct 
     1410            case ${comp_proc_omp_loc} in 
     1411            2|4|8|16) 
     1412              IGCM_debug_Print 1 "You run ${ExeNameOut} on ${comp_proc_omp_loc} OMP threads" 
     1413              ;; 
     1414            *) 
     1415              IGCM_debug_Exit "ERROR with OMP parameters !" 
     1416              IGCM_debug_Print 2 "${comp_proc_omp_loc} is not possible as number of OMP threads" 
     1417              IGCM_debug_Print 2 "Only 2,4,8,16 as number of OMP threads are possible " 
     1418              IGCM_debug_Verif_Exit 
     1419              ;; 
     1420            esac 
     1421            ### only for LMDZ? 
     1422            echo "export KMP_STACKSIZE=3g"  >> script_${ExeNameOut}.ksh 
     1423            echo "export KMP_LIBRARY=turnaround"  >> script_${ExeNameOut}.ksh 
     1424            echo "export MKL_SERIAL=YES"  >> script_${ExeNameOut}.ksh 
     1425            echo "OMP_NUM_THREADS=${comp_proc_omp_loc}" >> script_${ExeNameOut}.ksh 
     1426 
     1427          fi 
     1428 
     1429          # to have out/err per process on different files 
     1430          echo "./${ExeNameOut} > out_${ExeNameOut}.out.\${SLURM_PROCID} 2>out_${ExeNameOut}.err.\${SLURM_PROCID}" >> script_${ExeNameOut}.ksh 
     1431          #echo "./${ExeNameOut}" >> script_${ExeNameOut}.ksh 
     1432 
     1433          IGCM_sys_Chmod u+x script_${ExeNameOut}.ksh 
     1434 
     1435          # Complete run_file 
     1436 
     1437          echo "${comp_proc_mpi_loc}-${comp_proc_omp_loc} env OMP_NUM_THREADS=${comp_proc_omp_loc} ./script_${ExeNameOut}.ksh " >>run_file 
     1438 
     1439        fi 
     1440      done 
     1441 
     1442      ## variable added to stop after 60s instead of 600s by default.  
     1443      ## This is used when no error comes from executables and when something stopped an executable without notice.  
     1444      export SLURM_WAIT=60 
     1445 
     1446      ## module advised by TGCC (instead of 2 variables) 
     1447      module load feature/bridge/heterogenous_mpmd 
     1448 
     1449      # set EXECUTION for ccc_mprun case (similar to #1 : MPI only MPMD method)  
     1450 
     1451      EXECUTION="${HOST_MPIRUN_COMMAND} -f ./run_file" 
     1452 
     1453      IGCM_sys_Chmod u+x run_file 
     1454      if ( $DEBUG_sys ) ; then 
     1455        echo "run_file contains : " 
     1456        cat run_file 
     1457      fi 
     1458 
     1459    else 
     1460 
     1461      IGCM_debug_Print 1 "sys Curie :  choose mpirun or ccc_mprun in config.card for ExecutionModeOnCurie" 
     1462 
     1463    fi # 1 2 or 3 if ${OK_PARA_MPMD} 
     1464 
     1465  else 
    13561466  # Only one executable (SPMD mode). 
    1357   else 
    13581467 
    13591468    for comp in ${config_ListOfComponents[*]} ; do 
     
    13621471      eval ExeNameOut=\${config_Executable_${comp}[1]} 
    13631472      if ( [ "X${ExeNameOut}" != X\"\" ] && [ "X${ExeNameOut}" != "Xinca.dat" ] ) ; then 
     1473 
     1474        # Build script files 
    13641475 
    13651476        echo "#!/bin/ksh" > script_${ExeNameOut}.ksh 
     
    13981509    done 
    13991510 
    1400   fi 
     1511  fi # ${OK_PARA_MPMD} 
    14011512 
    14021513  IGCM_debug_Print 1 "sys Curie : execution command is " 
     
    16891800} 
    16901801 
     1802#D-#================================================== 
     1803#D-function IGCM_sys_rebuild_nemo 
     1804#D-* Purpose: rebuild nemo parallel files with nemo specific rebuild on curie 
     1805#D-* Examples: 
     1806#D- 
     1807 
     1808function IGCM_sys_rebuild_nemo { 
     1809  IGCM_debug_PushStack "IGCM_sys_rebuild_nemo" $@ 
     1810  if ( $DEBUG_sys ) ; then 
     1811    echo "IGCM_sys_rebuild_nemo :" $@ 
     1812  fi 
     1813 
     1814  $( ccc_home -u p86ipsl )/REBUILD_NEMO/rebuild_nemo ${1} ${2} 
     1815 
     1816  IGCM_debug_PopStack "IGCM_sys_rebuild_nemo" 
     1817} 
     1818 
  • tags/libIGCM_v3.0_beta1/libIGCM_sys/libIGCM_sys_default.ksh

    r1318 r1399  
    11721172} 
    11731173 
     1174#D-#================================================== 
     1175#D-function IGCM_sys_rebuild_nemo 
     1176#D-* Purpose: rebuild nemo parallel files with general rebuild 
     1177#D-* Examples: 
     1178#D- 
     1179 
     1180function IGCM_sys_rebuild_nemo { 
     1181  IGCM_debug_PushStack "IGCM_sys_rebuild_nemo" $@ 
     1182  if ( $DEBUG_sys ) ; then 
     1183    echo "IGCM_sys_rebuild_nemo :" $@ 
     1184  fi 
     1185 
     1186  nemo_generic_restart_file_name_out=${1} 
     1187  nemo_extension_out=${3} 
     1188  shift ; shift ; shift 
     1189 
     1190  IGCM_sys_rebuild -o ${nemo_generic_restart_file_name_out}.${nemo_extension_out} $@ 
     1191 
     1192  IGCM_debug_PopStack "IGCM_sys_rebuild_nemo" 
     1193} 
     1194 
  • tags/libIGCM_v3.0_beta1/libIGCM_sys/libIGCM_sys_iitm.ksh

    r1244 r1399  
    10301030  IGCM_debug_PopStack "IGCM_sys_CountJobInQueue" 
    10311031} 
     1032 
     1033#D-#================================================== 
     1034#D-function IGCM_sys_rebuild_nemo 
     1035#D-* Purpose: rebuild nemo parallel files with general rebuild 
     1036#D-* Examples: 
     1037#D- 
     1038 
     1039function IGCM_sys_rebuild_nemo { 
     1040  IGCM_debug_PushStack "IGCM_sys_rebuild_nemo" $@ 
     1041  if ( $DEBUG_sys ) ; then 
     1042    echo "IGCM_sys_rebuild_nemo :" $@ 
     1043  fi 
     1044 
     1045  nemo_generic_restart_file_name_out=${1} 
     1046  nemo_extension_out=${3} 
     1047  shift ; shift ; shift 
     1048 
     1049  IGCM_sys_rebuild -o ${nemo_generic_restart_file_name_out}.${nemo_extension_out} $@ 
     1050 
     1051  IGCM_debug_PopStack "IGCM_sys_rebuild_nemo" 
     1052} 
     1053 
     1054 
  • tags/libIGCM_v3.0_beta1/libIGCM_sys/libIGCM_sys_obelix.ksh

    r1360 r1399  
    11951195} 
    11961196 
     1197 
     1198#D-#================================================== 
     1199#D-function IGCM_sys_rebuild_nemo 
     1200#D-* Purpose: rebuild nemo parallel files with general rebuild 
     1201#D-* Examples: 
     1202#D- 
     1203 
     1204function IGCM_sys_rebuild_nemo { 
     1205  IGCM_debug_PushStack "IGCM_sys_rebuild_nemo" $@ 
     1206  if ( $DEBUG_sys ) ; then 
     1207    echo "IGCM_sys_rebuild_nemo :" $@ 
     1208  fi 
     1209 
     1210  nemo_generic_restart_file_name_out=${1} 
     1211  nemo_extension_out=${3} 
     1212  shift ; shift ; shift 
     1213 
     1214  IGCM_sys_rebuild -o ${nemo_generic_restart_file_name_out}.${nemo_extension_out} $@ 
     1215 
     1216  IGCM_debug_PopStack "IGCM_sys_rebuild_nemo" 
     1217} 
     1218 
Note: See TracChangeset for help on using the changeset viewer.