Ignore:
Timestamp:
Nov 9, 2022, 3:27:12 PM (2 years ago)
Author:
musat
Message:

Ajout environnement et corrections

  • champ eva(poration) moyennes zonales
  • pour les appels a des fonctions climaf via mcdo (timavg, sqrt)

IonelaMusat?

File:
1 edited

Legend:

Unmodified
Added
Removed
  • BOL/Multi_atlas/METRICS/metrics.sh

    r4306 r4330  
    11#!/bin/bash
    22
    3 login=`whoami`
    4 
    5 hostname=`hostname`
    6 if [ ${hostname:0:5} = cicla ] ; then
    7 DODSDIR=/thredds/ipsl
    8 fi
    9 if [ ${hostname:0:5} = camel ] ; then
    10 DODSDIR=/thredds/ipsl
    11 fi
    12 if [ ${hostname:0:5} = irene ] ; then
    13 DODSDIR=
    14 fi
    15 if [ ${hostname:0:5} = jean- ] ; then
    16 DODSDIR=
    17 fi
    18 
    19 set -vx
     3source ../env.sh
     4
     5#set -vx
    206force_create=1
    217
    228comp=$1
    23 local=`pwd`
     9local=`pwd -P`
    2410
    2511for season in YEAR DJF JJA ; do
    26 
    2712
    2813cd $local
     
    4732   COMP_D=$DODSDIR/$login/lmdz/MultiSimu/$comp
    4833   CMOR_DIR=$DODSDIR/$login/lmdz/VLR/$season
     34   echo COMP_D $COMP_D CMOR_DIR $CMOR_DIR
    4935elif [ "$comp" = "$1" ] ; then
    5036   # Installation locale
     
    6046# Liste des simulations de la comparasion $comp
    6147listsims="" ; listsimsy=""
     48
    6249DEF_FILE=$COMP_D/def.txt ; if [ ! -f "$DEF_FILE" ] ; then renseigner $DEF_FILE ; exit ; fi
    6350for s in `awk ' {print $1"_"$2 } ' $DEF_FILE` ; do listsimsy="$listsimsy $s" ; done
     
    7461  echo years $years
    7562
    76 
    7763  SIM_DIR=$CMOR_DIR/$GR/$sim$years
    78 ETOA_DIR=$SIM_DIR/METRICS
    79 
     64  ETOA_DIR=$SIM_DIR/METRICS
    8065
    8166   for mask in $masks ; do
     
    8671        if [ ! -d $SIM_DIR ] ; then echo $SIM_DIR absent ; exit ; fi
    8772        set +e ; \rm resu$sim ; set -e
    88         for var in rsut clhcalipso cllcalipso clmcalipso cltcalipso clt hfls eva hfss hurs huss pr ts tas sst psl rldscs rlds rlus rlutcs rlut rsdscs rsds rsdt rsuscs rsus rsutcs prw ; do
     73        for var in rsut clhcalipso cllcalipso clmcalipso cltcalipso clt hfls hfss hurs huss pr ts tas sst psl rldscs rlds rlus rlutcs rlut rsdscs rsds rsdt rsuscs rsus rsutcs prw ; do
    8974          if [ -f "$SIM_DIR/NC/$var.nc" ] ; then
    9075           if [ "$mask" = "glob" ] ; then
     
    118103      rlutcs=`grep '^rlutcs ' $xmgr | awk ' { print $2 } '`
    119104      hfls=`grep '^hfls ' $xmgr | awk ' { print $2 } '`
    120       eva=`grep '^eva ' $xmgr | awk ' { print $2 } '`
    121105      hfss=`grep '^hfss ' $xmgr | awk ' { print $2 } '`
    122106      rlds=`grep '^rlds ' $xmgr | awk ' { print $2 } '`
     
    128112      rsuscs=`grep '^rsuscs ' $xmgr | awk ' { print $2 } '`
    129113      rsdt=`grep '^rsdt ' $xmgr | awk ' { print $2 } '`
     114      echo $hfls | awk ' { print "eva"  , $1 * 0.03456 } ' >> $xmgr
    130115      echo $rsut $rsutcs | awk ' { print "crest" , $2 - $1 } ' >> $xmgr
    131116      echo $rlut $rlutcs | awk ' { print "crelt" , $2 - $1 } ' >> $xmgr
     
    160145# Tracers
    161146#########################################################################################
    162 
    163 
    164147
    165148cat <<eod>| descr
Note: See TracChangeset for help on using the changeset viewer.