From 64221ffe942920819021e672da0678f8ca71787d Mon Sep 17 00:00:00 2001 From: Soren Rasmussen Date: Thu, 6 Jun 2024 12:49:16 -0600 Subject: [PATCH] Updating scripts and documentation to reflect NCAR's move from Cheyenne to Derecho clusters --- scm/doc/TechGuide/chap_cases.rst | 14 +- scm/etc/scm_qsub_example.py | 15 +- scm/etc/scripts/GABLS3_LSM.ncl | 202 +++++++++---------- scm/etc/scripts/GABLS3_LSM_NoahMP.ncl | 202 +++++++++---------- scm/etc/scripts/GABLS3_LSM_RUC.ncl | 266 +++++++++++++------------- test/README.md | 9 +- test/rt.sh | 12 +- 7 files changed, 362 insertions(+), 358 deletions(-) diff --git a/scm/doc/TechGuide/chap_cases.rst b/scm/doc/TechGuide/chap_cases.rst index b6bd183dd..ff97454d7 100644 --- a/scm/doc/TechGuide/chap_cases.rst +++ b/scm/doc/TechGuide/chap_cases.rst @@ -146,7 +146,7 @@ are included in ``ccpp-scm/scm/data/processed_case_input/fv3_model_point_noah[mp .. literalinclude:: arm_case_header.txt :name: lst_case_input_netcdf_header_arm :caption: example NetCDF file (CCPP-SCM format) header for case initialization and forcing data - + Case input data file (DEPHY format) ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ @@ -505,10 +505,10 @@ Optional arguments: Examples to run from within the ``scm/etc/scripts`` directory to create SCM cases starting with the output from a UFS Weather Model regression test(s): -On the supported platforms Cheyenne (NCAR) and Hera (NOAA), there are +On the supported platforms Derecho (NCAR) and Hera (NOAA), there are staged UWM RTs located at: -- Cheyenne ``/glade/scratch/epicufsrt/GMTB/CCPP-SCM/UFS_RTs`` +- Derecho ``/glade/derecho/scratch/epicufsrt/FV3_RT/`` - Hera ``/scratch1/BMC/gmtb/CCPP-SCM/UFS_RTs`` .. _`example1`: @@ -520,7 +520,7 @@ UFS regression test, ``control_c192``, for single point. .. code:: bash - ./UFS_forcing_ensemble_generator.py -d /glade/scratch/epicufsrt/GMTB/CCPP-SCM/UFS_RTs/control_c192/ -sc --C_RES 192 -dt 360 -n control_c192 -lons 300 -lats 34 + ./UFS_forcing_ensemble_generator.py -d [path_to_regression_tests_output]/control_c192_intel/ -sc --C_RES 192 -dt 360 -n control_c192 -lons 300 -lats 34 Upon successful completion of the script, the command to run the case(s) will print to the screen. For example, @@ -540,7 +540,7 @@ UFS regression test, ``control_c384``, for multiple points. .. code:: bash - ./UFS_forcing_ensemble_generator.py -d /glade/scratch/epicufsrt/GMTB/CCPP-SCM/UFS_RTs/control_c384/ -sc --C_RES 384 -dt 225 -n control_c384 -lons 300 300 300 300 -lats 34 35 35 37 + ./UFS_forcing_ensemble_generator.py -d /glade/derecho/scratch/epicufsrt/ufs-weather-model/RT/NEMSfv3gfs/develop-20240607/control_c384_intel/ -sc --C_RES 384 -dt 225 -n control_c384 -lons 300 300 300 300 -lats 34 35 35 37 Upon successful completion of the script, the command to run the case(s) will print to the screen. For example, @@ -578,14 +578,14 @@ for more details. For the purposes of this example the ``control_p8`` test has already been rerun, but if starting from your own UWM RTs, you can rerun the UWM regression test, -on Cheyenne for example, by running the following command in the RT +on Derecho for example, by running the following command in the RT directory: ``qsub job_card`` Now the cases can be generated with the following command: .. code:: bash - ./UFS_forcing_ensemble_generator.py -d /glade/scratch/epicufsrt/GMTB/CCPP-SCM/UFS_RTs/control_p8/ -sc --C_RES 96 -dt 720 -n control_p8 -lonl 300 320 -latl 40 50 -nens 10 -sdf SCM_GFS_v17_p8 + ./UFS_forcing_ensemble_generator.py -d /glade/derecho/scratch/epicufsrt/ufs-weather-model/RT/NEMSfv3gfs/develop-20240607/control_p8_intel -sc --C_RES 96 -dt 720 -n control_p8 -lonl 300 320 -latl 40 50 -nens 10 -sdf SCM_GFS_v17_p8 Upon successful completion of the script, the command to run the case(s) will print to the screen. For example, diff --git a/scm/etc/scm_qsub_example.py b/scm/etc/scm_qsub_example.py index 457013dff..e34d80ab4 100755 --- a/scm/etc/scm_qsub_example.py +++ b/scm/etc/scm_qsub_example.py @@ -3,10 +3,15 @@ ----------------------------------------------------------------------- Description: Example script to submit a job through the HPC batch system - Assumptions: For use on Cheyenne. This script must be copied to the bin directory. + Assumptions: For use on Derecho. This script must be copied to the bin directory. The user should edit the JOB_NAME, ACCOUNT, etc. - ./scm/etc/Cheyenne_setup_intel.sh or - ./scm/etc/Cheyenne_setup_gnu.sh must be run before submitting this script + Before running this script the environment must be setup. + The following are instructions for that: + $ module purge + $ module use scm/etc/modules + $ module load derecho_gnu + or + $ module load derecho_intel Command line arguments: none @@ -25,10 +30,10 @@ ### Begin User-editable section ### JOB_NAME = "test_job" -ACCOUNT = "p48503002" +ACCOUNT = "ENTER_ACCOUNT_NUMBER" WALLTIME = "walltime=00:20:00" PROCESSORS = "select=1:ncpus=1" -QUEUE = "share" +QUEUE = "develop" COMMAND = "./run_scm.py -c twpice" EMAIL_ADDR = MY_EMAIL SERIAL_MEM = "512M" diff --git a/scm/etc/scripts/GABLS3_LSM.ncl b/scm/etc/scripts/GABLS3_LSM.ncl index 85f4dc2a9..4330c1563 100644 --- a/scm/etc/scripts/GABLS3_LSM.ncl +++ b/scm/etc/scripts/GABLS3_LSM.ncl @@ -5,7 +5,7 @@ load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" begin ;Define constants - + missing_value = -9999.0 g = 9.80665 ;gravity (m s-2) R_dry = 287. ;ideal gas dry air constant (J kg-1 K-1) @@ -24,7 +24,7 @@ begin ; Time, 01Jul2006 12:00:00 UTC - 02Jul2006 12:00:00 UTC ; Must be in seconds time = fspan(0,86400,145) - time@long_name = "elapsed time since the beginning of the simulation" + time@long_name = "elapsed time since the beginning of the simulation" time@units = "s" ; timb = fspan(0,86400,145) @@ -52,7 +52,7 @@ begin ; Total water specific humidity (q) at heights listed above qt = (/ 9.3e-3, 9.3e-3, 8.5e-3, 8.4e-3, 8.3e-3, 8.2e-3, 8.1e-3, \ - 8.0e-3, 7.5e-3, 2.0e-3, 0.3e-3, 0.01e-3, 0.003e-3, 0. /) + 8.0e-3, 7.5e-3, 2.0e-3, 0.3e-3, 0.01e-3, 0.003e-3, 0. /) qt@long_name = "initial profile of total water specific humidity" qt@units = "kg kg^-1" @@ -96,7 +96,7 @@ begin end do ; Solve the hypsometric equation for p2 to attain each new pressure level -; and fill the array (the variable to fill is levels, created above.) +; and fill the array (the variable to fill is levels, created above.) ; The value for levels(0) = p_surf(0) levels(0) = p_surf(0) do i=1,dimsizes(levels)-1,1 @@ -113,7 +113,7 @@ begin ; Calculate thetail. Because ql and qi are not given, this is not possible, ; so the initial profile of thetail will be assumed theta. -; The remainder of the equation used in the gmtb-scm user's guide would be +; The remainder of the equation used in the gmtb-scm user's guide would be ; zero, leaving you with only theta. thetail = theta thetail@long_name = "initial profile of ice-liquid water potential "+ \ @@ -135,10 +135,10 @@ begin v@long_name = "initial profile of N-S horizontal wind" v@units = "m s^-1" -; Use GLDAS to derive the sensible and latent heat flux for the Cabauw -; location, then you can compare the GLDAS H/Le to the given intial Bowen +; Use GLDAS to derive the sensible and latent heat flux for the Cabauw +; location, then you can compare the GLDAS H/Le to the given intial Bowen ; ratio. Begin by reading in the data from each file. -; gl_dir = "/glade/scratch/damico/GLDAS_GABLS3/" +; gl_dir = "/path/to/GLDAS_GABLS3/" ; gl_00 = addfile(gl_dir+"GLDAS_NOAH025_3H.A20060701.0000.021.nc4.SUB.nc4", \ ; "r") @@ -249,7 +249,7 @@ begin w_ls@units = "m s^-1" ; Geostrophic winds are given at certain times but only at the surface. -; Instructions from GABLS suggest interpolation to surface winds up to +; Instructions from GABLS suggest interpolation to surface winds up to ; 2000 m, and then constant from that point. This should be done for each ; time step. Starting with time. u_geo_spec = (/ -7.8, -7.8, -6.5, -5.0, -5.0, -6.5 /) @@ -260,7 +260,7 @@ begin v_geo_t = (/ 0, 21600, 39600, 54000, 64800, 86400 /) v_geo = linint1(v_geo_t,v_geo_spec,False,time,0) -; Interpolate with height, linearly, from the surface values above to -2.0 +; Interpolate with height, linearly, from the surface values above to -2.0 ; m s^-1 for u and 2.0 m s^-1 for v. Above 2000 m, geostrophic wind is ; constant with height (according to GABLS guide). u_g = new((/ dimsizes(levels),dimsizes(time) /),float) @@ -287,10 +287,10 @@ begin u_g@units = "m s^-1" v_g@unit = "m s^-1" -; Horizontal temperature tendency due to advection, which can be converted to -; thetail tendency. The values are give; between 200-1000m, decreasing -; to zero down towards the surface and decreasing to zero from 1000m to -; 1500m, with zero entirely above. Once again, there needs to be +; Horizontal temperature tendency due to advection, which can be converted to +; thetail tendency. The values are give; between 200-1000m, decreasing +; to zero down towards the surface and decreasing to zero from 1000m to +; 1500m, with zero entirely above. Once again, there needs to be ; interpolation in time and with height. T_advec_spec = (/ -2.5e-5,7.5e-5, 0., 0. /) T_advec_time = (/ 0, 46800,64800,86400 /) @@ -316,10 +316,10 @@ begin "horizontal advection" h_advec_thetail@units = "K s^-1" -; The last remaining variable given in the data that the gmtb-scm can -; use is horizontal specific humidity tendency. The values are given +; The last remaining variable given in the data that the gmtb-scm can +; use is horizontal specific humidity tendency. The values are given ; between 200-1000m, decreasing to zero down towards the surface and -; decreasing to zero from 1000m to 1500, with zero entirely above. Once +; decreasing to zero from 1000m to 1500, with zero entirely above. Once ; again, there needs to be interpolation in time and with height. h_advec_spec = (/ 0., 8.e-8, 0., -8.e-8, 0., 0. /) h_advec_time = (/ 0, 32400, 43200, 50400, 61200, 86400 /) @@ -407,7 +407,7 @@ begin v_advec_thetail = 0. v_advec_thetail@long_name = "prescribed theta_il tendency due to " + \ "vertical advection" - v_advec_thetail@units = "K s^-1" + v_advec_thetail@units = "K s^-1" v_advec_qt = new((/ dimsizes(levels),dimsizes(time) /),float) v_advec_qt = 0. @@ -418,141 +418,141 @@ begin ; Noah LSM initialization slmsk = 1.0 ;corresponds to land from the UFS ICs slmsk@long_name = "land-sea-ice mask" - - tsfco = 305.0 + + tsfco = 305.0 tsfco@long_name = "sea surface temperature OR surface skin temperature over land OR sea ice surface skin temperature (depends on value of slmsk)" tsfco@units = "K" - + weasd = 0.0 weasd@long_name = "water equivalent accumulated snow depth" weasd@units = "mm" - + tg3 = 283.15 ;corresponds to case specs tg3@units = "K" tg3@long_name = "deep soil temperature" - + zorl = 15.0 ;(cm) from case specs zorl@long_name = "composite surface roughness length" zorl@units = "cm" - + zorlw = zorl ;(cm) from case specs zorlw@long_name = "surface roughness length over ocean" zorlw@units = "cm" - + alvsf = 0.23 ;corresponds to case specs alvsf@long_name = "60 degree vis albedo with strong cosz dependency" - + alnsf = 0.23 ;corresponds to case specs alnsf@long_name = "60 degree nir albedo with strong cosz dependency" - + alvwf = 0.23 ;corresponds to case specs alvwf@long_name = "60 degree vis albedo with weak cosz dependency" - + alnwf = 0.23 ;corresponds to case specs alnwf@long_name = "60 degree nir albedo with weak cosz dependency" - + facsf = 0.50556319952 ;corresponds to value from UFS ICs (static from fix files for C768) facsf@long_name = "fractional coverage with strong cosz dependency" - + facwf = 0.49443680048 ;corresponds to value from UFS ICs (static from fix files for C768) facwf@long_name = "fractional coverage with weak cosz dependency" - - vegfrac = 0.75 ; the value of 100% specified in the case + + vegfrac = 0.75 ; the value of 100% specified in the case ; specifications clashes with the maximum value ; for this gridpoint from UFS ICs vegfrac@long_name = "vegetation fraction" - + canopy = 0.5 ;corresponds to typical value for grassland in the growing season canopy@units = "kg m-2" canopy@long_name = "amount of water stored in canopy" - + f10m = missing_value ;this is not required f10m@long_name = "ratio of sigma level 1 wind and 10m wind" - + t2m = missing_value; this is not required t2m@long_name = "2-meter absolute temperature" t2m@units = "K" - + q2m = missing_value; this is not required q2m@long_name = "2-meter specific humidity" q2m@units = "kg kg-1" - - vegtyp = 10 ;corresponds to the "grasslands" type for the IGBP (vegsrc=1) + + vegtyp = 10 ;corresponds to the "grasslands" type for the IGBP (vegsrc=1) ;dataset vegtyp@long_name = "vegetation type (1-12)" - + soiltyp = 12 ;corresponds to "clay" soil type soiltyp@long_name = "soil type (1-12)" - + ;derive friction velocity from known values wind1 = sqrt(u_specified(1)^2 + v_specified(1)^2) uustar = von_K*wind1/log(u_h(1)/(0.01*zorl)) uustar@units = "m s-1" uustar@long_name = "friction velocity" - + ffmm = missing_value ;this is not required ffmm@long_name = "Monin-Obukhov similarity function for momentum" - + ffhh = missing_value ;this is not required ffhh@long_name = "Monin-Obukhov similarity function for heat" - + hice = 0.0 ;corresponds to value from UFS ICs hice@units = "m" hice@long_name = "sea ice thickness" - + fice = 0.0 ;corresponds to value from UFS ICs fice@long_name = "ice fraction" - + tisfc = tsfco ; there is no ice, but this corresponds to the surface skin temperature tisfc@units = "K" tisfc@long_name = "ice surface temperature" - + tprcp = missing_value; not required tprcp@units = "m" tprcp@long_name = "instantaneous total precipitation amount" - + srflag = missing_value; not required srflag@long_name = "snow/rain flag for precipitation" - + snwdph = 0.0 ;corresponds to case specs snwdph@units = "mm" snwdph@long_name = "water equivalent snow depth" - + shdmin = 0.01 ; corresponds to minimum vegetation fraction from surface fixed data (is not actually used in Noah LSM) shdmin@long_name = "minimum vegetation fraction" - + shdmax = 0.8 ; the maximum value from the surface fixed data is closer to 0.75 (is not actually used in Noah LSM) shdmax@long_name = "maximum vegetation fraction" - + slopetyp = 1 slopetyp@long_name = "slope type (1-9)" - + snoalb = 0.728796124458 ;corresponds to value from UFS ICs (static from fix files for C768) snoalb@long_name = "maximum snow albedo" - + sncovr = 0.0 ;corresponds to case specs sncovr@long_name = "snow area fraction" - + tsfcl = tsfco tsfcl@long_name = "surface skin temperature over land" tsfcl@units = "K" - + zorll = zorl ;(cm) from case specs zorll@long_name = "surface roughness length over land" zorll@units = "cm" - + zorli = zorl ;(cm) from case specs zorli@long_name = "surface roughness length over ice" zorli@units = "cm" - + stc = (/ 292.55, 289.9, 285.35, 283.15 /) stc@units = "K" stc@long_name = "initial profile of soil temperature" - + smc = (/ 0.203, 0.203, 0.203, 0.203 /) smc@units = "m3 m-3" smc@long_name = "initial profile of soil moisture" - + slc = smc ;all liquid (no ice) slc@units = "m3 m-3" slc@long_name = "initial profile of soil liquid moisture" @@ -594,7 +594,7 @@ begin filevardef(fo,"levels",typeof(levels),"levels") filevarattdef(fo,"levels",levels) fo->levels = (/ levels /) - + filevardef(fo,"soil_depth",typeof(soil_depth),"nsoil") filevarattdef(fo,"soil_depth",soil_depth) fo->soil_depth = (/ soil_depth /) @@ -615,7 +615,7 @@ begin filedimdef(g2,dimNames,dimSizes,dimUnlim) filedimdef(g3,dimNames,dimSizes,dimUnlim) - + filevardef(g1,"lat",typeof(lat),"ncl_scalar") filevarattdef(g1,"lat",lat) g1->lat = lat @@ -623,151 +623,151 @@ begin filevardef(g1,"lon",typeof(lon),"ncl_scalar") filevarattdef(g1,"lon",lon) g1->lon = lon - + filevardef(g1,"slmsk",typeof(slmsk),"ncl_scalar") filevarattdef(g1,"slmsk",slmsk) g1->slmsk = slmsk - + filevardef(g1,"tsfco",typeof(tsfco),"ncl_scalar") filevarattdef(g1,"tsfco",tsfco) g1->tsfco = tsfco - + filevardef(g1,"weasd",typeof(weasd),"ncl_scalar") filevarattdef(g1,"weasd",weasd) g1->weasd = weasd - + filevardef(g1,"tg3",typeof(tg3),"ncl_scalar") filevarattdef(g1,"tg3",tg3) g1->tg3 = tg3 - + filevardef(g1,"zorl",typeof(zorl),"ncl_scalar") filevarattdef(g1,"zorl",zorl) g1->zorl = zorl - + filevardef(g1,"zorlw",typeof(zorlw),"ncl_scalar") filevarattdef(g1,"zorlw",zorlw) g1->zorlw = zorlw - + filevardef(g1,"alvsf",typeof(alvsf),"ncl_scalar") filevarattdef(g1,"alvsf",alvsf) g1->alvsf = alvsf - + filevardef(g1,"alnsf",typeof(alnsf),"ncl_scalar") filevarattdef(g1,"alnsf",alnsf) g1->alnsf = alnsf - + filevardef(g1,"alvwf",typeof(alvwf),"ncl_scalar") filevarattdef(g1,"alvwf",alvwf) g1->alvwf = alvwf - + filevardef(g1,"alnwf",typeof(alnwf),"ncl_scalar") filevarattdef(g1,"alnwf",alnwf) g1->alnwf = alnwf - + filevardef(g1,"facsf",typeof(facsf),"ncl_scalar") filevarattdef(g1,"facsf",facsf) g1->facsf = facsf - + filevardef(g1,"facwf",typeof(facwf),"ncl_scalar") filevarattdef(g1,"facwf",facwf) g1->facwf = facwf - + filevardef(g1,"vegfrac",typeof(vegfrac),"ncl_scalar") filevarattdef(g1,"vegfrac",vegfrac) g1->vegfrac = vegfrac - + filevardef(g1,"canopy",typeof(canopy),"ncl_scalar") filevarattdef(g1,"canopy",canopy) g1->canopy = canopy - + filevardef(g1,"f10m",typeof(f10m),"ncl_scalar") filevarattdef(g1,"f10m",f10m) g1->f10m = f10m - + filevardef(g1,"t2m",typeof(t2m),"ncl_scalar") filevarattdef(g1,"t2m",t2m) g1->t2m = t2m - + filevardef(g1,"q2m",typeof(q2m),"ncl_scalar") filevarattdef(g1,"q2m",q2m) g1->q2m = q2m - + filevardef(g1,"vegtyp",typeof(vegtyp),"ncl_scalar") filevarattdef(g1,"vegtyp",vegtyp) g1->vegtyp = vegtyp - + filevardef(g1,"soiltyp",typeof(soiltyp),"ncl_scalar") filevarattdef(g1,"soiltyp",soiltyp) g1->soiltyp = soiltyp - + filevardef(g1,"uustar",typeof(uustar),"ncl_scalar") filevarattdef(g1,"uustar",uustar) g1->uustar = uustar - + filevardef(g1,"ffmm",typeof(ffmm),"ncl_scalar") filevarattdef(g1,"ffmm",ffmm) g1->ffmm = ffmm - + filevardef(g1,"ffhh",typeof(ffhh),"ncl_scalar") filevarattdef(g1,"ffhh",ffhh) g1->ffhh = ffhh - + filevardef(g1,"hice",typeof(hice),"ncl_scalar") filevarattdef(g1,"hice",hice) g1->hice = hice - + filevardef(g1,"fice",typeof(fice),"ncl_scalar") filevarattdef(g1,"fice",fice) g1->fice = fice - + filevardef(g1,"tisfc",typeof(tisfc),"ncl_scalar") filevarattdef(g1,"tisfc",tisfc) g1->tisfc = tisfc - + filevardef(g1,"tprcp",typeof(tprcp),"ncl_scalar") filevarattdef(g1,"tprcp",tprcp) g1->tprcp = tprcp - + filevardef(g1,"srflag",typeof(srflag),"ncl_scalar") filevarattdef(g1,"srflag",srflag) g1->srflag = srflag - + filevardef(g1,"snwdph",typeof(snwdph),"ncl_scalar") filevarattdef(g1,"snwdph",snwdph) g1->snwdph = snwdph - + filevardef(g1,"shdmin",typeof(shdmin),"ncl_scalar") filevarattdef(g1,"shdmin",shdmin) g1->shdmin = shdmin - + filevardef(g1,"shdmax",typeof(shdmax),"ncl_scalar") filevarattdef(g1,"shdmax",shdmax) g1->shdmax = shdmax - + filevardef(g1,"slopetyp",typeof(slopetyp),"ncl_scalar") filevarattdef(g1,"slopetyp",slopetyp) g1->slopetyp = slopetyp - + filevardef(g1,"snoalb",typeof(snoalb),"ncl_scalar") filevarattdef(g1,"snoalb",snoalb) g1->snoalb = snoalb - + filevardef(g1,"sncovr",typeof(sncovr),"ncl_scalar") filevarattdef(g1,"sncovr",sncovr) g1->sncovr = sncovr - + filevardef(g1,"tsfcl",typeof(tsfcl),"ncl_scalar") filevarattdef(g1,"tsfcl",tsfcl) g1->tsfcl = tsfcl - + filevardef(g1,"zorll",typeof(zorll),"ncl_scalar") filevarattdef(g1,"zorll",zorll) g1->zorll = zorll - + filevardef(g1,"zorli",typeof(zorli),"ncl_scalar") filevarattdef(g1,"zorli",zorli) g1->zorli = zorli - + filevardef(g2,"height",typeof(height),"levels") filevarattdef(g2,"height",height) g2->height = (/height/) @@ -803,15 +803,15 @@ begin filevardef(g2,"ozone",typeof(ozone),"levels") filevarattdef(g2,"ozone",ozone) g2->ozone = (/ozone/) - + filevardef(g2,"stc",typeof(stc),"nsoil") filevarattdef(g2,"stc",stc) g2->stc = (/stc/) - + filevardef(g2,"smc",typeof(smc),"nsoil") filevarattdef(g2,"smc",smc) g2->smc = (/smc/) - + filevardef(g2,"slc",typeof(slc),"nsoil") filevarattdef(g2,"slc",slc) g2->slc = (/slc/) diff --git a/scm/etc/scripts/GABLS3_LSM_NoahMP.ncl b/scm/etc/scripts/GABLS3_LSM_NoahMP.ncl index aa956aebf..ad2570875 100644 --- a/scm/etc/scripts/GABLS3_LSM_NoahMP.ncl +++ b/scm/etc/scripts/GABLS3_LSM_NoahMP.ncl @@ -5,7 +5,7 @@ load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" begin ;Define constants - + missing_value = -9999.0 g = 9.80665 ;gravity (m s-2) R_dry = 287. ;ideal gas dry air constant (J kg-1 K-1) @@ -24,7 +24,7 @@ begin ; Time, 01Jul2006 12:00:00 UTC - 02Jul2006 12:00:00 UTC ; Must be in seconds time = fspan(0,86400,145) - time@long_name = "elapsed time since the beginning of the simulation" + time@long_name = "elapsed time since the beginning of the simulation" time@units = "s" ; timb = fspan(0,86400,145) @@ -52,7 +52,7 @@ begin ; Total water specific humidity (q) at heights listed above qt = (/ 9.3e-3, 9.3e-3, 8.5e-3, 8.4e-3, 8.3e-3, 8.2e-3, 8.1e-3, \ - 8.0e-3, 7.5e-3, 2.0e-3, 0.3e-3, 0.01e-3, 0.003e-3, 0. /) + 8.0e-3, 7.5e-3, 2.0e-3, 0.3e-3, 0.01e-3, 0.003e-3, 0. /) qt@long_name = "initial profile of total water specific humidity" qt@units = "kg kg^-1" @@ -96,7 +96,7 @@ begin end do ; Solve the hypsometric equation for p2 to attain each new pressure level -; and fill the array (the variable to fill is levels, created above.) +; and fill the array (the variable to fill is levels, created above.) ; The value for levels(0) = p_surf(0) levels(0) = p_surf(0) do i=1,dimsizes(levels)-1,1 @@ -113,7 +113,7 @@ begin ; Calculate thetail. Because ql and qi are not given, this is not possible, ; so the initial profile of thetail will be assumed theta. -; The remainder of the equation used in the gmtb-scm user's guide would be +; The remainder of the equation used in the gmtb-scm user's guide would be ; zero, leaving you with only theta. thetail = theta thetail@long_name = "initial profile of ice-liquid water potential "+ \ @@ -135,10 +135,10 @@ begin v@long_name = "initial profile of N-S horizontal wind" v@units = "m s^-1" -; Use GLDAS to derive the sensible and latent heat flux for the Cabauw -; location, then you can compare the GLDAS H/Le to the given intial Bowen +; Use GLDAS to derive the sensible and latent heat flux for the Cabauw +; location, then you can compare the GLDAS H/Le to the given intial Bowen ; ratio. Begin by reading in the data from each file. -; gl_dir = "/glade/scratch/damico/GLDAS_GABLS3/" +; gl_dir = "/path/to/GLDAS_GABLS3/" ; gl_00 = addfile(gl_dir+"GLDAS_NOAH025_3H.A20060701.0000.021.nc4.SUB.nc4", \ ; "r") @@ -249,7 +249,7 @@ begin w_ls@units = "m s^-1" ; Geostrophic winds are given at certain times but only at the surface. -; Instructions from GABLS suggest interpolation to surface winds up to +; Instructions from GABLS suggest interpolation to surface winds up to ; 2000 m, and then constant from that point. This should be done for each ; time step. Starting with time. u_geo_spec = (/ -7.8, -7.8, -6.5, -5.0, -5.0, -6.5 /) @@ -260,7 +260,7 @@ begin v_geo_t = (/ 0, 21600, 39600, 54000, 64800, 86400 /) v_geo = linint1(v_geo_t,v_geo_spec,False,time,0) -; Interpolate with height, linearly, from the surface values above to -2.0 +; Interpolate with height, linearly, from the surface values above to -2.0 ; m s^-1 for u and 2.0 m s^-1 for v. Above 2000 m, geostrophic wind is ; constant with height (according to GABLS guide). u_g = new((/ dimsizes(levels),dimsizes(time) /),float) @@ -287,10 +287,10 @@ begin u_g@units = "m s^-1" v_g@unit = "m s^-1" -; Horizontal temperature tendency due to advection, which can be converted to -; thetail tendency. The values are give; between 200-1000m, decreasing -; to zero down towards the surface and decreasing to zero from 1000m to -; 1500m, with zero entirely above. Once again, there needs to be +; Horizontal temperature tendency due to advection, which can be converted to +; thetail tendency. The values are give; between 200-1000m, decreasing +; to zero down towards the surface and decreasing to zero from 1000m to +; 1500m, with zero entirely above. Once again, there needs to be ; interpolation in time and with height. T_advec_spec = (/ -2.5e-5,7.5e-5, 0., 0. /) T_advec_time = (/ 0, 46800,64800,86400 /) @@ -316,10 +316,10 @@ begin "horizontal advection" h_advec_thetail@units = "K s^-1" -; The last remaining variable given in the data that the gmtb-scm can -; use is horizontal specific humidity tendency. The values are given +; The last remaining variable given in the data that the gmtb-scm can +; use is horizontal specific humidity tendency. The values are given ; between 200-1000m, decreasing to zero down towards the surface and -; decreasing to zero from 1000m to 1500, with zero entirely above. Once +; decreasing to zero from 1000m to 1500, with zero entirely above. Once ; again, there needs to be interpolation in time and with height. h_advec_spec = (/ 0., 8.e-8, 0., -8.e-8, 0., 0. /) h_advec_time = (/ 0, 32400, 43200, 50400, 61200, 86400 /) @@ -407,7 +407,7 @@ begin v_advec_thetail = 0. v_advec_thetail@long_name = "prescribed theta_il tendency due to " + \ "vertical advection" - v_advec_thetail@units = "K s^-1" + v_advec_thetail@units = "K s^-1" v_advec_qt = new((/ dimsizes(levels),dimsizes(time) /),float) v_advec_qt = 0. @@ -418,141 +418,141 @@ begin ; Noah LSM initialization slmsk = 1.0 ;corresponds to land from the UFS ICs slmsk@long_name = "land-sea-ice mask" - - tsfco = 305.0 + + tsfco = 305.0 tsfco@long_name = "sea surface temperature OR surface skin temperature over land OR sea ice surface skin temperature (depends on value of slmsk)" tsfco@units = "K" - + weasd = 0.0 weasd@long_name = "water equivalent accumulated snow depth" weasd@units = "mm" - + tg3 = 283.15 ;corresponds to case specs tg3@units = "K" tg3@long_name = "deep soil temperature" - + zorl = 15.0 ;(cm) from case specs zorl@long_name = "composite surface roughness length" zorl@units = "cm" - + zorlw = zorl ;(cm) from case specs zorlw@long_name = "surface roughness length over ocean" zorlw@units = "cm" - + alvsf = 0.23 ;corresponds to case specs alvsf@long_name = "60 degree vis albedo with strong cosz dependency" - + alnsf = 0.23 ;corresponds to case specs alnsf@long_name = "60 degree nir albedo with strong cosz dependency" - + alvwf = 0.23 ;corresponds to case specs alvwf@long_name = "60 degree vis albedo with weak cosz dependency" - + alnwf = 0.23 ;corresponds to case specs alnwf@long_name = "60 degree nir albedo with weak cosz dependency" - + facsf = 0.50556319952 ;corresponds to value from UFS ICs (static from fix files for C768) facsf@long_name = "fractional coverage with strong cosz dependency" - + facwf = 0.49443680048 ;corresponds to value from UFS ICs (static from fix files for C768) facwf@long_name = "fractional coverage with weak cosz dependency" - - vegfrac = 0.75 ; the value of 100% specified in the case + + vegfrac = 0.75 ; the value of 100% specified in the case ; specifications clashes with the maximum value ; for this gridpoint from UFS ICs vegfrac@long_name = "vegetation fraction" - + canopy = 0.5 ;corresponds to typical value for grassland in the growing season canopy@units = "kg m-2" canopy@long_name = "amount of water stored in canopy" - + f10m = missing_value ;this is not required f10m@long_name = "ratio of sigma level 1 wind and 10m wind" - + t2m = missing_value; this is not required t2m@long_name = "2-meter absolute temperature" t2m@units = "K" - + q2m = missing_value; this is not required q2m@long_name = "2-meter specific humidity" q2m@units = "kg kg-1" - - vegtyp = 10 ;corresponds to the "grasslands" type for the IGBP (vegsrc=1) + + vegtyp = 10 ;corresponds to the "grasslands" type for the IGBP (vegsrc=1) ;dataset vegtyp@long_name = "vegetation type (1-12)" - + soiltyp = 12 ;corresponds to "clay" soil type soiltyp@long_name = "soil type (1-12)" - + ;derive friction velocity from known values wind1 = sqrt(u_specified(1)^2 + v_specified(1)^2) uustar = von_K*wind1/log(u_h(1)/(0.01*zorl)) uustar@units = "m s-1" uustar@long_name = "friction velocity" - + ffmm = missing_value ;this is not required ffmm@long_name = "Monin-Obukhov similarity function for momentum" - + ffhh = missing_value ;this is not required ffhh@long_name = "Monin-Obukhov similarity function for heat" - + hice = 0.0 ;corresponds to value from UFS ICs hice@units = "m" hice@long_name = "sea ice thickness" - + fice = 0.0 ;corresponds to value from UFS ICs fice@long_name = "ice fraction" - + tisfc = tsfco ; there is no ice, but this corresponds to the surface skin temperature tisfc@units = "K" tisfc@long_name = "ice surface temperature" - + tprcp = missing_value; not required tprcp@units = "m" tprcp@long_name = "instantaneous total precipitation amount" - + srflag = missing_value; not required srflag@long_name = "snow/rain flag for precipitation" - + snwdph = 0.0 ;corresponds to case specs snwdph@units = "mm" snwdph@long_name = "water equivalent snow depth" - + shdmin = 0.01 ; corresponds to minimum vegetation fraction from surface fixed data (is not actually used in Noah LSM) shdmin@long_name = "minimum vegetation fraction" - + shdmax = 0.8 ; the maximum value from the surface fixed data is closer to 0.75 (is not actually used in Noah LSM) shdmax@long_name = "maximum vegetation fraction" - + slopetyp = 1 slopetyp@long_name = "slope type (1-9)" - + snoalb = 0.728796124458 ;corresponds to value from UFS ICs (static from fix files for C768) snoalb@long_name = "maximum snow albedo" - + sncovr = 0.0 ;corresponds to case specs sncovr@long_name = "snow area fraction" - + tsfcl = tsfco tsfcl@long_name = "surface skin temperature over land" tsfcl@units = "K" - + zorll = zorl ;(cm) from case specs zorll@long_name = "surface roughness length over land" zorll@units = "cm" - + zorli = zorl ;(cm) from case specs zorli@long_name = "surface roughness length over ice" zorli@units = "cm" - + stc = (/ 292.55, 289.9, 285.35, 283.15 /) stc@units = "K" stc@long_name = "initial profile of soil temperature" - + smc = (/ 0.33, 0.33, 0.33, 0.33 /) smc@units = "m3 m-3" smc@long_name = "initial profile of soil moisture" - + slc = smc ;all liquid (no ice) slc@units = "m3 m-3" slc@long_name = "initial profile of soil liquid moisture" @@ -594,7 +594,7 @@ begin filevardef(fo,"levels",typeof(levels),"levels") filevarattdef(fo,"levels",levels) fo->levels = (/ levels /) - + filevardef(fo,"soil_depth",typeof(soil_depth),"nsoil") filevarattdef(fo,"soil_depth",soil_depth) fo->soil_depth = (/ soil_depth /) @@ -615,7 +615,7 @@ begin filedimdef(g2,dimNames,dimSizes,dimUnlim) filedimdef(g3,dimNames,dimSizes,dimUnlim) - + filevardef(g1,"lat",typeof(lat),"ncl_scalar") filevarattdef(g1,"lat",lat) g1->lat = lat @@ -623,151 +623,151 @@ begin filevardef(g1,"lon",typeof(lon),"ncl_scalar") filevarattdef(g1,"lon",lon) g1->lon = lon - + filevardef(g1,"slmsk",typeof(slmsk),"ncl_scalar") filevarattdef(g1,"slmsk",slmsk) g1->slmsk = slmsk - + filevardef(g1,"tsfco",typeof(tsfco),"ncl_scalar") filevarattdef(g1,"tsfco",tsfco) g1->tsfco = tsfco - + filevardef(g1,"weasd",typeof(weasd),"ncl_scalar") filevarattdef(g1,"weasd",weasd) g1->weasd = weasd - + filevardef(g1,"tg3",typeof(tg3),"ncl_scalar") filevarattdef(g1,"tg3",tg3) g1->tg3 = tg3 - + filevardef(g1,"zorl",typeof(zorl),"ncl_scalar") filevarattdef(g1,"zorl",zorl) g1->zorl = zorl - + filevardef(g1,"zorlw",typeof(zorlw),"ncl_scalar") filevarattdef(g1,"zorlw",zorlw) g1->zorlw = zorlw - + filevardef(g1,"alvsf",typeof(alvsf),"ncl_scalar") filevarattdef(g1,"alvsf",alvsf) g1->alvsf = alvsf - + filevardef(g1,"alnsf",typeof(alnsf),"ncl_scalar") filevarattdef(g1,"alnsf",alnsf) g1->alnsf = alnsf - + filevardef(g1,"alvwf",typeof(alvwf),"ncl_scalar") filevarattdef(g1,"alvwf",alvwf) g1->alvwf = alvwf - + filevardef(g1,"alnwf",typeof(alnwf),"ncl_scalar") filevarattdef(g1,"alnwf",alnwf) g1->alnwf = alnwf - + filevardef(g1,"facsf",typeof(facsf),"ncl_scalar") filevarattdef(g1,"facsf",facsf) g1->facsf = facsf - + filevardef(g1,"facwf",typeof(facwf),"ncl_scalar") filevarattdef(g1,"facwf",facwf) g1->facwf = facwf - + filevardef(g1,"vegfrac",typeof(vegfrac),"ncl_scalar") filevarattdef(g1,"vegfrac",vegfrac) g1->vegfrac = vegfrac - + filevardef(g1,"canopy",typeof(canopy),"ncl_scalar") filevarattdef(g1,"canopy",canopy) g1->canopy = canopy - + filevardef(g1,"f10m",typeof(f10m),"ncl_scalar") filevarattdef(g1,"f10m",f10m) g1->f10m = f10m - + filevardef(g1,"t2m",typeof(t2m),"ncl_scalar") filevarattdef(g1,"t2m",t2m) g1->t2m = t2m - + filevardef(g1,"q2m",typeof(q2m),"ncl_scalar") filevarattdef(g1,"q2m",q2m) g1->q2m = q2m - + filevardef(g1,"vegtyp",typeof(vegtyp),"ncl_scalar") filevarattdef(g1,"vegtyp",vegtyp) g1->vegtyp = vegtyp - + filevardef(g1,"soiltyp",typeof(soiltyp),"ncl_scalar") filevarattdef(g1,"soiltyp",soiltyp) g1->soiltyp = soiltyp - + filevardef(g1,"uustar",typeof(uustar),"ncl_scalar") filevarattdef(g1,"uustar",uustar) g1->uustar = uustar - + filevardef(g1,"ffmm",typeof(ffmm),"ncl_scalar") filevarattdef(g1,"ffmm",ffmm) g1->ffmm = ffmm - + filevardef(g1,"ffhh",typeof(ffhh),"ncl_scalar") filevarattdef(g1,"ffhh",ffhh) g1->ffhh = ffhh - + filevardef(g1,"hice",typeof(hice),"ncl_scalar") filevarattdef(g1,"hice",hice) g1->hice = hice - + filevardef(g1,"fice",typeof(fice),"ncl_scalar") filevarattdef(g1,"fice",fice) g1->fice = fice - + filevardef(g1,"tisfc",typeof(tisfc),"ncl_scalar") filevarattdef(g1,"tisfc",tisfc) g1->tisfc = tisfc - + filevardef(g1,"tprcp",typeof(tprcp),"ncl_scalar") filevarattdef(g1,"tprcp",tprcp) g1->tprcp = tprcp - + filevardef(g1,"srflag",typeof(srflag),"ncl_scalar") filevarattdef(g1,"srflag",srflag) g1->srflag = srflag - + filevardef(g1,"snwdph",typeof(snwdph),"ncl_scalar") filevarattdef(g1,"snwdph",snwdph) g1->snwdph = snwdph - + filevardef(g1,"shdmin",typeof(shdmin),"ncl_scalar") filevarattdef(g1,"shdmin",shdmin) g1->shdmin = shdmin - + filevardef(g1,"shdmax",typeof(shdmax),"ncl_scalar") filevarattdef(g1,"shdmax",shdmax) g1->shdmax = shdmax - + filevardef(g1,"slopetyp",typeof(slopetyp),"ncl_scalar") filevarattdef(g1,"slopetyp",slopetyp) g1->slopetyp = slopetyp - + filevardef(g1,"snoalb",typeof(snoalb),"ncl_scalar") filevarattdef(g1,"snoalb",snoalb) g1->snoalb = snoalb - + filevardef(g1,"sncovr",typeof(sncovr),"ncl_scalar") filevarattdef(g1,"sncovr",sncovr) g1->sncovr = sncovr - + filevardef(g1,"tsfcl",typeof(tsfcl),"ncl_scalar") filevarattdef(g1,"tsfcl",tsfcl) g1->tsfcl = tsfcl - + filevardef(g1,"zorll",typeof(zorll),"ncl_scalar") filevarattdef(g1,"zorll",zorll) g1->zorll = zorll - + filevardef(g1,"zorli",typeof(zorli),"ncl_scalar") filevarattdef(g1,"zorli",zorli) g1->zorli = zorli - + filevardef(g2,"height",typeof(height),"levels") filevarattdef(g2,"height",height) g2->height = (/height/) @@ -803,15 +803,15 @@ begin filevardef(g2,"ozone",typeof(ozone),"levels") filevarattdef(g2,"ozone",ozone) g2->ozone = (/ozone/) - + filevardef(g2,"stc",typeof(stc),"nsoil") filevarattdef(g2,"stc",stc) g2->stc = (/stc/) - + filevardef(g2,"smc",typeof(smc),"nsoil") filevarattdef(g2,"smc",smc) g2->smc = (/smc/) - + filevardef(g2,"slc",typeof(slc),"nsoil") filevarattdef(g2,"slc",slc) g2->slc = (/slc/) diff --git a/scm/etc/scripts/GABLS3_LSM_RUC.ncl b/scm/etc/scripts/GABLS3_LSM_RUC.ncl index 167cb5023..1d096c3c3 100644 --- a/scm/etc/scripts/GABLS3_LSM_RUC.ncl +++ b/scm/etc/scripts/GABLS3_LSM_RUC.ncl @@ -5,7 +5,7 @@ load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" begin ;Define constants - + missing_value = -9999.0 g = 9.80665 ;gravity (m s-2) R_dry = 287. ;ideal gas dry air constant (J kg-1 K-1) @@ -24,7 +24,7 @@ begin ; Time, 01Jul2006 12:00:00 UTC - 02Jul2006 12:00:00 UTC ; Must be in seconds time = fspan(0,86400,145) - time@long_name = "elapsed time since the beginning of the simulation" + time@long_name = "elapsed time since the beginning of the simulation" time@units = "s" ; timb = fspan(0,86400,145) @@ -52,7 +52,7 @@ begin ; Total water specific humidity (q) at heights listed above qt = (/ 9.3e-3, 9.3e-3, 8.5e-3, 8.4e-3, 8.3e-3, 8.2e-3, 8.1e-3, \ - 8.0e-3, 7.5e-3, 2.0e-3, 0.3e-3, 0.01e-3, 0.003e-3, 0. /) + 8.0e-3, 7.5e-3, 2.0e-3, 0.3e-3, 0.01e-3, 0.003e-3, 0. /) qt@long_name = "initial profile of total water specific humidity" qt@units = "kg kg^-1" @@ -96,7 +96,7 @@ begin end do ; Solve the hypsometric equation for p2 to attain each new pressure level -; and fill the array (the variable to fill is levels, created above.) +; and fill the array (the variable to fill is levels, created above.) ; The value for levels(0) = p_surf(0) levels(0) = p_surf(0) do i=1,dimsizes(levels)-1,1 @@ -113,7 +113,7 @@ begin ; Calculate thetail. Because ql and qi are not given, this is not possible, ; so the initial profile of thetail will be assumed theta. -; The remainder of the equation used in the gmtb-scm user's guide would be +; The remainder of the equation used in the gmtb-scm user's guide would be ; zero, leaving you with only theta. thetail = theta thetail@long_name = "initial profile of ice-liquid water potential "+ \ @@ -135,10 +135,10 @@ begin v@long_name = "initial profile of N-S horizontal wind" v@units = "m s^-1" -; Use GLDAS to derive the sensible and latent heat flux for the Cabauw -; location, then you can compare the GLDAS H/Le to the given intial Bowen +; Use GLDAS to derive the sensible and latent heat flux for the Cabauw +; location, then you can compare the GLDAS H/Le to the given intial Bowen ; ratio. Begin by reading in the data from each file. -; gl_dir = "/glade/scratch/damico/GLDAS_GABLS3/" +; gl_dir = "/path/to/GLDAS_GABLS3/" ; gl_00 = addfile(gl_dir+"GLDAS_NOAH025_3H.A20060701.0000.021.nc4.SUB.nc4", \ ; "r") @@ -249,7 +249,7 @@ begin w_ls@units = "m s^-1" ; Geostrophic winds are given at certain times but only at the surface. -; Instructions from GABLS suggest interpolation to surface winds up to +; Instructions from GABLS suggest interpolation to surface winds up to ; 2000 m, and then constant from that point. This should be done for each ; time step. Starting with time. u_geo_spec = (/ -7.8, -7.8, -6.5, -5.0, -5.0, -6.5 /) @@ -260,7 +260,7 @@ begin v_geo_t = (/ 0, 21600, 39600, 54000, 64800, 86400 /) v_geo = linint1(v_geo_t,v_geo_spec,False,time,0) -; Interpolate with height, linearly, from the surface values above to -2.0 +; Interpolate with height, linearly, from the surface values above to -2.0 ; m s^-1 for u and 2.0 m s^-1 for v. Above 2000 m, geostrophic wind is ; constant with height (according to GABLS guide). u_g = new((/ dimsizes(levels),dimsizes(time) /),float) @@ -287,10 +287,10 @@ begin u_g@units = "m s^-1" v_g@unit = "m s^-1" -; Horizontal temperature tendency due to advection, which can be converted to -; thetail tendency. The values are give; between 200-1000m, decreasing -; to zero down towards the surface and decreasing to zero from 1000m to -; 1500m, with zero entirely above. Once again, there needs to be +; Horizontal temperature tendency due to advection, which can be converted to +; thetail tendency. The values are give; between 200-1000m, decreasing +; to zero down towards the surface and decreasing to zero from 1000m to +; 1500m, with zero entirely above. Once again, there needs to be ; interpolation in time and with height. T_advec_spec = (/ -2.5e-5,7.5e-5, 0., 0. /) T_advec_time = (/ 0, 46800,64800,86400 /) @@ -316,10 +316,10 @@ begin "horizontal advection" h_advec_thetail@units = "K s^-1" -; The last remaining variable given in the data that the gmtb-scm can -; use is horizontal specific humidity tendency. The values are given +; The last remaining variable given in the data that the gmtb-scm can +; use is horizontal specific humidity tendency. The values are given ; between 200-1000m, decreasing to zero down towards the surface and -; decreasing to zero from 1000m to 1500, with zero entirely above. Once +; decreasing to zero from 1000m to 1500, with zero entirely above. Once ; again, there needs to be interpolation in time and with height. h_advec_spec = (/ 0., 8.e-8, 0., -8.e-8, 0., 0. /) h_advec_time = (/ 0, 32400, 43200, 50400, 61200, 86400 /) @@ -407,7 +407,7 @@ begin v_advec_thetail = 0. v_advec_thetail@long_name = "prescribed theta_il tendency due to " + \ "vertical advection" - v_advec_thetail@units = "K s^-1" + v_advec_thetail@units = "K s^-1" v_advec_qt = new((/ dimsizes(levels),dimsizes(time) /),float) v_advec_qt = 0. @@ -418,199 +418,199 @@ begin ; Noah LSM initialization slmsk = 1.0 ;corresponds to land from the UFS ICs slmsk@long_name = "land-sea-ice mask" - - tsfco = 305.0 + + tsfco = 305.0 tsfco@long_name = "sea surface temperature OR surface skin temperature over land OR sea ice surface skin temperature (depends on value of slmsk)" tsfco@units = "K" - + weasd = 0.0 weasd@long_name = "water equivalent accumulated snow depth" weasd@units = "mm" - + tg3 = 283.15 ;corresponds to case specs tg3@units = "K" tg3@long_name = "deep soil temperature" - + zorl = 15.0 ;(cm) from case specs zorl@long_name = "composite surface roughness length" zorl@units = "cm" - + zorlw = zorl ;(cm) from case specs zorlw@long_name = "surface roughness length over ocean" zorlw@units = "cm" - + alvsf = 0.23 ;corresponds to case specs alvsf@long_name = "60 degree vis albedo with strong cosz dependency" - + alnsf = 0.23 ;corresponds to case specs alnsf@long_name = "60 degree nir albedo with strong cosz dependency" - + alvwf = 0.23 ;corresponds to case specs alvwf@long_name = "60 degree vis albedo with weak cosz dependency" - + alnwf = 0.23 ;corresponds to case specs alnwf@long_name = "60 degree nir albedo with weak cosz dependency" - + facsf = 0.50556319952 ;corresponds to value from UFS ICs (static from fix files for C768) facsf@long_name = "fractional coverage with strong cosz dependency" - + facwf = 0.49443680048 ;corresponds to value from UFS ICs (static from fix files for C768) facwf@long_name = "fractional coverage with weak cosz dependency" - - vegfrac = 0.75 ; the value of 100% specified in the case + + vegfrac = 0.75 ; the value of 100% specified in the case ; specifications clashes with the maximum value ; for this gridpoint from UFS ICs vegfrac@long_name = "vegetation fraction" - + canopy = 0.5 ;corresponds to typical value for grassland in the growing season canopy@units = "kg m-2" canopy@long_name = "amount of water stored in canopy" - + f10m = missing_value ;this is not required f10m@long_name = "ratio of sigma level 1 wind and 10m wind" - + t2m = missing_value; this is not required t2m@long_name = "2-meter absolute temperature" t2m@units = "K" - + q2m = missing_value; this is not required q2m@long_name = "2-meter specific humidity" q2m@units = "kg kg-1" - - vegtyp = 10 ;corresponds to the "grasslands" type for the IGBP (vegsrc=1) + + vegtyp = 10 ;corresponds to the "grasslands" type for the IGBP (vegsrc=1) ;dataset vegtyp@long_name = "vegetation type (1-12)" - + soiltyp = 12 ;corresponds to "clay" soil type soiltyp@long_name = "soil type (1-12)" - + ;derive friction velocity from known values wind1 = sqrt(u_specified(1)^2 + v_specified(1)^2) uustar = von_K*wind1/log(u_h(1)/(0.01*zorl)) uustar@units = "m s-1" uustar@long_name = "friction velocity" - + ffmm = missing_value ;this is not required ffmm@long_name = "Monin-Obukhov similarity function for momentum" - + ffhh = missing_value ;this is not required ffhh@long_name = "Monin-Obukhov similarity function for heat" - + hice = 0.0 ;corresponds to value from UFS ICs hice@units = "m" hice@long_name = "sea ice thickness" - + fice = 0.0 ;corresponds to value from UFS ICs fice@long_name = "ice fraction" - + tisfc = tsfco ; there is no ice, but this corresponds to the surface skin temperature tisfc@units = "K" tisfc@long_name = "ice surface temperature" - + tprcp = missing_value; not required tprcp@units = "m" tprcp@long_name = "instantaneous total precipitation amount" - + srflag = missing_value; not required srflag@long_name = "snow/rain flag for precipitation" - + snwdph = 0.0 ;corresponds to case specs snwdph@units = "mm" snwdph@long_name = "water equivalent snow depth" - + shdmin = 0.01 ; corresponds to minimum vegetation fraction from surface fixed data (is not actually used in Noah LSM) shdmin@long_name = "minimum vegetation fraction" - + shdmax = 0.8 ; the maximum value from the surface fixed data is closer to 0.75 (is not actually used in Noah LSM) shdmax@long_name = "maximum vegetation fraction" - + slopetyp = 1 slopetyp@long_name = "slope type (1-9)" - + snoalb = 0.728796124458 ;corresponds to value from UFS ICs (static from fix files for C768) snoalb@long_name = "maximum snow albedo" - + sncovr = 0.0 ;corresponds to case specs sncovr@long_name = "snow area fraction" - + tsfcl = tsfco tsfcl@long_name = "surface skin temperature over land" tsfcl@units = "K" - + zorll = zorl ;(cm) from case specs zorll@long_name = "surface roughness length over land" zorll@units = "cm" - + zorli = zorl ;(cm) from case specs zorli@long_name = "surface roughness length over ice" zorli@units = "cm" - + wetness = 0.37; from rucinit using Noah ICs wetness@long_name = "normalized soil wetness for land surface model" - + clw_surf_land = 0.0 clw_surf_land@long_name = "moist cloud water mixing ratio at surface over land" clw_surf_land@units = "kg kg-1" - + clw_surf_ice = 0.0 clw_surf_ice@long_name = "moist cloud water mixing ratio at surface over ice" clw_surf_ice@units = "kg kg-1" - + qwv_surf_land = qt(0)/(1.0 - qt(0)) qwv_surf_land@long_name = "water vapor mixing ratio at surface over land" qwv_surf_land@units = "kg kg-1" - + qwv_surf_ice = qwv_surf_land qwv_surf_ice@long_name = "water vapor mixing ratio at surface over ice" qwv_surf_ice@units = "kg kg-1" - + tsnow_land = 273.14 tsnow_land@long_name = "snow temperature at the bottom of the first snow layer over land" tsnow_land@units = "K" - + tsnow_ice = tsnow_land tsnow_ice@long_name = "snow temperature at the bottom of the first snow layer over ice" tsnow_ice@units = "K" - + snowfallac_land = 0.0 snowfallac_land@long_name = "run-total snow accumulation on the ground" snowfallac_land@units = "kg m-2" - + snowfallac_ice = 0.0 snowfallac_ice@long_name = "run-total snow accumulation on the ice" snowfallac_ice@units = "kg m-2" - + sncovr_ice = 0.0 sncovr_ice@long_name = "surface snow area fraction over ice" - + sfalb_lnd = 0.23 sfalb_lnd@long_name = "mean surface diffused sw albedo over land" - + sfalb_lnd_bck = 0.23 sfalb_lnd_bck@long_name = "surface snow-free albedo over ice" - + sfalb_ice = 0.6 sfalb_ice@long_name = "mean surface diffused sw albedo over ice" - + emis_ice = 0.97 emis_ice@long_name = "surface lw emissivity in fraction over ice" - + tslb = (/ 296.55, 295.95, 294.55, 292.55, 290.65, 288.39, 285.35, 284.03, 283.15/) tslb@units = "K" tslb@long_name = "initial profile of soil temperature for RUC LSM" - + smois = (/ 0.31, 0.31, 0.31, 0.31, 0.31, 0.31, 0.31, 0.31, 0.31/) smois@units = "fraction" smois@long_name = "volumetric fraction of soil moisture for RUC LSM" - + sh2o = smois sh2o@units = "fraction" sh2o@long_name = "volume fraction of unfrozen soil moisture for RUC LSM" - + smfr = (/ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0/) smfr@units = "fraction" smfr@long_name = "volume fraction of frozen soil moisture for RUC LSM" - + flfr = (/ 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0/) flfr@long_name = "flag for frozen soil physics for RUC LSM" @@ -651,7 +651,7 @@ begin filevardef(fo,"levels",typeof(levels),"levels") filevarattdef(fo,"levels",levels) fo->levels = (/ levels /) - + filevardef(fo,"soil_depth",typeof(soil_depth),"nsoil") filevarattdef(fo,"soil_depth",soil_depth) fo->soil_depth = (/ soil_depth /) @@ -672,7 +672,7 @@ begin filedimdef(g2,dimNames,dimSizes,dimUnlim) filedimdef(g3,dimNames,dimSizes,dimUnlim) - + filevardef(g1,"lat",typeof(lat),"ncl_scalar") filevarattdef(g1,"lat",lat) g1->lat = lat @@ -680,207 +680,207 @@ begin filevardef(g1,"lon",typeof(lon),"ncl_scalar") filevarattdef(g1,"lon",lon) g1->lon = lon - + filevardef(g1,"slmsk",typeof(slmsk),"ncl_scalar") filevarattdef(g1,"slmsk",slmsk) g1->slmsk = slmsk - + filevardef(g1,"tsfco",typeof(tsfco),"ncl_scalar") filevarattdef(g1,"tsfco",tsfco) g1->tsfco = tsfco - + filevardef(g1,"weasd",typeof(weasd),"ncl_scalar") filevarattdef(g1,"weasd",weasd) g1->weasd = weasd - + filevardef(g1,"tg3",typeof(tg3),"ncl_scalar") filevarattdef(g1,"tg3",tg3) g1->tg3 = tg3 - + filevardef(g1,"zorl",typeof(zorl),"ncl_scalar") filevarattdef(g1,"zorl",zorl) g1->zorl = zorl - + filevardef(g1,"zorlw",typeof(zorlw),"ncl_scalar") filevarattdef(g1,"zorlw",zorlw) g1->zorlw = zorlw - + filevardef(g1,"alvsf",typeof(alvsf),"ncl_scalar") filevarattdef(g1,"alvsf",alvsf) g1->alvsf = alvsf - + filevardef(g1,"alnsf",typeof(alnsf),"ncl_scalar") filevarattdef(g1,"alnsf",alnsf) g1->alnsf = alnsf - + filevardef(g1,"alvwf",typeof(alvwf),"ncl_scalar") filevarattdef(g1,"alvwf",alvwf) g1->alvwf = alvwf - + filevardef(g1,"alnwf",typeof(alnwf),"ncl_scalar") filevarattdef(g1,"alnwf",alnwf) g1->alnwf = alnwf - + filevardef(g1,"facsf",typeof(facsf),"ncl_scalar") filevarattdef(g1,"facsf",facsf) g1->facsf = facsf - + filevardef(g1,"facwf",typeof(facwf),"ncl_scalar") filevarattdef(g1,"facwf",facwf) g1->facwf = facwf - + filevardef(g1,"vegfrac",typeof(vegfrac),"ncl_scalar") filevarattdef(g1,"vegfrac",vegfrac) g1->vegfrac = vegfrac - + filevardef(g1,"canopy",typeof(canopy),"ncl_scalar") filevarattdef(g1,"canopy",canopy) g1->canopy = canopy - + filevardef(g1,"f10m",typeof(f10m),"ncl_scalar") filevarattdef(g1,"f10m",f10m) g1->f10m = f10m - + filevardef(g1,"t2m",typeof(t2m),"ncl_scalar") filevarattdef(g1,"t2m",t2m) g1->t2m = t2m - + filevardef(g1,"q2m",typeof(q2m),"ncl_scalar") filevarattdef(g1,"q2m",q2m) g1->q2m = q2m - + filevardef(g1,"vegtyp",typeof(vegtyp),"ncl_scalar") filevarattdef(g1,"vegtyp",vegtyp) g1->vegtyp = vegtyp - + filevardef(g1,"soiltyp",typeof(soiltyp),"ncl_scalar") filevarattdef(g1,"soiltyp",soiltyp) g1->soiltyp = soiltyp - + filevardef(g1,"uustar",typeof(uustar),"ncl_scalar") filevarattdef(g1,"uustar",uustar) g1->uustar = uustar - + filevardef(g1,"ffmm",typeof(ffmm),"ncl_scalar") filevarattdef(g1,"ffmm",ffmm) g1->ffmm = ffmm - + filevardef(g1,"ffhh",typeof(ffhh),"ncl_scalar") filevarattdef(g1,"ffhh",ffhh) g1->ffhh = ffhh - + filevardef(g1,"hice",typeof(hice),"ncl_scalar") filevarattdef(g1,"hice",hice) g1->hice = hice - + filevardef(g1,"fice",typeof(fice),"ncl_scalar") filevarattdef(g1,"fice",fice) g1->fice = fice - + filevardef(g1,"tisfc",typeof(tisfc),"ncl_scalar") filevarattdef(g1,"tisfc",tisfc) g1->tisfc = tisfc - + filevardef(g1,"tprcp",typeof(tprcp),"ncl_scalar") filevarattdef(g1,"tprcp",tprcp) g1->tprcp = tprcp - + filevardef(g1,"srflag",typeof(srflag),"ncl_scalar") filevarattdef(g1,"srflag",srflag) g1->srflag = srflag - + filevardef(g1,"snwdph",typeof(snwdph),"ncl_scalar") filevarattdef(g1,"snwdph",snwdph) g1->snwdph = snwdph - + filevardef(g1,"shdmin",typeof(shdmin),"ncl_scalar") filevarattdef(g1,"shdmin",shdmin) g1->shdmin = shdmin - + filevardef(g1,"shdmax",typeof(shdmax),"ncl_scalar") filevarattdef(g1,"shdmax",shdmax) g1->shdmax = shdmax - + filevardef(g1,"slopetyp",typeof(slopetyp),"ncl_scalar") filevarattdef(g1,"slopetyp",slopetyp) g1->slopetyp = slopetyp - + filevardef(g1,"snoalb",typeof(snoalb),"ncl_scalar") filevarattdef(g1,"snoalb",snoalb) g1->snoalb = snoalb - + filevardef(g1,"sncovr",typeof(sncovr),"ncl_scalar") filevarattdef(g1,"sncovr",sncovr) g1->sncovr = sncovr - + filevardef(g1,"tsfcl",typeof(tsfcl),"ncl_scalar") filevarattdef(g1,"tsfcl",tsfcl) g1->tsfcl = tsfcl - + filevardef(g1,"zorll",typeof(zorll),"ncl_scalar") filevarattdef(g1,"zorll",zorll) g1->zorll = zorll - + filevardef(g1,"zorli",typeof(zorli),"ncl_scalar") filevarattdef(g1,"zorli",zorli) g1->zorli = zorli - + filevardef(g1,"wetness",typeof(wetness),"ncl_scalar") filevarattdef(g1,"wetness",wetness) g1->wetness = wetness - + filevardef(g1,"clw_surf_land",typeof(clw_surf_land),"ncl_scalar") filevarattdef(g1,"clw_surf_land",clw_surf_land) g1->clw_surf_land = clw_surf_land - + filevardef(g1,"clw_surf_ice",typeof(clw_surf_ice),"ncl_scalar") filevarattdef(g1,"clw_surf_ice",clw_surf_ice) g1->clw_surf_ice = clw_surf_ice - + filevardef(g1,"qwv_surf_land",typeof(qwv_surf_land),"ncl_scalar") filevarattdef(g1,"qwv_surf_land",qwv_surf_land) g1->qwv_surf_land = qwv_surf_land - + filevardef(g1,"qwv_surf_ice",typeof(qwv_surf_ice),"ncl_scalar") filevarattdef(g1,"qwv_surf_ice",qwv_surf_ice) g1->qwv_surf_ice = qwv_surf_ice - + filevardef(g1,"tsnow_land",typeof(tsnow_land),"ncl_scalar") filevarattdef(g1,"tsnow_land",tsnow_land) g1->tsnow_land = tsnow_land - + filevardef(g1,"tsnow_ice",typeof(tsnow_ice),"ncl_scalar") filevarattdef(g1,"tsnow_ice",tsnow_ice) g1->tsnow_ice = tsnow_ice - + filevardef(g1,"snowfallac_land",typeof(snowfallac_land),"ncl_scalar") filevarattdef(g1,"snowfallac_land",snowfallac_land) g1->snowfallac_land = snowfallac_land - + filevardef(g1,"snowfallac_ice",typeof(snowfallac_ice),"ncl_scalar") filevarattdef(g1,"snowfallac_ice",snowfallac_ice) g1->snowfallac_ice = snowfallac_ice - + filevardef(g1,"sncovr_ice",typeof(sncovr_ice),"ncl_scalar") filevarattdef(g1,"sncovr_ice",sncovr_ice) g1->sncovr_ice = sncovr_ice - + filevardef(g1,"sfalb_lnd",typeof(sfalb_lnd),"ncl_scalar") filevarattdef(g1,"sfalb_lnd",sfalb_lnd) g1->sfalb_lnd = sfalb_lnd - + filevardef(g1,"sfalb_lnd_bck",typeof(sfalb_lnd_bck),"ncl_scalar") filevarattdef(g1,"sfalb_lnd_bck",sfalb_lnd_bck) g1->sfalb_lnd_bck = sfalb_lnd_bck - + filevardef(g1,"sfalb_ice",typeof(sfalb_ice),"ncl_scalar") filevarattdef(g1,"sfalb_ice",sfalb_ice) g1->sfalb_ice = sfalb_ice - + filevardef(g1,"emis_ice",typeof(emis_ice),"ncl_scalar") filevarattdef(g1,"emis_ice",emis_ice) g1->emis_ice = emis_ice - + filevardef(g2,"height",typeof(height),"levels") filevarattdef(g2,"height",height) g2->height = (/height/) @@ -916,23 +916,23 @@ begin filevardef(g2,"ozone",typeof(ozone),"levels") filevarattdef(g2,"ozone",ozone) g2->ozone = (/ozone/) - + filevardef(g2,"tslb",typeof(tslb),"nsoil") filevarattdef(g2,"tslb",tslb) g2->tslb = (/tslb/) - + filevardef(g2,"smois",typeof(smois),"nsoil") filevarattdef(g2,"smois",smois) g2->smois = (/smois/) - + filevardef(g2,"sh2o",typeof(sh2o),"nsoil") filevarattdef(g2,"sh2o",sh2o) g2->sh2o = (/sh2o/) - + filevardef(g2,"smfr",typeof(smfr),"nsoil") filevarattdef(g2,"smfr",smfr) g2->smfr = (/smfr/) - + filevardef(g2,"flfr",typeof(flfr),"nsoil") filevarattdef(g2,"flfr",flfr) g2->flfr = (/flfr/) diff --git a/test/README.md b/test/README.md index ebc4cfc5d..91878deae 100644 --- a/test/README.md +++ b/test/README.md @@ -7,11 +7,11 @@ and suites. It consists of the following scripts: * ``rt.sh`` - Driver for the regresion test that builds, runs and calls the summarize.sh script * ``rt_test_cases.py``- list of all supported cases and suites -* ``summarize.sh`` - Called by ``rt.sh`` to parse the output of each test to determine pass/fail +* ``summarize.sh`` - Called by ``rt.sh`` to parse the output of each test to determine pass/fail Currently, the following configurations are supported: -Machine | Cheyenne | Hera | Desktop | +Machine | Derecho | Hera | Desktop | ------------| ---------------|----------------|----------------| Compiler(s) | Intel, GNU | Intel | gfortran | Build Types | Release, Debug | Release, Debug | Release, Debug | @@ -39,11 +39,11 @@ The debug tests use a reduced runtime for faster turnaround and to conserve comp # To run the tests (no baseline generation or comparison): -On Cheyenne: +On Derecho: ``` cd test -./rt.sh cheyenne >& test.out & +./rt.sh derecho >& test.out & ``` On Hera: @@ -76,4 +76,3 @@ A useful workflow might consist of the following steps: 2. Run ``rt.sh ${machine} -g `` to generate a baseline and verify build/run 3. Make changes to your working copy 4. Run ``rt.sh ${machine} -c `` to verify your changes - diff --git a/test/rt.sh b/test/rt.sh index d8c3259fc..e5772d70a 100755 --- a/test/rt.sh +++ b/test/rt.sh @@ -8,7 +8,7 @@ # # Assumptions: # -# Command line arguments: machine name (hera or cheyenne) +# Command line arguments: machine name (hera or derecho) # -g run tests, generate baseline in # -c run tests, compare to baseline in # -h display usage @@ -35,7 +35,7 @@ function usage() { } function wait_for_criteria() { - + # Function that iteratively checks the return code of a given Unix command # and returns 0 when the command is successful or 1 if not @@ -67,7 +67,7 @@ function wait_for_criteria() { fi } -machines=( hera cheyenne desktop ) +machines=( hera derecho desktop ) executable_name=scm [[ $# -eq 0 ]] && usage # Display usage if no command-line arguments @@ -138,7 +138,7 @@ run_it=0 # Set to 1 to skip run (for t build_types=( Release Debug ) # Set all instances of CMAKE_BUILD_TYPE -if [ "${machine}" == "Cheyenne" ] ; then +if [ "${machine}" == "Derecho" ] ; then users=( $USER@ucar.edu ) compilers=( intel gnu ) use_batch_system=true @@ -298,13 +298,13 @@ done # End compiler loop n_tests=0 for compiler in "${compilers[@]}"; do for build_type in "${build_types[@]}"; do - + echo "-------------------------------------------------------" >> ${TEST_OUTPUT} echo "Monitoring ${compiler} ${build_type} run..." >> ${TEST_OUTPUT} echo "-------------------------------------------------------" >> ${TEST_OUTPUT} build_type_lc=$(echo "${build_type}" | tr '[A-Z]' '[a-z]') # Make build_type all lower case - RUN_DIR=$TOP_DIR/scm/run_${compiler}_${build_type_lc} + RUN_DIR=$TOP_DIR/scm/run_${compiler}_${build_type_lc} batch_out=${job_prefix}_${compiler}_${build_type_lc}.o* # Without PID extension #-----------------------------------------------------------------------