gsi setup, run and namelist

41
Hui Shao GSI Setup, Run and Namelist GSI Community Tutorial, June 28-30, 2010, Boulder, CO

Upload: lowri

Post on 25-Feb-2016

100 views

Category:

Documents


0 download

DESCRIPTION

GSI Setup, Run and Namelist. Hui Shao. GSI Community Tutorial, June 28-30, 2010, Boulder, CO. Observation processing and assimilation PrepBUFR and BUFR processing: 06/29, Tue Community Tools (1): PrebBUFR Converter : 06/29, Tue Satellite Radiance Assimilation: 06/29, Tue - PowerPoint PPT Presentation

TRANSCRIPT

Page 1: GSI Setup, Run and  Namelist

Hui Shao

GSI Setup, Run and Namelist

GSI Community Tutorial, June 28-30, 2010, Boulder, CO

Page 2: GSI Setup, Run and  Namelist

ObservationError

Observation

Analysisand

diagnostics

BackgroundError

Background

GSI

Background Error and Observation Background and Observation Error Estimation and Tuning: 06/29, TueCommunity Tools (2): GEN_BE: 06/29, Tue

Observation processing and assimilation • PrepBUFR and BUFR processing: 06/29,

Tue• Community Tools (1): PrebBUFR

Converter: 06/29, Tue• Satellite Radiance Assimilation: 06/29,

Tue• Radar Observation Assimilation: 06/30,

Wed• GPS RO Data Assimilation: 06/30, Wed

Output GSI Diagnostics: 06/29, Tue

Advanced GSI 4D-Var: 06/30, Wed

Overall• Overview of GSI: 06/28, Mon• GSI Code (SE Aspect): 06/28, Mon• GSI Setup, Run and Namelist:

06/28, Mon

Page 3: GSI Setup, Run and  Namelist

Outline• Installing GSI • Running GSI

• Cycling, partly cycling, cold-start

• Basic runtime options (namelist)

This talk is tailored based on GSI Community Release V2.0.

Page 4: GSI Setup, Run and  Namelist

Installing GSI(Community Release only)

For people who are using the NCEP version of GSI, please be aware the installation procedure and portability of the GSI code might be different from the community release.

Page 5: GSI Setup, Run and  Namelist

Source Codes• Download GSI source code (comGSI_v2.tar.gz) from

http://www.dtcenter.org/com-GSI/users/downloads/index.php

o Unpack the tarball, you may use the command“tar –zxvf comGSI_v2.tar.gz” or“gunzip comGSI_v2.tar.gz” and “tar –xvf

comGSI_v2.tar”

Page 6: GSI Setup, Run and  Namelist

NCEP GSI Repository

GSI Core and Extra Features

fix

src

scripts

GSICommunity

Release

fix/ libs/

run/

src/main/

configurecompileuntil/arch/

cleanmakefile

makefile

Page 7: GSI Setup, Run and  Namelist

o Use “which” (e.g., which xlf) command to find the compiler path.

o To check version number, use “xlf –qversion”, “pgf90 –V” and “ifort –v” for xlf, pgi and Intel Fortran compilers.

Fortran Compiler• Supported and Tested Platforms

• IBM: xlf• LINUX: pgi 7.0,8.0,9.0• LINUX: Intel 10.0 and 11.0• MAC OSX: PGI 8.0

• Supported and Tested by a 3rd party• SGI Altix: Intel 10.0

Please share with us your experience on the various platforms and compilers.

Page 8: GSI Setup, Run and  Namelist

External Libraries Required by GSI netCDF (network Common Data Form) v3.6+ (not v4.0 yet):

http://www.unidata.ucar.edu/software/netcdf/ WRF I/O API (WRF I/O and Model Coupling Application Program

Interface) v3.2:WRF-ARW or NMM provided in the same tar file http://www.mmm.ucar.edu/wrf/users/downloads.html or http://www.dtcenter.org/wrf-nmm/users/downloads/index.php

ESSL (IBM) or LAPACK and BLAS (LINUX and MAC OSX) ESSL (Engineering and Scientific Subroutine Library):

