/[lmdze]/trunk/Scripts/gcm.sh
ViewVC logotype

Annotation of /trunk/Scripts/gcm.sh

Parent Directory Parent Directory | Revision Log Revision Log


Revision 12 - (hide annotations)
Mon Jul 21 16:05:07 2008 UTC (15 years, 10 months ago) by guez
File MIME type: application/x-sh
File size: 2516 byte(s)
-- Minor modification of input/output:

Created procedure "read_logic". Variables of module "logic" are read
by "read_logic" instead of "conf_gcm". Variable "offline" of module
"conf_gcm" is read from namelist instead of "*.def".

Deleted arguments "dtime", "co2_ppm_etat0", "solaire_etat0",
"tabcntr0" and local variables "radpas", "tab_cntrl" of
"phyetat0". "phyetat0" does not read "controle" in "startphy.nc" any
longer. "phyetat0" now reads global attribute "itau_phy" from
"startphy.nc". "phyredem" does not create variable "controle" in
"startphy.nc" any longer. "phyredem" now writes global attribute
"itau_phy" of "startphy.nc". Deleted argument "tabcntr0" of
"printflag". Removed diagnostic messages written by "printflag" for
comparison of the variable "controle" of "startphy.nc" and the
variables read from "*.def" or namelist input.

-- Removing unwanted functionality:

Removed variable "lunout" from module "iniprint", replaced everywhere
by standard output.

Removed case "ocean == 'couple'" in "clmain", "interfsurf_hq" and
"physiq". Removed procedure "interfoce_cpl".

-- Should not change anything at run time:

Automated creation of graphs in documentation. More documentation on
input files.

Converted Fortran files to free format: "phyredem.f90", "printflag.f90".

Split module "clesphy" into "clesphys" and "clesphys2".

Removed variables "conser", "leapf", "forward", "apphys", "apdiss" and
"statcl" from module "logic". Added arguments "conser" to "advect",
"leapf" to "integrd". Added local variables "forward", "leapf",
"apphys", "conser", "apdiss" in "leapfrog".

Added intent attributes.

Deleted arguments "dtime" of "phyredem", "pdtime" of "flxdtdq", "sh"
of "phytrac", "dt" of "yamada".

Deleted local variables "dtime", "co2_ppm_etat0", "solaire_etat0",
"length", "tabcntr0" in "physiq". Replaced all references to "dtime"
by references to "pdtphys".

1 guez 3 # This is a script in Bash.
2    
3     # This script collects input files necessary for the program "gcm" and
4     # runs "gcm". Run this script in the directory where you want "gcm" to run.
5     # The "ln" command does not report missing targets, so we check them first.
6    
7     trap 'echo -e \\a; exit 1' ERR
8    
9     # Specify directories:
10    
11 guez 12 REL_dir=/usr/local/guez/LMDZE_work/Results_etat0_lim
12 guez 3 ##REL_dir=$workdir/LMDZE/Results_etat0_lim
13    
14     IGCM_dir=~/Documents/Utilisation_LMDZ/Input_gcm
15     ##IGCM_dir=~
16    
17 guez 12 executable_dir=/usr/local/guez/LMDZE_work/Compil_prod_g95
18 guez 3 ##executable_dir=$workdir/LMDZE/Compil_prod
19    
20 guez 12 RGCM_dir=/usr/local/guez/LMDZE_work/Results_gcm
21 guez 3 ##RGCM_dir=$workdir/LMDZE/Results_gcm
22     # (used only for a restart or a comparison)
23    
24     set -x
25    
26     test -d $REL_dir
27     test -d $IGCM_dir
28     test -d $executable_dir
29    
30     set +x
31    
32     read -p \
33     "Identifier for the set of parameters (\"*.def\" files and namelists)? " \
34     igcm_id
35     read -p \
36     "Run number of \"etat0_lim\", for \"limit.nc\" and \"coefoz_LMDZ.nc\"? " \
37     numb_cr
38    
39     read -p \
40     "Do you want to restart from the end of a previous \"gcm\" run? (y/[n]) " \
41     restart
42     if [[ $restart = y ]]
43     then
44     echo "Previous run number of \"gcm\" for \"start.nc\" and \"startphy.nc\ ?"
45     read prev_gcm
46     fi
47    
48     set -x
49    
50     my_host=`hostname`
51    
52     if [[ $my_host = vierne ]]
53     then
54     # This is only useful if the program was compiled with G95:
55     G95_FPU_UNDERFLOW=${G95_FPU_UNDERFLOW:+No}
56     G95_FPU_INVALID=${G95_FPU_INVALID:+No}
57     fi
58    
59     test -f $REL_dir/$numb_cr/limit.nc
60 guez 11 ln -f -s $REL_dir/$numb_cr/limit.nc .
61 guez 3
62 guez 11 if [[ -f $REL_dir/$numb_cr/coefoz_LMDZ.nc ]]
63     then
64     ln -f -s $REL_dir/$numb_cr/coefoz_LMDZ.nc .
65     fi
66    
67 guez 3 if [[ $restart != y ]]
68     then
69     # Start-up files come from "etat0_lim":
70     ln -f -s $REL_dir/$numb_cr/start*.nc .
71     else
72     ln -f -s $RGCM_dir/$prev_gcm/restart.nc start.nc
73     ln -f -s $RGCM_dir/$prev_gcm/restartphy.nc startphy.nc
74     fi
75    
76     rm -f *.def
77     test -f $IGCM_dir/$igcm_id/run.def
78     ln -s $IGCM_dir/$igcm_id/*.def .
79     date
80    
81     if [[ $my_host = brodie ]]
82     then
83     rsh brodie01 \
84     export F_PROGINF=YES\; \
85     cd $PWD\; \
86     $executable_dir/gcm <$IGCM_dir/$igcm_id/gcm_nml.txt >gcm_out.txt \
87     2>gcm_err.txt
88     elif [[ $my_host = zahir* ]]
89     then
90     hpmcount $executable_dir/gcm \
91     <$IGCM_dir/$igcm_id/gcm_nml.txt >gcm_out.txt 2>gcm_err.txt
92     else
93     time $executable_dir/gcm \
94     <$IGCM_dir/$igcm_id/gcm_nml.txt >gcm_out.txt 2>gcm_err.txt
95     fi
96    
97     echo -e '\a' # beep
98     set +x
99     read -p "Previous run number for comparison [none] ? "
100     if [[ -n $REPLY ]]
101     then
102     selective_diff.sh $RGCM_dir/$REPLY .
103     fi

Properties

Name Value
svn:eol-style native
svn:executable

  ViewVC Help
Powered by ViewVC 1.1.21