source: BOL/Multi_atlas/getun_SE.sh @ 4179

Last change on this file since 4179 was 3684, checked in by idelkadi, 5 years ago

Repository under svn of a first version of Multiatlas diagnostics for LMDZ. This version is adapted to be able to run a LMDZ multiatlas on an individual account on the ciclad machine of the IPSL. In this version, the parts to be modified are identified so as to subsequently adapt it to other machines.
This version is still under development.

  • Property svn:executable set to *
File size: 6.8 KB
Line 
1#!/bin/bash
2
3#http://dods.extra.cea.fr/store/aidel/LMDZOR/DEVT/clim/NPv5.50/ATM/Analyse/SE/NPv5.50_SE_1982_1989_1M_histmth.nc
4
5mkdir -p WORK$$
6cd WORK$$
7wget="wget -t 1"
8
9simu=$1
10echo simu $simu
11run=`echo $simu | sed -e 's/_[0-9][0-9][0-9][0-9]_[0-9][0-9][0-9][0-9]//'`
12
13echo run $run
14runstxt=/home/fabric/LMDZ/MultiSimu/runs.txt
15simdir=`grep -w "^$run " $runstxt | awk ' { print $2 } '`
16echo simdir $simdir
17sim=`basename $simdir `
18
19years=`echo $simu | sed -e 's/'$run'//' | sed -e 's/_//'`
20echo years $years
21runu=${sim}_SE_$years
22
23echo runu $runu
24
25for file in ${runu}_1M_histmth.nc  ${runu}_1M_histmthCOSP.nc  ; do
26
27sim=` echo $file | sed -e 's/_SE_.*..nc//'`
28
29echo AVANT SIM $sim $file
30
31echo $simdir/ATM/Analyse/SE/$file
32
33if [ ! -f $simdir/ATM/Analyse/SE/$file ] ; then
34echo OK
35
36echo APRES SIM $sim $file
37echo sim ${sim:0:4}
38
39if [ "${sim:0:2}" = "MR" ] ; then
40   $wget http://dodsp.idris.fr/rdzt401/MTH/$file
41elif [ "${sim}" = "CM605-LR-sstClim-01" ] ; then
42     $wget https://esgf.extra.cea.fr/thredds/fileServer/store_thredds/p86denv/IPSLCM6/PROD/clim/$sim/ATM/Analyse/SE/$file
43elif [ "${sim:0:5}" = "CM605" ] ; then
44    case $sim in
45        CM605-LR-pdCtrl-01|CM605.THC1-LR-pdCtrl-01) login=p86caub ;;
46        CM605.calv-LR-pdCtrl-02|CM605.dt20-LR-pdCtrl-02) login=p86mart ;;
47        CM605.NOSU-LR-pdCtrl-02|CM605.NOSU-LR-pdCtrl-03) login=p86maf ;;
48        CM605.Z0-LR-pdCtrl-01|CM605.GUST-LR-pdCtrl-01) login=p529tra ;;
49        *) exit
50    esac
51    $wget https://esgf.extra.cea.fr/thredds/fileServer/store_thredds/$login/IPSLCM6/DEVT/pdControl/$sim/ATM/Analyse/SE/$file
52elif [ "${sim:0:4}" = "NPv5" ] ; then
53      if [ "${sim:0:6}" = "NPv5.8" ] || [ "$sim" = "NPv5.70svn2685" ] || [ "$sim" = "NPv5.MixAdiab" ] || [ "$sim" = "NPv5.V5.70Orolf" ] || [ "$sim" = "NPv5.70OrodrOrolf" ] || [ "$sim" = "NPv5.vn2709" ] || [ "$sim" = "NPv5.vn2709cv72" ] ; then 
54         echo $wget https://esgf.extra.cea.fr/thredds/fileServer/store_thredds/aidel/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/EXTR/$file
55         $wget https://esgf.extra.cea.fr/thredds/fileServer/store_thredds/aidel/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/EXTR/$file
56      else
57         echo $wget http://esgf.extra.cea.fr/thredds/fileServer/store/aidel/LMDZOR/DEVT/clim//$sim/ATM/Analyse/SE/EXTR/$file
58         $wget $wget http://esgf.extra.cea.fr/thredds/fileServer/store/aidel/LMDZOR/DEVT/clim//$sim/ATM/Analyse/SE/EXTR/$file
59      fi
60elif [ "${sim:0:4}" = "LMDZ" ] ; then       
61     echo $wget https://esgf.extra.cea.fr/thredds/fileServer/store_thredds/aidel/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/EXTR/$file
62     $wget https://esgf.extra.cea.fr/thredds/fileServer/store_thredds/aidel/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/EXTR/$file
63   # $wget http://dods.extra.cea.fr/store/aidel/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/$file
64   #$wget https://esgf.extra.cea.fr/thredds/fileServer/store/aidel/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/$file
65   #$wget https://esgf.extra.cea.fr/thredds/fileServer/store_thredds/aidel/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/EXTR/$file
66elif [ "${sim:0:7}" = "NPv4.12" ] ; then
67   $wget http://dodsp.idris.fr/rlmd093/IGCM_OUT/LMDZOR/DEVT/clim/$sim/ATM/Analyse/SE/$file
68elif [ "${sim:0:8}" = "AR4.0ada" -o "${sim:0:9}" = "NPv3.1ada" ] ; then
69   $wget http://dodsp.idris.fr/rlmd093/IGCM_OUT/LMDZOR/DEVT/CLIM/$sim/ATM/Analyse/SE/$file
70elif [ "${sim:0:6}" = "CPL6v5" ] ; then
71   $wget http://dods.extra.cea.fr/store/p86fair/IPSLCM6/PROD/piControl/$sim/ATM/Analyse/SE/$file
72elif [ "${sim:0:16}" = "v5.5pftXORCA1V01" ] ; then
73   $wget http://dods.extra.cea.fr/store/p86fair/IPSLCM6/PROD/piControl/${sim}_tmp/ATM/Analyse/SE/$file
74elif [ "${sim:0:18}" = "CL5.CWRR90mSu.3607" ] ; then
75   $wget http://esgf.extra.cea.fr/thredds/fileServer/store/p86ghatt/LMDZOR/PROD/ref3607/${sim}/ATM/Analyse/SE/$file
76elif [ "${sim:0:22}" = "CL5.CWRR90msnowSu.3607" ] ; then
77   $wget http://esgf.extra.cea.fr/thredds/fileServer/store/p86ghatt/LMDZOR/PROD/ref3607/${sim}/ATM/Analyse/SE/$file
78elif [ "${sim:0:16}" = "CL5.CWRRcSu.3607" ] ; then
79   $wget http://esgf.extra.cea.fr/thredds/fileServer/store/p86ghatt/LMDZOR/PROD/ref3607/${sim}/ATM/Analyse/SE/$file
80elif [ "${sim:0:22}" = "CL5.CWRR90msnowZ0.3607" ] ; then
81   $wget http://esgf.extra.cea.fr/thredds/fileServer/store/p86ghatt/LMDZOR/PROD/ref3607/${sim}/ATM/Analyse/SE/$file
82elif [ "${sim:0:18}" = "CL5.CWRR90mZ0.3607" ] ; then
83   $wget http://esgf.extra.cea.fr/thredds/fileServer/store/p86ghatt/LMDZOR/PROD/ref3607/${sim}/ATM/Analyse/SE/$file
84#elif [ "${sim:0:18}" = "CL5.CWRR90mSu.3525" ] ; then
85#   $wget http://dods.extra.cea.fr/store/p86ghatt/LMDZOR/PROD/ref3525/${run}/ATM/Analyse/SE/$file
86#echo OK c est la ; exit
87elif [ "${sim:0:12}" = "v5.5XORCA1V01" ] ; then
88   $wget http://dods.extra.cea.fr/store/p86fair/IPSLCM6/PROD/piControl/${sim}/ATM/Analyse/SE/$file
89elif [ "${sim:0:12}" = "v5.63XORCA1T" ] ; then
90   $wget http://dods.extra.cea.fr/store/p86fair/IPSLCM6/PROD/piControl/${sim}_temp/ATM/Analyse/SE/$file
91elif [ "${sim:0:5}" = "v5.5X" ] ; then
92   $wget http://dods.extra.cea.fr/store/p86fair/IPSLCM6/PROD/piControl/$sim/ATM/Analyse/SE/$file
93elif [ "${sim:0:4}" = "AMIP" ] ; then
94   $wget http://dods.extra.cea.fr/store/mellull/LMDZOR/PROD/amip/$sim/ATM/Analyse/SE/$file
95elif [ "${sim:2:12}" = ".historical1" ] ; then
96   $wget http://dods.extra.cea.fr/store/p86denv/IPSLCM5A/PROD/historical/v3.historical1/ATM/Analyse/SE/$file
97elif [ "${sim:2:8}" = ".histNP1" ] ; then
98   $wget http://dods.extra.cea.fr/store/p86fair/IPSLCM5B/PROD/historical/v5.histNP1/ATM/Analyse/SE/$file
99elif [ "${sim:2:15}" = ".historicalCMR5" ] ; then
100   $wget http://dods.extra.cea.fr/store/p86maf/IPSLCM5A-MR/PROD/historical/v5.historicalCMR5/ATM/Analyse/SE/$file
101elif [ "${sim:0:11}" = "ADA2016COMP" ] ; then
102   $wget http://dods.idris.fr/rlmd007/LMDZOR/PROD/clim/$sim/ATM/Analyse/SE/$file
103elif [ "${sim:0:7}" = "MP65vd2" ] ; then
104   $wget http://dods.extra.cea.fr/store/p86musat/Tuning_runs/tun141479_svn2574_xios2/$sim/$file
105elif [ "${sim:0:7}" = "MP68vd2" ] ; then
106   $wget http://dods.extra.cea.fr/store/p86musat/Tuning_runs/tun141479_svn2574_xios2/$sim/$file
107elif [ "${sim:0:2}" = "T0" ] ; then
108   fileb=`echo $file | sed -e 's/T0//'`
109   simb=`echo $sim | sed -e 's/T0//'`
110   echo FILEB $fileb
111   $wget http://dods.extra.cea.fr/store/p86musat/Tuning_runs/tun141479_svn2468/$simb/$fileb
112   \mv -f $fileb $file
113else
114   echo Cas non prevu
115   exit
116fi
117
118fi
119
120runstxt=/home/fabric/LMDZ/MultiSimu/runs.txt
121simdir=`grep -w "$sim" $runstxt | awk ' { print $2 } '`
122
123echo simdir $simdir
124
125if [ ! -d $simdir/ATM/Analyse/SE ] ; then
126mkdir -p $simdir/ATM/Analyse/SE
127fi 
128
129if [ -f $file -a ! -f $simdir/ATM/Analyse/SE/$file ] ; then
130   chmod +x $file
131   var=`ncdump -h $file | \\
132    grep float | sed -e 's/(/ /' -e 's/float.//' -e '/OD550_STRAT/d' | \\
133    awk ' BEGIN{ liste="" } { liste=liste","$1 } END { print liste } '`
134   echo $var 
135   cdo selvar,$var $file $simdir/ATM/Analyse/SE/$file
136#   \rm -r $file
137else
138   echo $file not found
139fi
140
141done
Note: See TracBrowser for help on using the repository browser.