LDAP: couldn't connect to LDAP server

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
noresm:runmodel:advancednoresm2 [2014-01-29 14:08:12]
alfg
noresm:runmodel:advancednoresm2 [2022-05-31 09:29:32] (current)
Line 1: Line 1:
-===== Advanced configuration of NorESM2 =====+====== Advanced configuration of NorESM2 ======
  
-=== Creating a new compset for use of CAM5-Oslo aerosols ===+**NOTE THAT THE COMPSETS MENTIONED IN THIS EXAMPLE ARE NO LONGER MAINTAINED! THE GENERAL EXPLANATION AND IDEAS ARE STILL VALID! 
 +** 
 +===== Creating a new compset =====
  
-In this example we use the CESM1.2 compset FAMIPC5 (AMIP run with CAM5) as basis.  +The essential file to edit is  
-If starting from fresh, include the new CAM5-Oslo on a new directory;+<file> 
 +~/noresm/scripts/ccsm_utils/Case.template/config_compsets.xml 
 +</file>
  
-== ~/noresm/models/atm/cam/src/physics/cam_oslo/ ==+This examples shows how to simply add a to the "F_AMIP_CAM5" compset:
  
-then add the new CAM5-Oslo capability by editing the following files:+Under "<!-- F compsets -->", add
  
-== ~/noresm/models/atm/cam/bld/configure ==+<file> 
 +<COMPSET sname="F_AMIP_CAM5-OSLO"     alias="FAMIPOSLO"  >AMIP_CAM5%OSLO_CLM40%SP_CICE%PRES_DOCN%DOM_RTM_SGLC_SWAV</COMPSET> 
 +</file>
  
-Under "GetOptions(add+The "CAM5%OSLOoptions have to be defined, so a line like this is needed:
  
-    "cam_oslo=s               =\$opts{'cam_oslo'},+<file> 
 +<CAM_CONFIG_OPTS compset="_CAM5%OSLO"     >-phys cam5 -cam_oslo aerlife</CAM_CONFIG_OPTS> 
 +</file>
  
-At the end of the section starting with "The default physics package is cam5...", add+The compset needs a description, we also need the line 
 +<file> 
 +<desc compset="_CAM5%OSLO">cam 5 physcs and oslo aerosols</desc>  
 +</file>
  
-    #cam-oslo configuration +We could also define a specific use-case (namelistfor our compset. This would need a line like: 
-    my $cam_oslo='none'; +<file> 
-    my $cam_oslo_nadv = 0; + <CAM_NML_USE_CASE compset="_CAM5%OSLO       >my_namelist</CAM_NML_USE_CASE> 
-    # Check cam-oslo option +</file>
-    if (defined $opts{'cam_oslo'}){ +
- $cam_oslo=$opts{'cam_oslo'}; +
-    } +
-    if($cam_oslo !'none' and $cam_oslo != 'aerlife'){ +
-    die "only valid cam_oslo configuration is currently 'aerlife' or 'none' \n "+
-    } +
-    if($cam_oslo eq 'aerlife'){ +
-        $cam_oslo_nadv =23; +
-    }+
  
-At the end of the section starting with "User source directories", add+This would only work if the file my_namelist.xml exists as  
 +<file> 
 +noresm/models/atm/cam/bld/namelist_files/use_cases/my_namelist.xml 
 +</file>
  
-    #if cam_oslo is defined its source goes before the usr_sources 
-    if ($cam_oslo ne 'none'){ 
-     my @usr_src_dirs = split ',', $cfg_ref->get('usr_src'); 
-     unshift(@usr_src_dirs, "$cam_root/models/atm/cam/src/physics/cam_oslo"); 
-     my $usr_src_dirs_string = join(",",@usr_src_dirs); 
-     $cfg_ref->set('usr_src',$usr_src_dirs_string); 
-    } 
  