http://www-03.ibm.com/systems/software/essl/index.html Usually, the IBM compiler automatically set up the ESSL. No

manual set up required.• LAPACK (Linear Algebra PACKage): http://www.netlib.org/lapack/

BLAS (Basic Linear Algebra Subprograms): http://www.netlib.org/blas/

LINUX: usually, the PGI compiler automatically set up the lib. LINUX: Intel compiler, please set up the lib manually. MAC OSX: PGI compile, please set up the lib manually.

To set up environment variable.o csh/tcsh users: use “setenv” (e.g., setenv NETCDF $netcdfpath)o bash/ksh users: use “export” (e.g., export NETCDF $netcdfpath)

Page 9: GSI Setup, Run and  Namelist

Internal Libraries Required by GSI(included in the GSI tarball)

NCEP GSI Repository

fix

src

scripts

GSICommunity

Release

fix/ libs/

run/

src/main/

configurecompileuntil/arch/

cleanmakefile

makefile

Name (~/src/libs) Descriptionbufr NCEP BUFR Librarycrtm_gfsgis JCSDA Commuity Radiative Transfer Model

(CRTM)gfsio Unformatted Fortran record for GFS I/Osfcio NCEP GFS surface file I/O modulesigio NCEP GFS atmospheric file I/O modulesp NCEP spectral-grid transforms (global

application only)w3 NCEP W3 library (date/time manipulation,

GRIB)

No manual setup/compilation required if you use configure/compile utility provided by the GSI tarball.

Page 10: GSI Setup, Run and  Namelist

NCEP GSI Repository

Configure and Compile GSI

fix

src

scripts

GSICommunity

Release

fix/ libs/

run/

src/main/

configurecompileuntil/arch/

cleanmakefile

makefile

Functions:• Checks the system hardware and software (netCDF,

WRF, and math libraries).• Offers the user choices for configuring GSI. • Creates configure.gsi, which contains compilation

options, paths, rules, etc. specific to your computer and compiler choice, and can be edited to change compilation options, if desired.

• Compiles both internal libraries and GSI source code and create gsi.exe.

Page 11: GSI Setup, Run and  Namelist

Configure GSI>cd $your_sourcecode_dir/comGSI_v2>./configure

./configure.gsi will be created if succeed.

Will use NETCDF in dir: /usr/local/netcdf** WARNING: No path to WRF_DIR and environment variable WRF_DIR not set.** would you like to try to fix? [y]

Will use NETCDF in dir: /usr/local/netcdfWill use WRF in dir: /ptmp/huishao/tutorial/comGSI_v2/../WRFV3------------------------------------------------------------------------Please select from among the following supported platforms. 1. AIX 64-bit (dmpar) 2. AIX 32-bit (dmpar)Enter selection [1-2] : dmpar: distributed-memory

parallel

• Example 1: NETCDF path was set up but not WRF directory

• Example 2: Compilation options on IBM

For unsupported platforms, you may start from ~/comGSI_v2/arch/configure.defaults. Change the settings for your platform then rerun configure.

Page 12: GSI Setup, Run and  Namelist

Compile GSI>cd $your_sourcecode_dir/comGSI_v2>./compile (or ./compile >& $your_log_filename)

~/comGSI_v2/run/gsi.exe will be created if succeed.

Get help on the compilation:>./compile –h

Clean the GSI directory before making your next compilation:> ./clean -a

Page 13: GSI Setup, Run and  Namelist

Running GSI

The following is tailored for 3D-Var and regional applications.

Page 14: GSI Setup, Run and  Namelist

BackgroundError(gen_be)

Forecast(WRF)

xb

xaUpdate Lateral& Lower BCs(UPDATE_BC)

BackgroundPreprocessing(WPS , real)

xlbc

Blue --> Supported by GSI Team

Cycled Background

B0

yo , R

Cold-Start Background

xf

GSI

Example: GSI in a WRF System

Page 15: GSI Setup, Run and  Namelist

GSI Input and Output

ObservationError

Observation

Analysisand

diagnostics

BackgroundError

Background

GSI

Namelist

Statistical and

control files (“fixed”)

