New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
Changeset 13676 for NEMO/branches/2020/dev_r13648_ASINTER-04_laurent_bulk_ice/tests/STATION_ASF/EXPREF/launch_sasf.sh – NEMO

Ignore:
Timestamp:
2020-10-26T17:56:37+01:00 (3 years ago)
Author:
laurent
Message:

Setting up the new STATION_ASF with sea-ice support

File:
1 edited

Legend:

Unmodified
Added
Removed
  • NEMO/branches/2020/dev_r13648_ASINTER-04_laurent_bulk_ice/tests/STATION_ASF/EXPREF/launch_sasf.sh

    r13675 r13676  
    1212 
    1313CONFIG="STATION_ASF" ; # general name of the configuration 
    14 CONFIG_BLD="STATION_ASF" ; # name of config as build in NEMO... (directory inside "tests" actually contains the compiled test-case?) 
     14CONFIG_BLD="STATION_ASF2" ; # name of config as build in NEMO... (directory inside "tests" actually contains the compiled test-case?) 
    1515 
    1616# Root directory NEMOGCM reference depository where to fetch compiled STATION_ASF nemo.exe + default namelists: 
    1717NEMO_REF_DIR="/home/laurent/DEV/NEMO/NEMOGCM_dev_r13648_ASINTER-04_laurent_bulk_ice" 
    18 NEMO_WRK_DIR="/home/laurent/NEMO/NEMOvdev_r13648_ASINTER-04_laurent_bulk_ice" 
    1918 
    2019# NEMOGCM root directory where to fetch compiled STATION_ASF nemo.exe: 
    21 SASF_WRK_DIR="${NEMO_WRK_DIR}/tests/${CONFIG_BLD}" 
     20SASF_WRK_DIR="${NEMO_REF_DIR}/tests/${CONFIG_BLD}" 
     21 
     22# DATA_IN_DIR => Directory containing sea-surface + atmospheric forcings: 
     23DATA_IN_DIR="${NEMO_REF_DIR}/tests/${CONFIG}/input_data" 
    2224 
    2325# Directory where to run the simulation: 
     
    3032i_sea_ice=0 ; # default does not compute fluxes over sea-ice 
    3133# 
    32 NFORC="ERA5_arctic" ; i_sea_ice=1 ; FORC="ERA5_arctic_surface_81N_36p75E_1h" ; # string sufficient to copy relevant files as in "*${FORC}*.nc" 
    33  
    34 #NFORC="PAPA" ; FORC="Station_PAPA_50N-145W" ; # string sufficient to copy relevant files as in "*${FORC}*.nc" 
     34#NFORC="ERA5_arctic" ; i_sea_ice=1 ; FORC="ERA5_arctic_surface_81N_36p75E_1h" ; # string sufficient to copy relevant files as in "*${FORC}*.nc" 
     35NFORC="PAPA" ; FORC="Station_PAPA_50N-145W" ; # string sufficient to copy relevant files as in "*${FORC}*.nc" 
    3536 
    3637 
     
    4041 
    4142#================================================================================ 
     43 
     44if [ "`which ncks`" = "" ]; then 
     45    echo 
     46    echo "WARNING: you do not seem to have NCO installed here... You should!" 
     47    echo "      => anyway! will do without, output fields will remaine 3x3 in space :( " 
     48    echo 
     49    sleep 4 
     50fi 
     51 
    4252HERE=`pwd` 
    4353 
     
    6878    LIST_OA_ALGOS="ECMWF" ;          # list of air-sea algorithms to test 
    6979    LIST_IA_ALGOS="LG15 LU12 CSTC" ; # list of air-ice algorithms to test 
    70     DIR_NL=${NFORC}/ice ; # where to get the namelists from... 
     80    DIR_NL=${NFORC}/ice ; # where to fetch the namelists from... 
    7181else 
    7282    # Only OPEN-OCEAN/AIR flux computation 
    73     LIST_OA_ALGOS="NCAR ECMWF" ; # "NCAR ECMWF COARE3p6"; do   ; # list of air-sea algorithms to test 
     83    LIST_OA_ALGOS="NCAR ECMWF COARE3p6 ANDREAS"; # list of air-sea algorithms to test 
    7484    LIST_IA_ALGOS="" 
    75     DIR_NL=${NFORC}/oce ; # where to get the namelists from... 
     85    DIR_NL=${NFORC}/oce ; # where to fetch the namelists from... 
    7686fi 
    7787if [ ! -d ${DIR_NL} ]; then echo " Mhhh, seems like forcing ${NFORC} is not meant to be used with sea-ice/air flux computation !"; exit; fi 
     
    8696 
    8797 
    88 # DATA_IN_DIR => Directory containing sea-surface + atmospheric forcings 
    89 #             (get it there https://drive.google.com/file/d/1MxNvjhRHmMrL54y6RX7WIaM9-LGl--ZP/): 
    90 if [ `hostname` = "merlat"        ]; then 
    91     DATA_IN_DIR="/MEDIA/data/STATION_ASF/input_data" 
    92 elif [ `hostname` = "luitel"        ]; then 
    93     DATA_IN_DIR="/data/gcm_setup/STATION_ASF/input_data" 
    94 elif [ `hostname` = "ige-meom-cal1" ]; then 
    95     DATA_IN_DIR="/mnt/meom/workdir/brodeau/STATION_ASF/input_data" 
    96 elif [ `hostname` = "salvelinus" ]; then 
    97     DATA_IN_DIR="/opt/data/STATION_ASF/input_data" 
    98 else 
    99     echo "Boo!"; exit 
    100 fi 
    10198if [ ! -d ${DATA_IN_DIR} ]; then echo "PROBLEM!!! => did not find directory 'input_data' with input forcing..."; exit; fi 
    10299 
     
    164161if [ "${LIST_IA_ALGOS}" = "" ]; then LIST_IA_ALGOS="none"; fi 
    165162 
    166 echo " {LIST_OA_ALGOS} = ${LIST_OA_ALGOS} !" 
    167 echo " {LIST_IA_ALGOS} = ${LIST_IA_ALGOS} !" 
     163echo 
    168164 
    169165for OA_A in ${LIST_OA_ALGOS}; do 
    170166    for IA_A in ${LIST_IA_ALGOS}; do 
    171          
     167 
     168        echo         
    172169        CASE="${OA_A}" 
    173170        if [ ${i_sea_ice} -eq 1 ] && [ "${IA_A}" != "none" ]; then CASE="${OA_A}-${IA_A}"; fi 
    174171 
    175172        echo ; echo 
    176         echo "====================================" 
    177         echo " Going for ${CASE} experiment" 
    178         echo "====================================" 
     173        echo "=======================================================================" 
     174        echo " Going for experiment: ${CASE} bulk param. with ${NFORC} forcing " 
     175        echo "=======================================================================" 
    179176        echo 
    180177 
     
    204201        # Moving output files: 
    205202        mkdir -p output 
    206         mv -f ${CONFIG}-${CASE}_*_grid*.nc output/ 
    207         if [ ${i_sea_ice} -eq 1 ]; then mv -f ${CONFIG}-${CASE}_*_icemod.nc output/; fi 
     203        mv -f ${CONFIG}-${CASE}_${NFORC}_*_grid*.nc output/ 
     204        if [ ${i_sea_ice} -eq 1 ]; then mv -f ${CONFIG}-${CASE}_${NFORC}_*_icemod.nc output/; fi 
    208205 
    209206        # Saving logs: 
     
    213210        # Making 3x3 to 1 ! 
    214211        cd output/ 
    215         mkdir -p 3x3 
    216         list=`\ls ${CONFIG}*${CASE}*.nc | grep -v '_restart_'` 
     212        list=`\ls ${CONFIG}*${CASE}_${NFORC}_*.nc | grep -v '_restart_'| grep -v '_1p.nc'` 
    217213        for ff in ${list}; do 
    218214            echo 
    219             fn=`echo ${ff} | sed -e "s|.nc|_${NFORC}_1p.nc|g"` 
    220             fb=`echo ${ff} | sed -e "s|.nc|_${NFORC}.nc|g"` 
     215            fn=`echo ${ff} | sed -e "s|.nc|_1p.nc|g"` 
    221216            CMD="ncks -O -d x,1 -d y,1 ${ff} -o ${fn}" 
    222217            echo " *** ${CMD}"; ${CMD} 
    223             mv -f ${ff} 3x3/${fb} 
    224218            echo 
    225219        done 
Note: See TracChangeset for help on using the changeset viewer.