Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

Urban canopy parameters ingestion into WPS/ WRF

madhavijain

New member
I am trying to ingest city specific urban canopy parameters that I developed using buildings heights and footprints data. The UCPs I built were: 1) Mean Building Height, 2) Distribution of building heights for 5m bins, 3) Area weighted mean building height, 4) Standard deviation of building height, 5) Plan area fraction, and 6) Building surface to plan area ratio. All of the geotiff files were successfully converted to WPS binaries.
QUESTIONS-
1) For Distribution of building heights for 5m bins UCP, I have separate files for bins: 0-5m, 5-10m, 10-15m, 15-20m, 20-25m, 25-30m, 30-35m, 35-40m, 40-45m, 45-50m, >50m. Is this correct or should I have more bins till the maximum height of the building in the city (e.g. 540m for NYC)? Is there a standardized number of bins that WRF expects, and maybe in that case >50m bin would be wrong?

2) I am wondering what all needs to be added in the GEOGRID.TBL? Should I add sections like this for each of the UCP separately? How does this work out for the Distribution of building heights for 5m bins UCP?
===============================
name=FRC_URB2D
priority=1
optional=yes
dest_type=continuous
fill_missing = 0.
interp_option=default: average_gcell(2.0)+four_pt
rel_path=default:urbfrac_XXX/
flag_in_output=FLAG_FRC_URB2D
===============================
3) Do we just rerun geogrid.exe after editing the GEOGRID.TBL or do we need to make additional changes in the WRF/Registry/Registry.EM_COMMON file?
 
The urban parameters are read in the GEOGRID.TBL through

name=URB_PARAM
priority=1
optional=yes
dest_type=continuous
fill_missing = 0.
z_dim_name=num_urb_params
interp_option=default:nearest_neighbor
rel_path=default:NUDAPT44_1km/
flag_in_output=FLAG_URB_PARAM

and in the geo_em NetCDF files, the variable are

float URB_PARAM(Time, num_urb_params, south_north, west_east) ;
URB_PARAM:FieldType = 104 ;
URB_PARAM:MemoryOrder = "XYZ" ;
URB_PARAM:units = "dimensionless" ;
URB_PARAM:description = "Urban_Parameters" ;
URB_PARAM:stagger = "M" ;
URB_PARAM:sr_x = 1 ;
URB_PARAM:sr_y = 1 ;


So you can try changing these binary files in the NUDAPT44_1km directory or change the rel_path to the one you have in the GEOGRID.TBL file.

Another method is using the w2w tool or other methods (write the own codes) to replace these parameters in the geo_em NetCDF files

The following doc provides more details about these parameters.

To check if these parameters has been changed correctly, you can look at these following variables from the wrfinput files after running real.exe. The below are examples for using BEP urban model.
These variables are already output in the wrfinput files, so there should no be required to change the Registry.EM_COMMON file.

float BUILD_AREA_FRACTION(Time, south_north, west_east) ;
BUILD_AREA_FRACTION:FieldType = 104 ;
BUILD_AREA_FRACTION:MemoryOrder = "XY " ;
BUILD_AREA_FRACTION:description = "BUILDING PLAN AREA DENSITY" ;
BUILD_AREA_FRACTION:units = "dimensionless" ;
BUILD_AREA_FRACTION:stagger = "" ;
BUILD_AREA_FRACTION:coordinates = "XLONG XLAT XTIME" ;
float HEIGHT_HISTOGRAMS(Time, urban_vertical_layers_stag, south_north, west_east) ;
HEIGHT_HISTOGRAMS:FieldType = 104 ;
HEIGHT_HISTOGRAMS:MemoryOrder = "XYZ" ;
HEIGHT_HISTOGRAMS:description = "DISTRIBUTION OF BUILDING HEIGHTS" ;
HEIGHT_HISTOGRAMS:units = "dimensionless" ;
HEIGHT_HISTOGRAMS:stagger = "Z" ;
HEIGHT_HISTOGRAMS:coordinates = "XLONG XLAT XTIME" ;
float BUILD_SURF_RATIO(Time, south_north, west_east) ;
BUILD_SURF_RATIO:FieldType = 104 ;
BUILD_SURF_RATIO:MemoryOrder = "XY " ;
BUILD_SURF_RATIO:description = "BUILDING SURFACE AREA TO PLAN AREA RATIO" ;
BUILD_SURF_RATIO:units = "dimensionless" ;
BUILD_SURF_RATIO:stagger = "" ;
BUILD_SURF_RATIO:coordinates = "XLONG XLAT XTIME" ;
float BUILD_HEIGHT(Time, south_north, west_east) ;
BUILD_HEIGHT:FieldType = 104 ;
BUILD_HEIGHT:MemoryOrder = "XY " ;
BUILD_HEIGHT:description = "AVERAGE BUILDING HEIGHT WEIGHTED BY BUILDING PLAN AREA" ;
BUILD_HEIGHT:units = "m" ;
BUILD_HEIGHT:stagger = "" ;
BUILD_HEIGHT:coordinates = "XLONG XLAT XTIME" ;


The aboe urban_vertical_layers_stag for variable HEIGHT_HISTOGRAMS is 15, so it should be fine to have maximum of 15 bins for the distribution of building heights.

If need more distributions, it may required to change this hard-code value in the
and the model will stop running, so you will know that.

Currently the maximum number of vertical levels in the urban grid is set as 18 in this line, and it would require to meet this criteria, 15+3, in the following code
WRF/phys/module_sf_bep.F at 0a11865f97680fdd6865b278ea29d910e5db3ed7 · wrf-model/WRF, otherwise model would stop to run.
 
Last edited:
Top