Page 16: GSI Setup, Run and  Namelist

Before You Run…Check GSI executable has been created

approximately~/comGSI_v2/run/gsi.exe

Obtain background filesDepending in which mode (cycling or cold start) the GSI

is run, the background files for the GSI can either come from the forecast from the previous cycle or from any other model simulations or forecasts.WRF NMM input field in binary formatWRF NMM input field in netCDF formatWRF ARW input field in binary formatWRF ARW input field in netCDF formatGFS input field in binary formatGMAO global model input field in binary format

Page 17: GSI Setup, Run and  Namelist

Before You Run…Obtain observation files.

The NCAR CISL Research Data Archive (RDA):http://dss.ucar.edu/

NCEP public server:http://www.emc.ncep.noaa.gov/data/

NCAR Mass Storage System (MSS): authorized access

GSD Mass Storage System: authorized accessOr any places you may obtain

PREPBUFR formatted data: conventional (including satellite derived data)

BUFR formatted data: satellite radiance, radar reflectivity, GPS radio occultation(RO) refractivity/bending angle

GSI can run pseudo single observation test (PSOT) without real observations.

Page 18: GSI Setup, Run and  Namelist

18

Check statistic and control files under ~/comGSI_v2/fixBackground errors (BE)

nam_nmmstat_na (nam_glb_berror.f77_Little_Endian): computed from NCEP NAM statistics

nam_glb_berror.f77 (nam_glb_berror.f77_Little_Endian): computed from NCEP GFS statistics

Or you may produce your own BE using the community tool GEN_BE (talk on 06/29)

Observation errors nam_errtable.r3dv

Observation data control file (info files) Global_convinfo.txt: Conventional obs. Information file Global_pcpnfo.txt: Satellite channel information file global_satinfo.txt: precipitation rate observation information file

Bias correction used by radiance analysis Global_satangbias.txt: Satellite scan angle dependent bais correction file ndas.t06z.satbias.tm03: satellite variational bias correction coefficient file

Radiance coefficient used by CRTM (~/comGSI_v2/fix/crtm_gfsgsi)

Before You Run…

Page 19: GSI Setup, Run and  Namelist

Set up GSIWe do provide a sample run script for you

to start from~/comGSI_v2/run/run_gsi.ksh

The following slides will describe the basic steps for running GSI, assuming conventional data are assimilated. • Create a working directory ($WORK_ROOT in run_gsi.ksh), for example, “your_choice_of_ working_dir”.

> mkdir your_choice_of_working_dir• Go into the working directory:

> cd your_choice_of_working_dir

Page 20: GSI Setup, Run and  Namelist

Working Directory - Input

> cp ~/comGSI_v2/run/gsi.exe ($GSI_EXE) ./gsi.exe> cp your_bk_dir//2010050700/arw_wrfinput_d01_2010-05-07_00:00:00 ($BK_FILE)

./wrf_inout

> ln -s your_dat_dir/2010050700/obs/le_nam.t00z.prepbufr.tm00.nr ($PREPBUFR)

./prepbufr

>cp ~/comGSI_v2/fix/nam_glb_berror.f77 ($BERROR) ./berror_stats

>cp ~/comGSI_v2/fix/global_convinfo.txt ($CONVINFO) ./convinfo

>cp ~/comGSI_v2/fix/nam_errtable.r3dv ($OBERROR) ./errtable

> Set up your own GSI namelist and name it as ./gsiparm.anlThe background file will be replaced after running GSI

therefore please make sure it is copied to the working directory (instead of using link command).

Page 21: GSI Setup, Run and  Namelist

Observation File Names Used in GSI(GSI Users’ Manual-Chapter 3)

Page 22: GSI Setup, Run and  Namelist

“Fixed” File Names Used in GSI(GSI Users’ Manual-Chapter 3)

Page 23: GSI Setup, Run and  Namelist

Running GSI> gsi.exe >&! stdout (or your own log file name)

If running in distributed-memory mode, you need to set up the computer resources (e.g., processor numbers, memory, wallclock…) based on the platform you are using.

GSI finished but not necessarily succeed!

Page 24: GSI Setup, Run and  Namelist