-At the end of the section starting with "Number of advected constituents", add +===== Setting up a case with the new compset and building the model =====
-  +
-         #CAM5-Oslo +
-            if ($cam_oslo_nadv > 0){ +
-     $nadv +$cam_oslo_nadv; +
-             if($print >=2 ){ print "Advected constituents added by CAM-Oslo $cam_oslo : $cam_oslo_nadv$eol";+
-     }+
  
-At the end of the section starting with "For the CPP tokens"add+It should now be possible to create a new case directorywhich we here name FAMIPOSLOtst 
 +and configure with 1 degree horizontal atmospheric resolution;
  
-    if ($cam_oslo eq 'aerlife'){ +<file> 
-         $usr_cppdefs .= ' -DAERLIFE -DDIRIND'; +./create_newcase -case ../cases/FAMIPOSLOtst -compset FAMIPOSLO -mach hexagon -res f09_f09 
-    }+</file>
  
-The two chosen cppdefs options make sure that all code under "#ifdef AERLIFE" and "#ifdef DIRIND" is compiled, +and finally set up and compile the model: 
-so that both the CAM5-Oslo aerosol life cycle and its direct and indirect effects on climate are taken into account +<file> 
 +cd ../cases/FAMIPOSLOtst 
 +</file>
  
-== ~/noresm/models/atm/cam/bld/config_files/definition.xml == +<file> 
 +./cesm_setup 
 +</file>
  
-Under "<config_definition>", add+<file> 
 +./FAMIPOSLOtst.build 
 +</file>
  
-    <entry id="cam_oslo" value=""> +===== Why does it work to change config_compsets.xml ?   =====
-    Options for building cam-oslo +
-    </entry>+
  
 +In NorESM there are 3 new config-options for CAM:  
 +  * -cam-oslo aerlife (turns on transport of oslo tracers)
 +  * -cam-oslo dirind  (also turns on interaction with radiation)
 +  * -cam-oslo warmclouds (also turns on interaction with warm clouds)
  
-== ~/noresm/scripts/ccsm_utils/Case.template/config_compsets.xml == +They change number of tracers and turn on different preprocessor flags in in a perl script called "configure", see:  
 +<file> 
 +models/atm/cam/bld/configure 
 +</file>
  
-Under "<!-- F compsets -->", add+To understand the implementation do: 
 +<file> 
 +svn diff -r 202 models/atm/cam/bld/configure  
 +</file>
  
-    <COMPSET sname="F_AMIP_CAM5-OSLO"     alias="FAMIPOSLO"  >AMIP_CAM5%OSLO_CLM40%SP_CICE%PRES_DOCN%DOM_RTM_SGLC_SWAV</COMPSET>+The new oslo-options also need to be defined, see  
 +<file> 
 +models/atm/cam/bld/config_files/definition.xml 
 +</file>
  
 +To see how these new options were added, do:
 +<file>
 +svn diff -r 202 models/atm/cam/bld/config_files/definition.xml
 +</file>
  
-=== Setting up a case with the new compset and building the model === 
  
-It should now be possible to create a new case directory, which we here name FAMIPOSLOtst +===== Configure nudging =====
-and configure with 1 degree horizontal atmospheric resolution;+
  
-./create_newcase -case ../cases/FAMIPOSLOtst -compset FAMIPOSLO -mach hexagon -res f09_f09+==== Create the met-data ====
  
-and finally set up and compile the model:+First run the model to produce 6 hourly data. The following namelists are needed:
  
-cd ../cases/FAMIPOSLOtst +<file> 
-./cesm_setup +user_nl_cam 
-./FAMIPOSLOtst.build+&camexp 
 +mfilt           = 1,  4, 
 +nhtfrq          = 0,  -6, 
 +avgflag_pertape ='A','I', 
 +fincl2          = 'PS','U','V','TAUX','TAUY','FSDS','TS','T','Q','PHIS','QFLX','SHFLX' 
 +</file> 
 + 
 +<file> 
 +user_nl_clm 
 +&clmexp 
 +hist_mfilt             = 1,4 
 +hist_nhtfrq            = 0,-6 
 +hist_avgflag_pertape   = 'A','I' 
 +hist_fincl2            = 'SNOWDP','H2OSNO','H2OSOI' 
 +</file> 
 + 
 +==== Use the met-data in another run ==== 
 + 
 +First create a compset which has the configure-option "-offline_dyn" Check in config_compsets.xml which compsets have this configure-option added. See for example the compset NFAMIPNUDGEPTAERO in https://svn.met.no/NorESM/noresm/branches/featureCAM5-OsloDevelopment_trunk2.0-1/noresm/scripts/ccsm_utils/Case.template/config_compsets.xml 
 + 
 +Then use this compset to create a caseYou need the following user-input (for example in your user_nl_cam) 
 + 
 +<file> 
 +&metdata_nl 
 +met_data_file='/work/shared/noresm/inputForNudging/FAMIPC5NudgeOut/atm/hist/FAMIPC5NudgeOut.cam.h1.1979-01-01-00000.nc' 
 +met_filenames_list = '/work/shared/noresm/inputForNudging/FAMIPC5NudgeOut/atm/hist/fileList.txt' 
 +</file> 
 + 
 +This info can be added directly in a use_case which you associate with the compset created (see e.g. 2000_cam5_oslonudge.xml)  
 + 
 +where met_data_file is the first met-data file to read, and met_filenames_list is a list of the following met-data. The first lines of the file should look something like this (guess what the rest of the file should look like? 8-o: )  
 +<file> 
 +/work/shared/noresm/inputForNudging/FAMIPC5NudgeOut/atm/hist/FAMIPC5NudgeOut.cam.h1.1979-01-01-00000.nc 
 +/work/shared/noresm/inputForNudging/FAMIPC5NudgeOut/atm/hist/FAMIPC5NudgeOut.cam.h1.1979-01-02-00000.nc 
 +/work/shared/noresm/inputForNudging/FAMIPC5NudgeOut/atm/hist/FAMIPC5NudgeOut.cam.h1.1979-01-03-00000.nc 
 +</file> 
 + 
 +This file can be created at the place where you put the metdata with this command:  
 +<file> 
 +alfgr@hexagon-4:/work/shared/noresm/inputForNudging/FAMIPC5NudgeOut/atm/hist> ls -d -1 $PWD/*.h1.*.nc > fileList.txt 
 +</file> 
 + 
 +==== Namelist options ==== 
 +When looking at aerosol indirect effects, it's recommended to nudge only U, V and PS: 
 +<file> 
 +&metdata_nl 
 + met_nudge_only_uvps = .true. 
 +</file> 
 + 
 +Choose relaxation time (hours). Use the same time as dt in met_data_file: 
 +<file> 
 +&metdata_nl 
 + met_rlx_time = 6 
 +</file> 
 + 
 + 
 +==== Nudge to ERA-interim reanalysis ==== 
 +Link to ERA-interim metdata instead of model produced metdata. Remember to choose the files corresponding to your resolution (examples below are for f09_f09 and 32 levels in the vertical): 
 +<file> 
 +&metdata_nl 
 + met_data_file = '/work/shared/noresm/inputdata/noresm-only/inputForNudging/ERA_f09f09_30L_days/2001-01-01.nc' 
 + met_filenames_list = '/work/shared/noresm/inputdata/noresm-only/inputForNudging/ERA_f09f09_30L_days/fileList2001-2015.txt' 
 +</file>
  
 +Add also the ERA-topography (no matter which fields you are nudging):
 +<file>
 +&cam_inparm
 + bnd_topo = '/work/shared/noresm/inputdata/noresm-only/inputForNudging/ERA_f09f09_30L_days/ERA_bnd_topo.nc'
 +</file>
  
  • noresm/runmodel/advancednoresm2.1391004492.txt.gz
  • Last modified: 2022-05-31 09:23:24
  • (external edit)