wiki:WRF4G2.0/Experiment

Version 54 (modified by carlos, 7 years ago) (diff)

--

Experiment Configuration

In order to design a WRF4G experiment you need to edit a file called experiment.wrf4g. From this file, WRF4G will generate all WRF configuration files required to run the simulations planned for the experiment.

Configuration format

The configuration experiment file consists of sections, each led by a [section] header, followed by key = value entries. Lines beginning with # are ignored. Allowing sections are [DEFAULT] and [resource_name].

DEFAULT section

The DEFAULT section provides default values for all other sections. And its key values are:

  • name: Name of the experiment it MUST be unique.
  • max_dom: Number of domains.
  • date_time: Describe dates for a list of realizations with the following format : start_date | end_date | simulation_interval | simulation_length | chunk_size
    • start_date: Beginning of the list of realizations.
    • end_date: End of the list of realizations.
    • simulation_interval: Interval (in hours) between realizations (optional).
    • simulation_length: Length (in hours) of each realization (optional).
    • chunk_size: Length (in hours) of a temporal piece of a realization (optional). That means that every chunk_size a wrf-restart will be generated.
  • chunk_restart: Either yes or no (default value is yes). If you won't create a restart files when a chunk finishes.
  • calendar: Either standard or leap (default value is standard). Type of calendar to create realizations.
  • timestep_dxfactor: If present, the time step is computed as dx*timestep_dxfactor, in kilometers. Defaults to 6, as suggested by the WRF team for most applications. Under some circumstances (cfl problems) a lower value may be needed. In any case, the time step is adjusted to the highest value lower than timestep_dxfactor times dx fitting evenly in one hour period.
  • np: Number of processors requested in a parallel job.
  • requirements: Requirements for computing rerources where the experiment is going to run (for more information see advanced configuration).
  • environment: Experiment environment variables are configuration options for jobs (for more information see advanced configuration).
  • clean_after_run: Either yes or no (default value is no), indicating whether or not temporary simulation files should be removed. The maintenance of these files on running place could be desirable for debugging purposes.
  • save_wps: Either yes or no (default value is no), indicating whether boundary and initial conditions (real.exe output) should be preserved or not. They will be used if the experiment is relaunched again.
  • real_parallel: Either yes or no (default value is no), indicating whether the real.exe binary is compiled in serial or parallel mode.
  • wrf_parallel: Either yes or no (default value is yes), indicating whether the wrf.exe binary is compiled in serial or parallel mode.
  • domain_path: Path of the directory with the information about the domain of the simulations; this is, the files generated by geogrid.exe (nameslit.wps & geo_em.d[nn].nc).
  • preprocessor: Name (just the ending [NAME] section in preprocessor.[NAME]) of the necessary pre-processor useful to make the specific input data available for WRF model. Users could not be interested in the permanent WRF-necessary modification of any source of data. With the specification and design of a pre-processor, necessary WRF modifications (e.g.: ASCII to GRIB, variables re-coding, complete input data). Pre-processors are included in repository/apps/preprocessor/.
  • extdata_vtable: Vtable of the ungrib module to be used to decode provided GRIB input data.
  • extdata_path : Path to the input data. It must be consistent with the pre-processor design.
  • extdata_member: Set of labels (| separated) for multi-member ensemble. Thus, input data should have the following format :
    `extdata_path`/member0
    `extdata_path`/member1
    ...
    
  • extdata_interval: Interval of the input data (in seconds). On multiple input data sources use the smallest one.
  • postprocessor: Users might be interested in the transformation of the WRF output files. A first generic post-process of the output will be automatically carried out if a valid name postprocessor.[NAME] is provided. Post-processors are included under the repository/apps/postprocessor/ directory.
  • app: This is to define applications with the following format: tag | type | value
    • tag: Name identifier. wrf_all_in_one tag is a special name that indicates which is a bundle that includes WRFV3 and WPS files, netcdf, ncos cdos and openmpi libraries.
    • type: Either bundle or command.
    • value: If type is bundle indicates the path of the bundle that can have the following formats zip, tar, tar.gz (or tgz), and tar.bz2 (or tbz2). If type is command you can type shell commands to configure netcdf, openmpi or WRF.
  • namelist_version: Namelist version to use ( from 3.2 to 3.7 ).
  • namelist_label_comb: Set of labels (| separated) for multi-physics combinations defined on namelist_values.
  • namelist_values: Users are able to over-write or add parameters to the namelist file. The name must be the same as the namelist.input entry.

Resource section

Each resource section has to begin with the line [resource_name] followed by key = value entries. Thus, experiment variables such as:

  • np
  • requirements
  • environment
  • clean_after_run
  • save_wps
  • real_parallel
  • wrf_parallel
  • domain_path
  • preprocessor
  • extdata_path
  • postprocessor
  • app
  • output_path

can be defined depending on each computing resource.

How to create one

You can write a experiment.wrf4g from scratch or use the templates that WRF4G provides by typing :

$ wrf4g exp test define --from-template single

Example

[DEFAULT]
# Experiment configuration
name                 = test
# Simulation domain
max_dom              = 1
# Experiment time-specification
#                      start_date          | end_date            | chunk_size_h
date_time            = 2011-08-28_12:00:00 | 2011-08-30_00:00:00 | 12
calendar             = standard
timestep_dxfactor    = 6
# Running options 
np                   = 1
requirements         = ARCH = "x86_64"
clean_after_run      = yes
save_wps             = no
real_parallel        = no
wrf_parallel         = yes
# Input data
domain_path          = /home/carlos/WRF4G_2_0/repository/domains/Santander_50km
# Vtables must exist as Vtable.[input_extdata]
extdata_vtable       = GFS
extdata_path         = /home/user/WRF4G_2_0/repository/input/NCEP/GFS
# Seconds between global analysis input times
extdata_interval     = 21600
preprocessor         = default
# Output
output_path          = /home/user/test/output
postprocessor        = SFC
# app
app                  = wrf_all_in_one | bundle | /home/user/WRF4G_2_0/repository/apps/WRF/WRFbin-3.4.1_r2265_gfortran.tar.gz
# WRF-namelist parameters. Override namelist.input variables here
namelist_version     = 3.4.1
namelist             = spec_bdy_width     | 10
                       spec_zone          | 1
                       relax_zone         | 9
                       feedback           | 0
                       history_interval   | 180
                       frames_per_outfile | 3
                       e_vert             | 28
                       mp_physics         | 4
                       radt               | 15
                       ra_lw_physics      | 3
                       ra_sw_physics      | 3