Working Directory - Output

In your_choice_of_working_dir, you may have the following files after running GSI successfully:

Please refer to the talk “GSI diagnostics” for more information.

stdout Standard text output file, which is the most often used file to check GSI analysis processes as well as basic and important information about the analyses. We will explain the content of stdout in Section 4.1 and users are encouraged to read this file in detail to get an idea about GSI process order.

Fort.201(202,203,…)

statistic results of observation innovations according to observation variables.

Diag_conv(amsu_n15,…)_ges_*

(Depends on the etup of the namelist option write_diag): diagnostic files for conventional observations at initial analysis step (background)

Diag_conv(amsu_n15,…)_anl_*

(Depends on the etup of the namelist option write_diag): diagnostic files for conventional observations at final analysis step

Conv(sat…)info Information about data usageWrf_inout Analysis xa (only if using WRF background).

Page 25: GSI Setup, Run and  Namelist

Working Directory - Output

Some intermediate files:

Page 26: GSI Setup, Run and  Namelist

26

Ask for computer resources to run GSISet environment variables for the machine

Set experiments variables (experiment name, analysis time, background and observation)

Check the definition of required variables

Generate a run directory for GSI (working or temp directory)

Copy GSI executable to run directoryCopy background file to run directoryCopy or link observations to run directoryCopy fixed files to run directoryGenerate namelist for GSI

Run the GSI executable

Save the GSI analysis results

Run_gsi.ksh: Structure

Page 27: GSI Setup, Run and  Namelist

27

# Machine dependent configuration GSIPROC=1 ARCH=‘LINUX_PGI’# analysis time (YYYYMMDDHH) ANAL_TIME=2010050700# working direcotry, where GSI runs WORK_ROOT=/data1/class05/GSI/gps_arw_${ANAL_TIME}# path and name of background file BK_FILE=/wrfhelp/GSI/Datafiles/2010050700/arw_wrfinput_d01_2010-05-07_00:00:00# path of observations OBS_ROOT=/wrfhelp/GSI/Datafiles/2010050700/obs PREPBUFR=/wrfhelp/GSI/Datafiles/2010050700/obs/le_nam.t00z.prepbufr.tm00.nr# path of fix files FIX_ROOT=/data1/class05/GSI/comGSI_v2/fix# path and name of the gsi executable GSI_EXE=/data1/class05/GSI/comGSI_v2/run/gsi.exe#which WRF core is used as background (NMM or ARW) bk_core=ARW# which background error covariance and parameter will be used (GLOBAL or NAM) bkcv_option=NAM

Run_gsi.ksh: Setup(Example from Practical Sessions)

Page 28: GSI Setup, Run and  Namelist

Running Options-Namelist

Run_gsi.ksh has the namelist inside the script.

Page 29: GSI Setup, Run and  Namelist

What is a Namelist?

• The Fortran namelist (namelist.input) file helps the user to configure a GSI run without recompiling the code.– Specific Fortran 90 namelist format

• Description of WRF-Var namelist variables are given in GSI User’s Guide and gsimod.F90.

&namelistname - start/ - end

Page 30: GSI Setup, Run and  Namelist

GSI Namelist&SETUP miter=2,niter(1)=5,niter(2)=5, write_diag(1)=.true.,write_diag(2)=.false.,write_diag(3)=.true., qoption=1,

gencode=78,factqmin=0.005,factqmax=0.005,deltim=$DELTIM, ndat=59,npred=5,iguess=-1,

oneobtest=.false.,retrieval=.false.,l_foto=.false., use_pbl=.false., $SETUP / &GRIDOPTS JCAP=$JCAP,NLAT=$NLAT,NLON=$LONA,nsig=$LEVS,hybrid=.true., wrf_nmm_regional=.false.,wrf_mass_regional=.true.,

diagnostic_reg=.false., filled_grid=.false.,half_grid=.true.,netcdf=.true., regional=.true.,nlayers(63)=3,nlayers(64)=6, $GRIDOPTS

Page 31: GSI Setup, Run and  Namelist

GSI NamelistSETUP: General control variables.GRIDOPTS: Grid setup variab;e, including global regional

