Git Product home page Git Product logo

mpassit's Introduction

This program interpolates fields from an MPAS mesh (the "source" mesh) to a regular WRF grid (the "target" grid). Integer fields use nearest neighbor interpolation, snow-related fields use conservative regridding, and all other fields use bilinear interpolation.

The main point of this program was to be able to interpolate fields from an MPAS mesh to a regular grid for data visualization and post-processing purposes.

Additional information to what's below can be found in the included MPASSIT_presentation.pdf.

Compiling instructions:

0)[Only necessary on non-RDHPCS machines] Create an appropriate module file in the modulefiles subdirectory named build.[target].[compiler].lua (if your machine supports lua modulefiles) or build.[target]. In this file you will need to load your desired compiling environment, including cmake and MPI. Environmental variables NETCDF and ESMFMKFILE are also necessary and should be pointed to the top directory of the NETCDF install and the file esmf.mk of your ESMF install, respectively.

An example file that loads the build environment through modulefiles and the extra libraries via LD_LIBRARY_PATH modification is provided in modulfiles/build.jet.test.intel.lua.

  1. run build.sh [target] [compiler]

Run instructions:

  1. Copy all variable list files from ./parm in to run directory. Each file is formatted like:

rainc RAINC rainnc RAINNC refl10cm_max REFL10CM_MAX [...]

with the variable name in the MPAS file in the first column, and the desired output name in the second file. Variables are separated in to four categories:

a) Variables from the diag file (diaglist)

b) 2-dimensional variables from the history file (histlist_2d)

c) 3-dimensional variables from the history file (histlist_3d)

d) 3-dimensional soil variables from the history file (histlist_soil)

The user can edit these to their specifications, if they so wish.

  1. Create a namelist file of any name in run directory (e.g., namelist.input)

Input/namelist:

&config grid_file_input_grid="/scratch/wof/mpas/init.nc" hist_file_input_grid="/scratch/wof/mpas/init.nc" diag_file_input_grid="/scratch/wof/mpas/diag.2019-05-18_00.00.00.nc" file_target_grid="/scratch/wicker/27April2011/ICs/wrfinput_d01" output_file="/scratch/larissa.reames/out_hist_diag.nc" block_decomp_file="/scratch/wof/mpas/wofs_mpas.graph.info.part.120" target_grid_type = 'lambert' interp_diag=.true. interp_hist=.true. esmf_log=.false. nx = 1801 ny = 1061 dx = 3000.0 dy = 3000.0 ref_lat = 38.50 ref_lon = -97.50 truelat1 = 38.5 truelat2 = 38.5 stand_lon = -97.5 /

grid_file_input_grid : Full path of MPAS file containing grid information

hist_file_input_grid : Full path of input history MPAS data

diag_file_input_grid : Full path of input diag MPAS data

target_grid_type : Grid type to interpolate date to. Supported options are: 'file', 'lambert', lat-lon'

file_target_grid : Full path of WRF file containing target grid information, supported types: wrfout, wrfinput, geo_em (Valid only if target_grid_type='file')

is_regional: Whether the target grid is regional or not (default:.true.)

output_file : Full path of output file

block_decomp_file : Full path to the MPAS grid-specific block decomposition file

interp_diag : Whether to interpolate fields from the diag file (T/F)

interp_hist : Whether to interpolate fields from the hist file (T/F)

wrf_mod_vars : Whether to modify output variables to conform to WRF shapes (i.e. staggered winds) (default:.false.)

esmf_log : Whether to output ESMF files (PET) if an ESMF error is encounters (default:.false.)

The following options are only valid for target_grid_type NOT 'file':

nx : The number of target grid points in the east-west direction

ny : The number of target grid pointers in the north-south direction

dx : Grid size (meters, or deg for target_grid_type='lat-lon') in the east-west direction

dy : Grid size (meters, or deg for target_grid_type='lat-lon') in the north-south direction

ref_lat : Reference latitude of the target grid projection

ref_lon : Reference longitude of the target grid projection

truelat1 : First true latitude of target grid projection (for target_grid_type='lambert')

truelat2 : Second true latitude of target grid projection (for target_grid_type='lambert'; optional)

stand_lon : Standard longitude of the target grid projection (for target_grid_type='lambert')

  1. Submit to job queue (most grids won't need more then 3 nodes/72 processes)

srun bin/mpassit namelist.input [or whatever your chosen namelist is named]

mpassit's People

Contributors

larissareames-noaa avatar ywangwof avatar weather4evr avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.