Ignore:
Timestamp:
Jun 25, 2024, 4:52:40 PM (3 months ago)
Author:
abarral
Message:

add ecrad physics check
change ecrad data path
update lmdz_env for adastra
update DEF/namelist_ecrad

File:
1 edited

Legend:

Unmodified
Added
Removed
  • BOL/LMDZ_Setup_amaury/setup.sh

    r4991 r4993  
    2626  #   in order to re-run the initialisation job, which downloads the aerosol files and interpolates them)
    2727  aerosols="clim"
    28   aerosols="n"  # TODO TEMP
    2928
    3029  # SURFACE/VEGETATION SCHEME
    31   # - "none" (bucket scheme) / "CMIP6" or "orch2.0" (orchidee version used in CMIP exercise) / "orch2.2" (orchidee version used in IPSLCM7 configuration) / number (orchidee version number - only rev 7983 on branch _2_2, and 7994 on trunk, are available)
    32   # TODO check w/ Adriana why only 7983 & 7994, see if still relevant - is it a compilation issue ? Or an INIT issue ?
     30  # - "none" (bucket scheme) / "CMIP6" (orchidee version used in CMIP exercise) / "7983" (orch2.2) / "7994" (trunk)
     31  # If you need other orch versions, and also require XIOS, you'll need to create the appropriate files in DEF/XMLfilesOR...
    3332  veget="CMIP6"
    34 #  veget="6592"  # TODO correct bug in install_lmdz where we don't know which fcm arg to fwd if we only give the rev... see w/ Laurent (choice in ols install_lmdz: only support >2.0)
    3533
    3634  # New snow scheme INLANDSIS! "y" / "n"
     
    198196    exit 1
    199197  fi
     198
     199  if [[ $rad = "ecrad" && $phylmd != "lmd" ]]; then
     200    echo "<rad=ecrad> is only supported for <phy=phylmd> here"  # (Amaury) I added this check because we fetch ecrad data from libf/phylmd/ecrad/data only.
     201  fi
    200202}
    201203
     
    219221  cp "$local/install_lmdz.sh" .
    220222  chmod +x install_lmdz.sh
    221   echo "./install_lmdz.sh -noclean $optim -v $version $svnopt -d $resol -rad $rad -bench 0 -parallel mpi_omp $ins_cosp $ins_xios $ins_aero $ins_inlandsis -name $LMDZname -veget $veget -netcdf $netcdf -arch $ARCH" >> install_lmdz_options.$$.sh
     223  local make_j=8
     224  echo "./install_lmdz.sh -noclean $optim -v $version $svnopt -d $resol -rad $rad -bench 0 -parallel mpi_omp $ins_cosp $ins_xios $ins_aero $ins_inlandsis -name $LMDZname -veget $veget -netcdf $netcdf -arch $ARCH -make_j $make_j" >> install_lmdz_options.$$.sh
    222225  chmod +x install_lmdz_options.$$.sh
    223226  echo "Running install_lmdz_options.$$.sh"
    224227  set -o pipefail
    225   gcm=$MODEL/$(./install_lmdz_options.$$.sh | tee /dev/tty | tail -n 1 | sed -n "s:.* executable is \(.*\.e\).*:\1:p")
     228  # TODO (wip) Run install_lmdz using $RUNCMD to 1) speed up 2) avoid issues related to being on the "right" platform for compilation
     229  # gcm=$MODEL/$($RUNCMD $make_j bash install_lmdz_options.$$.sh | tee /dev/tty | tail -n 1 | sed -n "s:.* executable is \(.*\.e\).*:\1:p")
     230    gcm=$MODEL/$(./install_lmdz_options.$$.sh | tee /dev/tty | tail -n 1 | sed -n "s:.* executable is \(.*\.e\).*:\1:p")
    226231  set +o pipefail
    227232  mv install_lmdz.sh install_lmdz.$$.sh
     
    305310  #---------------------------------------------------------------------
    306311  sed -i'' -e 's/iflag_rrtm=.*.$/iflag_rrtm='"$iflag_rrtm"'/' -e 's/NSW=.*.$/NSW='"$NSW"'/' DEF/physiq.def
    307   sed -i'' -e 's:directory_name.*$:directory_name="'"$local"'/ecrad_data",:' DEF/namelist_ecrad
     312  sed -i"" -e "s:directory_name.*$:directory_name=\"$MODEL/libf/phylmd/ecrad/ecrad_data\",:" DEF/namelist_ecrad
    308313
    309314  if [[ $phylmd = "lmdiso" ]]; then iflag_ice_thermo=0; else iflag_ice_thermo=1; fi
     
    519524  done
    520525  cd - > /dev/null
    521 
    522   if [[ $rad = "ecrad" && ! -d ecrad_data ]]; then
    523     cd "$local"; wget https://lmdz.lmd.jussieu.fr/pub/3DInputData/ecrad/ecrad_data.tar; tar xvf ecrad_data.tar; cd - > /dev/null
    524   fi
    525526}
    526527
     
    695696function message_post_submit {
    696697  if [[ $ok_guide = "y" && $init = 1 ]]; then
     698    enable_platform era2gcm_tuto.sh
    697699    echo "Once initialisation is finished, you have to create nudging files"
    698     echo "Edit era2gcm.sh and set the desired parameters in section <User choices>"
    699     echo "Make sure you have acces to the chosen ERA files, and the required modules are loaded, then run : ./era2gcm.sh"
     700    echo "Edit era2gcm_tuto.sh and set the desired parameters in section <User choices>"
     701    echo "Make sure you have acces to the chosen ERA files, and the required modules are loaded, then run : ./era2gcm_tuto.sh"
    700702    if [[ $aerosols = "spla" ]]; then
    701703      echo "Your aerosol choice is <spla>, so you need ERA 10m-winds interpolated on LMDZ grid. Use script era2gcm_uv10m.sh"
     
    703705  else
    704706    echo "Si tout se passe bien, vous avez initialisé et lancé automatiquement la simulation."
    705     echo "Le job qui a été lancé se trouve sur $SIMRUNTOPDIR/$MAINDIR/tmp_$SIM"
     707    echo "Le job qui a été lancé se trouve sur $SIMRUNTOPDIR/tmp_$SIM"
    706708  fi
    707709}
     
    724726run_sim_or_init
    725727message_post_submit
    726 
    727 exit 1
    728 
    729 
    730 # COMPILATION OPTIONS depending on the user choices and LMDZ revision number $mysvn
    731 #-------------------------------------------------------
    732 
    733 if [[ $rad = "ecrad" && $aerosols != "n" && $mysvn -lt 4489 ]] ; then echo "Les aerosols tropospheriques ne sont pas pris en charge par ecrad avant LMDZ rev 4489, ici rev est $mysvn"; exit 1; fi
    734 
    735 # EXIT after (install and) compilation if we are on jean-zay-pp instead of jean-zay !
    736 hostname=`hostname`
    737 if [ ${hostname:0:11} = "jean-zay-pp" ]; then
    738  echo "You are on jean-zay-pp, here you only can install and compile the model, not run it"
    739  echo "If you want to run a simulation, log in to jean-zay and launch main.sh again, without install"
    740  echo `date`
    741  exit
    742 fi
    743 
    744 
    745 
    746 
    747 
    748 
    749 
    750 
    751 
    752 
    753 
    754 
    755 
    756 
    757 
    758 
    759 
    760 
    761 ###############################################################################
    762 # At the end, print on screen the compilation command, and also in a "compile.sh" script
    763 
    764 echo "To recompile the model :"
    765 echo "run the compile${sufiso}.sh script created in the present folder: ./compile${sufiso}.sh gcm "
Note: See TracChangeset for help on using the changeset viewer.