Browse Source

Updated special_restart option

Francois Klein 4 years ago
parent
commit
475503f9ca
1 changed files with 5 additions and 4 deletions
  1. 5 4
      3.3.0/runtime/classic/ece-ifs+nemo.sh.tmpl

+ 5 - 4
3.3.0/runtime/classic/ece-ifs+nemo.sh.tmpl

@@ -248,10 +248,11 @@ then
         sed -i "/$special_year/q" ${run_dir}/ece.info
         . ${run_dir}/ece.info
         special_restart_leg=$(printf %03d $((leg_number+1)))
+        special_restart_leg_oasis=$(printf %03d $((leg_number+2)))
         # PUT HERE THE INSTRUCTIONS TO COPY THE restart files
-        rsync -av ${run_dir}/../${special_restart_from}/restart/ifs/${special_restart_leg}/ ${run_dir}
-        rsync -av ${run_dir}/../${special_restart_from}/restart/oasis/${special_restart_leg}/ ${run_dir}
-        cd ${run_dir}/../${special_restart_from}/restart/nemo/${special_restart_leg}
+        rsync -av ${run_dir}/../../archive/${special_restart_from}/restart/ifs/${special_restart_leg}/ ${run_dir}
+        rsync -av ${run_dir}/../../archive/${special_restart_from}/restart/oasis/${special_restart_leg_oasis}/ ${run_dir}
+        cd ${run_dir}/../../archive/${special_restart_from}/restart/nemo/${special_restart_leg}
         for f in *.nc; do
             nf=${exp_name}${f:4}
             cp $f ${run_dir}/$nf
@@ -725,7 +726,7 @@ do
     # -------------------------------------------------------------------------
     # *** Link the appropriate NEMO restart files of the previous leg
     # -------------------------------------------------------------------------
-    if $leg_is_restart
+    if $leg_is_restart && ! $special_restart
     then
         ns=$(printf %08d $(( leg_start_sec / nem_time_step_sec - nem_restart_offset )))
         for (( n=0 ; n<nem_numproc ; n++ ))