| 1 | #!/bin/bash |
|---|
| 2 | ## Headers managed by sed |
|---|
| 3 | #@JZ#JeanZay |
|---|
| 4 | #@JZ#SBATCH --job-name=NOM_SIMU # nom du job |
|---|
| 5 | #@JZ# Nombre de processus MPI : |
|---|
| 6 | #@JZ#SBATCH --ntasks=8 |
|---|
| 7 | #@JZ##### number of MPI processes per node : 40(procs/node on Jean-Zay) / cpus-per-task (ex : =5 for 8 OMP) |
|---|
| 8 | #@JZ####SBATCH --ntasks-per-node=5 # if specified, also add "#SBATCH --nodes= ..." with nodes=ntasks/(ntasks-per-node) |
|---|
| 9 | #@JZ# nombre de threads OpenMP |
|---|
| 10 | #@JZ#SBATCH --cpus-per-task=8 |
|---|
| 11 | #@JZ# de Slurm "multithread" fait bien reference a l'hyperthreading. |
|---|
| 12 | #@JZ#SBATCH --hint=nomultithread # 1 thread par coeur physique (pas d'hyperthreading) |
|---|
| 13 | #@JZ#SBATCH --time=00:30:00 # Temps d execution maximum demande (HH:MM:SS) |
|---|
| 14 | #@JZ#SBATCH --output=outNOM_SIMU%j # Nom du fichier de sortie |
|---|
| 15 | #@JZ#SBATCH --error=outNOM_SIMU%j # Nom du fichier d'erreur (ici commun avec la sortie) |
|---|
| 16 | #@JZ# To submit to test queue ; "time" (above) must be max 30 min |
|---|
| 17 | #@JZ#TESTQ#SBATCH --qos=qos_cpu-dev |
|---|
| 18 | #@SP#Spirit |
|---|
| 19 | #@SP#SBATCH --job-name=NOM_SIMU |
|---|
| 20 | #@SP#SBATCH --ntasks=8 |
|---|
| 21 | #@SP#SBATCH --cpus-per-task=8 |
|---|
| 22 | #@SP#SBATCH --time=00:30:00 |
|---|
| 23 | #@SP#SBATCH --output=outNOM_SIMU%j |
|---|
| 24 | #@SP#SBATCH --error=outNOM_SIMU%j |
|---|
| 25 | #@ADS#Adastra |
|---|
| 26 | #@ADS#SBATCH --job-name=NOM_SIMU |
|---|
| 27 | #@ADS#SBATCH --ntasks=8 |
|---|
| 28 | #@ADS#SBATCH --cpus-per-task=8 |
|---|
| 29 | #@ADS#SBATCH --ntasks-per-node=8 |
|---|
| 30 | #@ADS#SBATCH --time=00:30:00 |
|---|
| 31 | #@ADS#SBATCH --output=outNOM_SIMU%j |
|---|
| 32 | #@ADS#SBATCH --error=outNOM_SIMU%j |
|---|
| 33 | #@ADS#SBATCH --exclusive |
|---|
| 34 | |
|---|
| 35 | set -eux |
|---|
| 36 | |
|---|
| 37 | # Number of MPI processes : |
|---|
| 38 | ntasks=8 |
|---|
| 39 | # number of OpenMP threads |
|---|
| 40 | nthreads=8 |
|---|
| 41 | export OMP_NUM_THREADS=$nthreads |
|---|
| 42 | #@JZ#export OMP_NUM_THREADS=$SLURM_CPUS_PER_TASK # For Jean-Zay (replacing the next 3 lines, commented out) |
|---|
| 43 | # private memory for each thread |
|---|
| 44 | export OMP_STACKSIZE=800M |
|---|
| 45 | |
|---|
| 46 | |
|---|
| 47 | #@JZ#export OMP_PLACES=cores # "binding" present in old script_SIMU, but terribly reduces performance on Spirit... |
|---|
| 48 | ulimit -s unlimited |
|---|
| 49 | #@SP ulimit -Ss 8192 |
|---|
| 50 | |
|---|
| 51 | simul=NOM_SIMU |
|---|
| 52 | |
|---|
| 53 | reseau_local=0 |
|---|
| 54 | #veget=y |
|---|
| 55 | veget=CMIP6 |
|---|
| 56 | if [[ $veget = "none" ]] ; then VEGET=n ; else VEGET=y ; fi |
|---|
| 57 | |
|---|
| 58 | isotopes=n |
|---|
| 59 | # If isotopes=y, initialisation_iso will be changed to 0 in iso.def after the 1st run period, to read isotopes in restart files |
|---|
| 60 | |
|---|
| 61 | # Choice of aerosols : n / clim / spla |
|---|
| 62 | aerosols=clim |
|---|
| 63 | stopsim=201101 |
|---|
| 64 | ok_guide=y # y/n guidage ou non |
|---|
| 65 | climato=1 |
|---|
| 66 | ozone=0 |
|---|
| 67 | |
|---|
| 68 | echo '##############################################################' |
|---|
| 69 | echo '# Gestion des repertoires de lancement ' |
|---|
| 70 | echo '##############################################################' |
|---|
| 71 | |
|---|
| 72 | # Repertoires de la simulation |
|---|
| 73 | SCRATCHD=$SCRATCH |
|---|
| 74 | STORED=$STORE |
|---|
| 75 | MAINDIR=LMDZOR96x95x79 |
|---|
| 76 | SIMU_dir=$MAINDIR/$simul |
|---|
| 77 | SIMUDIR=$STORED/$SIMU_dir |
|---|
| 78 | |
|---|
| 79 | # Repertoires de travail |
|---|
| 80 | WWORKD=$SCRATCHD/$simul$$ |
|---|
| 81 | if [[ -d $WWORKD ]]; then # useful when running on local computer, where jobs aren't submitted |
|---|
| 82 | #rm -rf "$WWORKD" |
|---|
| 83 | mv $WWORKD $WWORKD$$ |
|---|
| 84 | fi |
|---|
| 85 | mkdir -p $WWORKD |
|---|
| 86 | cd $WWORKD |
|---|
| 87 | SCRIPTDIR=$SCRATCHD |
|---|
| 88 | |
|---|
| 89 | cp "$STORED/$MAINDIR/lmdz_env.sh" .; . lmdz_env.sh |
|---|
| 90 | cp "$STORED/$MAINDIR/slurm_set_cpu_binding.sh" . |
|---|
| 91 | |
|---|
| 92 | ERADIR=$STORED/$MAINDIR/GUIDE |
|---|
| 93 | if [ "$aerosols" = "spla" ] ; then ERA10mDIR=$STORED/$MAINDIR/ERA10m ; fi |
|---|
| 94 | LIMITDIR=$STORED/$MAINDIR/LIMIT |
|---|
| 95 | DEFDIR=$SIMUDIR/DEF |
|---|
| 96 | |
|---|
| 97 | GET='ln -s' |
|---|
| 98 | PUT='mv ' |
|---|
| 99 | |
|---|
| 100 | |
|---|
| 101 | echo '##################################################################' |
|---|
| 102 | echo 'Gestion des mois et annees' |
|---|
| 103 | echo '##################################################################' |
|---|
| 104 | |
|---|
| 105 | $GET $SIMUDIR/etat |
|---|
| 106 | year=`tail -1 etat | awk ' { print $1 } ' | cut -c1-4` |
|---|
| 107 | month=`tail -1 etat | awk ' { print $1 } ' | cut -c5-` |
|---|
| 108 | echo year $year month $month |
|---|
| 109 | |
|---|
| 110 | if [ "$month" = "" ] ; then |
|---|
| 111 | paran=1 |
|---|
| 112 | ym=$year |
|---|
| 113 | next=`expr $ym + 1` |
|---|
| 114 | else |
|---|
| 115 | paran=0 |
|---|
| 116 | if [ $month = 12 ] ; then |
|---|
| 117 | nextmonth=1 |
|---|
| 118 | nextyear=`expr $year + 1` |
|---|
| 119 | else |
|---|
| 120 | nextmonth=`expr $month + 1` |
|---|
| 121 | nextyear=$year |
|---|
| 122 | fi |
|---|
| 123 | if [ `echo $nextmonth | wc -m` = 2 ] ; then |
|---|
| 124 | nextmonth=0$nextmonth |
|---|
| 125 | fi |
|---|
| 126 | ym=$year$month |
|---|
| 127 | next=$nextyear$nextmonth |
|---|
| 128 | fi |
|---|
| 129 | |
|---|
| 130 | |
|---|
| 131 | echo ym $ym |
|---|
| 132 | echo mois ancien : $ym |
|---|
| 133 | echo mois nouveau : $next |
|---|
| 134 | |
|---|
| 135 | echo '#################################################################' |
|---|
| 136 | echo 'Modification de run.def et gcm.def pour prendre en compte la duree du' |
|---|
| 137 | echo 'du mois en question.' |
|---|
| 138 | echo 'le dayref est modifie pour tricher avec le calendrier (ecrit pour' |
|---|
| 139 | echo 'une annee de 260 jours dans le modele).' |
|---|
| 140 | echo 'On passe donc comme jour de reference le numero du jour du mois dans' |
|---|
| 141 | echo 'une annee en 360 jours.' |
|---|
| 142 | echo '#################################################################' |
|---|
| 143 | |
|---|
| 144 | # Choix du calendrier |
|---|
| 145 | #AS: La condition if "$climato" = "0" suffit, car "$ok_guide" = "y" est interdit avec $climato" = "1" dans setup.sh (exit ligne 160) |
|---|
| 146 | ##calend=earth_360d |
|---|
| 147 | ##if [ "$ok_guide" = "y" -o "$climato" = "0" ] ; then calend=gregorian ; fi |
|---|
| 148 | if [ "$climato" = "0" ] ; then calend=gregorian ; else calend=earth_360d ; fi |
|---|
| 149 | bisextile=0 |
|---|
| 150 | if [[ $(( year % 4 )) = 0 && $calend = gregorian ]] ; then bisextile=1 ; fi |
|---|
| 151 | if [ $paran = 0 ] ; then |
|---|
| 152 | if [ "$calend" = "gregorian" ] ; then |
|---|
| 153 | ndays=( 31 28 31 30 31 30 31 31 30 31 30 31 ) |
|---|
| 154 | if [ $bisextile = 1 ] ; then ndays[1]=29 ; fi |
|---|
| 155 | else |
|---|
| 156 | ndays=( 30 30 30 30 30 30 30 30 30 30 30 30 ) |
|---|
| 157 | fi |
|---|
| 158 | #Constants with a leading 0 are interpreted as octal numbers. |
|---|
| 159 | # You can remove the leading zero by parameter expansion: hour=${hour#0} |
|---|
| 160 | |
|---|
| 161 | nday=${ndays[(( ${month#0} - 1 ))]} |
|---|
| 162 | ndayh=$nday |
|---|
| 163 | dayref=1 ; mm=1 ; while [ $mm -lt ${month#0} ] ; do |
|---|
| 164 | (( dayref = $dayref + ${ndays[(( $mm - 1 ))]} )) ; (( mm = $mm + 1 )) ; done |
|---|
| 165 | else |
|---|
| 166 | dayref=1 |
|---|
| 167 | if [ "$calend" = "gregorian" ] ; then |
|---|
| 168 | if [ $bisextile = 0 ] ; then nday=365 ; else nday=366 ; fi |
|---|
| 169 | else |
|---|
| 170 | nday=360 ; ndayh=30 |
|---|
| 171 | # nday=3 ; ndayh=1 # Pratique pour des tests rapides |
|---|
| 172 | fi |
|---|
| 173 | fi |
|---|
| 174 | |
|---|
| 175 | echo CALENDRIER $calend : longueur du mois vrai $year $month $nday dayref=$dayref |
|---|
| 176 | |
|---|
| 177 | |
|---|
| 178 | echo '####################################################################' |
|---|
| 179 | echo '# On va chercher les fichiers necessaires a la simulation' |
|---|
| 180 | echo '####################################################################' |
|---|
| 181 | #Reminder : we are in $WWORKD = $SCRATCHD/$SIMU_dir = $SCRATCHD/$MAINDIR/$simul |
|---|
| 182 | |
|---|
| 183 | echo DEFDIR $DEFDIR |
|---|
| 184 | echo SIMUDIR $SIMUDIR |
|---|
| 185 | echo simul $simul |
|---|
| 186 | |
|---|
| 187 | if [ $reseau_local = 0 ] ; then mkdir DEF ; cd DEF ; $GET $DEFDIR/* . ; cd .. ; fi |
|---|
| 188 | |
|---|
| 189 | cp -f DEF/* . |
|---|
| 190 | |
|---|
| 191 | # Forcing some parameters in run.def and config.def |
|---|
| 192 | sed -e 's/nday=.*.$/nday='$nday'/' -e 's/dayref=.*.$/dayref='${dayref}'/' \ |
|---|
| 193 | -e 's/anneeref=.*.$/anneeref='$year'/' DEF/run.def >| run.def |
|---|
| 194 | sed -e 's/phys_out_filetimesteps=[[:space:]]*[0-9][0-9]day/phys_out_filetimesteps= '$ndayh'day/' DEF/config.def >| config.def |
|---|
| 195 | |
|---|
| 196 | ${GET} $SIMUDIR/start.$ym.nc start.nc |
|---|
| 197 | ${GET} $SIMUDIR/startphy.$ym.nc startphy.nc |
|---|
| 198 | if [ $climato = 1 ] ; then |
|---|
| 199 | ${GET} $LIMITDIR/limit.nc limit.nc |
|---|
| 200 | if [ $ozone = 1 ] ; then ${GET} $LIMITDIR/climoz_LMDZ_1979_2008_clim.nc climoz_LMDZ.nc ; fi |
|---|
| 201 | else |
|---|
| 202 | ${GET} $LIMITDIR/limit.$year.nc limit.nc |
|---|
| 203 | if [ $ozone = 1 ] ; then ${GET} $LIMITDIR/climoz_LMDZ_$year.nc climoz_LMDZ.nc ; fi |
|---|
| 204 | fi |
|---|
| 205 | |
|---|
| 206 | |
|---|
| 207 | echo '####################################################################' |
|---|
| 208 | echo '# Imports des fichiers aerosols si flag_aerosol>0 dans config.def, ' |
|---|
| 209 | echo '# et si dans setup.sh on a "aerosols=clim" ou "aerosols=spla". ' |
|---|
| 210 | echo '# NOTE: Si "aerosols=n" dans setup.sh, script_SIMU met flag_aerosol=0 et on tourne SANS aerosols' |
|---|
| 211 | echo '####################################################################' |
|---|
| 212 | |
|---|
| 213 | if [ "`grep 'flag_aerosol=' config.def | head -1 | cut -d= -f2`" != 0 ] ; then |
|---|
| 214 | if [ $aerosols = clim ] ; then |
|---|
| 215 | # if [ $climato = 1 ] ; then suf=clim ; else suf=$year ; fi |
|---|
| 216 | suf=clim # pas d'aerosols interannuels jusque là |
|---|
| 217 | ${GET} $LIMITDIR/aerosols.$suf.nc aerosols$year.nc |
|---|
| 218 | if [ ! -f aerosols1980.nc ] ; then |
|---|
| 219 | ${GET} $LIMITDIR/aerosols.$suf.nc aerosols1980.nc |
|---|
| 220 | fi |
|---|
| 221 | ${GET} $LIMITDIR/aerosols.nat.nc aerosols.nat.nc |
|---|
| 222 | fi |
|---|
| 223 | |
|---|
| 224 | if [[ $aerosols = "spla" ]]; then |
|---|
| 225 | get_input_files ln_from_pub SPLA_WA/emissions |
|---|
| 226 | ln -s dust$month.nc dust.nc |
|---|
| 227 | for var in u10m v10m u v ; do |
|---|
| 228 | ln_from_pub 3DInputData/SPLA_WA/ERA5/$year/$month $var.nc |
|---|
| 229 | done |
|---|
| 230 | # Le calcul d'emissions de sels marins utilise les vents ERA-10m |
|---|
| 231 | # interpoles sur grille_s (lonv,latu) avec le script era2gcm_uv10m.sh |
|---|
| 232 | # NB : GET=ln -s ; ERA10mDIR contient lui-meme le lien ERA10m vers le |
|---|
| 233 | #le repertoire des vents interpoles $REA_uv10m (REA=ERA5, ERAI ou OPERA) |
|---|
| 234 | |
|---|
| 235 | fi |
|---|
| 236 | fi |
|---|
| 237 | |
|---|
| 238 | #-------------------------------------------------------------------------- |
|---|
| 239 | # Noveaux forcages a activer a l'avenir (commentes en attendant) : |
|---|
| 240 | # climoz_LMDZ.nc solarforcing.nc taulwstrat.2D.nc tauswstrat.2D.nc ; do |
|---|
| 241 | #-------------------------------------------------------------------------- |
|---|
| 242 | |
|---|
| 243 | ${GET} $SIMUDIR/gcm.e gcm.e ; chmod +x gcm.e |
|---|
| 244 | |
|---|
| 245 | |
|---|
| 246 | if [ $VEGET = y ] ; then |
|---|
| 247 | |
|---|
| 248 | set +e ; for t in stomate sechiba ; do cp $SIMUDIR/start_$t.$ym.nc ${t}_rest_in.nc ; done ; set -e |
|---|
| 249 | #For Orchidee trunk (post-CMIP6), orchidee_pft.def must be copied |
|---|
| 250 | # in addition to orchidee.def |
|---|
| 251 | \cp -f DEF/orchidee*.def . |
|---|
| 252 | |
|---|
| 253 | # If no sechiba restart file, the restart files for sechiba, stomate, |
|---|
| 254 | # and routing are created on line, thus requiring Orchidee input files |
|---|
| 255 | if [ ! -f sechiba_rest_in.nc ] ; then |
|---|
| 256 | |
|---|
| 257 | get_input_files ln_from_pub Orchidee # linking orchidee input files |
|---|
| 258 | |
|---|
| 259 | ln -sf alb_bg_modisopt_2D_ESA_v2.nc alb_bg.nc |
|---|
| 260 | echo ATTENTION : ON UTILISE LES FICHIERS DE L ANNEE 2000 |
|---|
| 261 | ln -s PFTmap_15PFT.v1_2000.nc PFTmap.nc |
|---|
| 262 | ln -s woodharvest_2000.nc woodharvest.nc |
|---|
| 263 | sed -e 's/^SECHIBA_restart_in.*./SECHIBA_restart_in=NONE/' \ |
|---|
| 264 | -e 's/^STOMATE_RESTART_FILEIN.*./STOMATE_RESTART_FILEIN=NONE/' \ |
|---|
| 265 | -i orchidee.def |
|---|
| 266 | fi |
|---|
| 267 | |
|---|
| 268 | # Input files for routing are always needed |
|---|
| 269 | if [ "`grep RIVER_ROUTING orchidee.def |grep -i y`" ] ; then |
|---|
| 270 | set +e |
|---|
| 271 | ln_from_pub 3DInputData/Orchideee routing.nc |
|---|
| 272 | ln_from_pub 3DInputData/Orchideee routing_simple.nc |
|---|
| 273 | cp $SIMUDIR/start_routing.$ym.nc routing_start.nc |
|---|
| 274 | set -e |
|---|
| 275 | fi |
|---|
| 276 | |
|---|
| 277 | fi |
|---|
| 278 | |
|---|
| 279 | |
|---|
| 280 | echo '#################################################################' |
|---|
| 281 | echo 'Repertoire contenant les fichiers de reanalyses' |
|---|
| 282 | echo '#################################################################' |
|---|
| 283 | |
|---|
| 284 | if [ "$ok_guide" = "y" ] ; then |
|---|
| 285 | \rm -f u.nc v.nc T.nc hur.nc |
|---|
| 286 | if [ -f u.nc ] ; then |
|---|
| 287 | echo PROBLEME D EFFACEMENT DES FICHIERS DE REANALYSES |
|---|
| 288 | exit 1 |
|---|
| 289 | fi |
|---|
| 290 | for var in u v T hur ; do $GET $ERADIR/$year/$month/$var.nc $var.nc ; done |
|---|
| 291 | echo Fin du rapatriement des fichiers de guidage |
|---|
| 292 | fi |
|---|
| 293 | |
|---|
| 294 | echo '##################################################################' |
|---|
| 295 | echo 'liste des fichiers avant le lancement de la simulation' |
|---|
| 296 | echo '##################################################################' |
|---|
| 297 | ls -lrt |
|---|
| 298 | #diff DEF ./ |
|---|
| 299 | |
|---|
| 300 | echo '##################################################################' |
|---|
| 301 | echo 'Lancement de la simulation' |
|---|
| 302 | echo '##################################################################' |
|---|
| 303 | |
|---|
| 304 | #@ADS if 1; then |
|---|
| 305 | if [ "$MPICMD" = "" ] ; then mpicmd= ; else mpicmd="$MPICMD $ntasks" ; fi |
|---|
| 306 | time $mpicmd ./gcm.e > listing |
|---|
| 307 | #@ADS else |
|---|
| 308 | #@ADS # 18/08/2025 : SLURM version changed from 23 to 24.05.8 --> "--overcommit" added to srun, to avoid crashes for memory problems |
|---|
| 309 | #@ADS srun --overcommit --cpu-bind=none --mem-bind=none -- ./slurm_set_cpu_binding.sh ./gcm.e > listing |
|---|
| 310 | #@ADS fi |
|---|
| 311 | |
|---|
| 312 | if [ ! -f restartphy.nc ] ; then |
|---|
| 313 | echo PROBLEME PAS DE FICHIER RESTARTPHY |
|---|
| 314 | exit |
|---|
| 315 | fi |
|---|
| 316 | |
|---|
| 317 | echo '##################################################################' |
|---|
| 318 | echo 'sauvegarde des fichiers de sortie' |
|---|
| 319 | echo '##################################################################' |
|---|
| 320 | |
|---|
| 321 | # listing |
|---|
| 322 | ${PUT} listing ${SIMUDIR}/list$ym |
|---|
| 323 | # if the listing for Orchidee is also needed, then uncomment the following line : |
|---|
| 324 | #if [ $VEGET = y ] ; then ${PUT} out_orchidee_0000.0000 ${SIMUDIR}/out_orchidee$ym ; fi |
|---|
| 325 | |
|---|
| 326 | # restart(s) |
|---|
| 327 | ${PUT} restart.nc ${SIMUDIR}/start.$next.nc |
|---|
| 328 | ${PUT} restartphy.nc ${SIMUDIR}/startphy.$next.nc |
|---|
| 329 | if [ $VEGET = y ] ; then for t in sechiba stomate ; do |
|---|
| 330 | f=${t}_rest_out.nc ; if [ -f $f ] ; then ${PUT} $f ${SIMUDIR}/start_$t.$next.nc ; fi ; done |
|---|
| 331 | f=routing_restart.nc ; if [ -f $f ] ; then ${PUT} $f ${SIMUDIR}/start_routing.$next.nc ; fi |
|---|
| 332 | fi |
|---|
| 333 | |
|---|
| 334 | # fichiers "histoires" |
|---|
| 335 | # Si on tourne avec xios (et type="one_file") au lieu de ioipsl, on n'a pas besoin de rebuild, on doit juste copier les fichiers |
|---|
| 336 | liste_out="histmth histday histhf histmthCOSP Xhistins XhistLES sechiba_history sechiba_history_4dim sechiba_out_2 stomate_history stomate_ipcc_history diag_routing dynzon" |
|---|
| 337 | xios_used=0 |
|---|
| 338 | |
|---|
| 339 | for fileout in $liste_out ; do |
|---|
| 340 | if [ -f $fileout.nc ] ; then |
|---|
| 341 | ${PUT} $fileout.nc ${SIMUDIR}/$fileout.$ym.nc |
|---|
| 342 | xios_used=1 |
|---|
| 343 | fi |
|---|
| 344 | done |
|---|
| 345 | |
|---|
| 346 | if [ $xios_used = 0 ] ; then |
|---|
| 347 | $GET $SIMUDIR/reb.sh |
|---|
| 348 | chmod +x reb.sh |
|---|
| 349 | ./reb.sh $ym $SIMUDIR $liste_out |
|---|
| 350 | fi |
|---|
| 351 | |
|---|
| 352 | if [ -f guide_ins.nc ] ; then ${PUT} guide_ins.nc ${SIMUDIR}/guide_ins.$ym.nc ; fi |
|---|
| 353 | |
|---|
| 354 | echo '##################################################################' |
|---|
| 355 | echo 'preparation et lancement de la simulation suivante' |
|---|
| 356 | echo '##################################################################' |
|---|
| 357 | |
|---|
| 358 | # Gestion du fichier etat de controle de la simulation |
|---|
| 359 | echo $ym OK >> etat |
|---|
| 360 | echo $next a faire >> etat |
|---|
| 361 | # ${PUT} etat $SIMUDIR/etat # Pas necessaire car etat est un lien vers $SIMUDIR/etat |
|---|
| 362 | |
|---|
| 363 | # set initialisation_iso to 0 for next run to read isotopes from restart files |
|---|
| 364 | if [ $isotopes = y ] ; then |
|---|
| 365 | sed -i 's/^initialisation_iso=.*.$/initialisation_iso=0/' $SIMUDIR/DEF/iso.def |
|---|
| 366 | fi |
|---|
| 367 | set +e ; \rm out* sta* list* rest* gcm.e aer* ; set -e |
|---|
| 368 | |
|---|
| 369 | # Arret si on est arrive au bout |
|---|
| 370 | if [ $next = $stopsim ] ; then |
|---|
| 371 | echo 'On arrive au bout, simulation next:'$next', stopsim:'$stopsim |
|---|
| 372 | exit 1 |
|---|
| 373 | fi |
|---|
| 374 | |
|---|
| 375 | echo '##################################################################' |
|---|
| 376 | echo 'lancement de la simulation suivante tmp_'$simul' depuis :' |
|---|
| 377 | echo '##################################################################' |
|---|
| 378 | pwd |
|---|
| 379 | cd $SCRIPTDIR |
|---|
| 380 | submitcmd tmp_$simul |
|---|
| 381 | #$SUBMITCMD tmp_$simul |
|---|