specific namelist variables.BKGERR:Background error related variables.ANBKGERRAnisotropic background error related variables.JCOPTS: Constraint term in cost function (Jc)STRONGOPTS: Strong dynamic constraint.OBSQC: Observation quality control variables.OBS_INPUT: Input data control variables.SPEROB_RADAR: Level 2 BUFR file of radar wind superobs.LAG_DATA: Lagrangian data assimilation related

variables.SINGLEOB_TEST: Pseudo single observation test setup.

Page 32: GSI Setup, Run and  Namelist

GSI Namelist-SETUPNhr_assimilation: Assimilation time interval

(currently 6 hours for global, 3 hours for regional )

Page 33: GSI Setup, Run and  Namelist

GSI Namelist-SETUP(cont.)miter=2: number of outer loops of analysis.niter(1)=50: maximum iteration number of

1st inner loop iterations. Inner loop will stop either reach this maximum number or reach convergence condition or broken.

niter(2)=50: maximum iteration number of 2nd inner loop iterations

Niter_no_qc: Inner loop iteration at which to turn on variational quality control

Page 34: GSI Setup, Run and  Namelist

GSI Namelist-SETUP(cont.)qoption = 1 or 2: option of moisture analysis

variable; 1:q/qsatg 2:normalized RHWhen qoption=1, the moisture analysis variable is

pseudo-relative humidity. The saturation specific humidity, qsatg, is computed from the guess and held constant during the inner loop. Thus, the RH control variable can only change via changes in specific humidity, q.

When qoption=2, the moisture analysis variable is normalized RH. In this formulation we allow RH to change in the inner loop via changes to surface pressure (pressure), temperature, or specific humidity.

Page 35: GSI Setup, Run and  Namelist

GSI Namelist-SETUP(cont.)Diag_rad, diag_pcp, …:

logical to turn off or on the diagnostic radiance file (true=on)

Write_diag: Logical to write out diagnostic files for outer

iteration

Page 36: GSI Setup, Run and  Namelist

GSI Namelist-GRIDOPTSregional: if true, perform a regional GSI run using

either ARW or NMM inputs as background. If false, perform a global GSI analysis.

wrf_nmm_regional: if true, background comes from WRF NMM. When use WRF ARW or perform a global analysis, set it to false.

wrf_mass_regional: if true, background comes from WRF ARW. When use WRF NMM or perform a global analysis, set it to false.

netcdf: if true, wrf files are in NETCDF format, otherwise wrf files are in binary format. This option only works for performing a regional GSI analysis.

Page 37: GSI Setup, Run and  Namelist

GSI Namelist-GRIDOPTS(cont.)

Nlon_regional: Number of x grid point in whole regional domain

Nlat_reginoal: Number of y grid point in whole regional domain

Nsig: number of sigma levels

Page 38: GSI Setup, Run and  Namelist

GSI Namelist-BKGERR

Refer to the talk “Background Errors Estimation and Tuning”

Page 39: GSI Setup, Run and  Namelist

GSI Namelist-ANBKGERR

Currently used in the RTMA operational run (for surface data analysis) and some hurricane studies. Research topic?

Page 40: GSI Setup, Run and  Namelist

GSI Namelist-SETUPndat=43: number of observation variables

(not observation types). This number should be consistent with the lines in OBS_INPUT. So if adding a new observation variable, ndat must be incremented by one and one new line is added in OBS_INPUT. Based on dimensions of the variables in OBS_INPUT (e.g., dfile), the maximum value of ndat is 100.

Page 41: GSI Setup, Run and  Namelist

GSI Namelist-OBS_INPUTdfile(01)='prepbufr': observation file name. The

observation file contains observations used for a GSI analysis. This file can include several observation variables from different observation types. The file name is default in GSI and cannot be changed.

dtype(01)='ps': analysis variable name that GSI can read in and handle. As an example here, GSI will read all ps observations from the file prepbufr. Please note this name should be consistent with that used in the GSI code. Otherwise, GSI will give a warning message like: ‘this is unknown observation variables and it will not be

used in GSI analysis’