SMOKE BEIS Custom BELD5 with our domain

“Custom BELD5 input file over your modeling domain can be developed using new updated Aggwndw utility program in SMOKE that can optionally aggregate non-mass values with the setting of AGGREGATE_EMIS_YN = N”

May I ask if there are details on customizing BELD5 for biogenic emission?

I couldn’t find AGGREGATE_EMIS_YN = N in assign file. This option should add by ourself, right? If I have our domain, anything else I should do after define AGGREGATE_EMIS_YN and IOAPI_GRIDNAME_1?

Is there BELD5 reference?

Thanks in advance,
Xiao

@jbash. Can you provide any references or details on BELD5?

Regarding to AGGREGATE_EMIS_YN, you do not set this in your assign file but in your run script. You should create a simple c-shell script that can invoke aggwndn and set this flag AGGREGATE_EMIS_YN to N when you process BELD5 file.

Thank you so much for your help. I will give a try and may come back for more questions.

Happy Holidays and Best Regards,
Xiao

Dr. Baek,

Is ‘aggwndw’ only aggregating/extracting a window of emissions data from an input finer to an output coarse grid? Is possible from an input coarse to output finer grid? Under smoke v4.8, only have US12NC (e.g., BELD5.US12NC_66X52.ncf). How about larger domain file (e.g., North America 12km)? Sorry, I am new to this knowledge. What D3 mean in ‘12.D3’? Is mean 1000m? I am not able to find reference.

GRISDDESC-
! coords --line: name; type, P-alpha, P-beta, P-gamma, xcent, ycent
‘LAM_40N97W’
2, 33.000, 45.000, -97.000, -97.000, 40.000
’ ’ ! end coords. grids: name; xorig,yorig,xcell,ycell,ncols,nrows,nthik
‘US12NC_66X52’
‘LAM_40N97W’, 1128D3, -672D3, 12.D3, 12.D3, 66, 52, 1
‘NA_12KM’
‘LAM_40N97W’, -2952000, -2772000, 12000, 12000, 516, 444, 1

Many thanks,
Xiao

For going from a coarse grid to a finer one, you need to interpolate; however, doing so will cause you to lose resolution in your input data: you won’t “see” geographic features smaller than twice the resolution of the coarser grid. Be aware, however, that emissions data does not use MKS units but instead has an additional implicit “per grid cell” for its units. You could use a combination of M3Tools programs m3cple for the interpolation and m3combo (with a trivial one-variable combination) for the re-scaling.

The D in the numbers for the GRIDDESC file indicates that the value is double precision and separates the mantissa from the exponent (so that D3 indicates that the fraction should be multiplied by 10^3=1000 and so can easily be read in kilometers instead of standard MKS meters). Normal “good practice” also has a decimal point in the fraction also.

Please be aware that this is a very sloppy GRIDDESC, where many of the parts that in fact should be double precision are not represented that way, and furthermore does not have the required “end-of-grids” marker. Far better would have been:

! coords --line: name; type, P-alpha, P-beta, P-gamma, xcent, ycent
‘LAM_40N97W’
2, 33.0D0, 45.0D0, -97.0D0, -97.0D0, 40.0D0
’ ’ ! end coords. grids: name; xorig,yorig,xcell,ycell,ncols,nrows,nthik
‘US12NC_66X52’
‘LAM_40N97W’, 1128.0D3, -672.0D3, 12.0D3, 12.D3, 66, 52, 1
‘NA_12KM’
‘LAM_40N97W’, -2952.0D3, -2772.0D3, 12.0D3, 12.0D3, 516, 444, 1
' '    !  end grids

For BELD5, you don’t want to interpolate. We have the input data available on a 1km domain.

Is your domain aligned with / on the same map projection as our standard grid? I think it is based on your griddesc.

Some tools were provided with SMOKE 4.8 to aggregate the BELD data to an aligned grid – check out the SMOKE release.

You should review the tools and send questions if you have them.

@xiaoyu. As stated in the SMOKE release note, “Latest BEISFAC and North America region BELD5 (1km x 1km) input files for BEIS v3.7 can be found from the CMAS Data Warehouse.”
Check out the CMAS Data Warehouse to download the. NA BELD5 input file for you to develop your own domain within North American region.

Thank you, Ms. Eyth. I will review tools and send questions if any comes.

Best Regards,
Xiao

Dr. Baek, thank you for the detail response regarding my questions. I will use the 1km BELD5.

Best Regards,
Xiao

Hello, Ms. Eyth @eyth.alison and Dr. Baek @bbaek

Based on your recommendation, I test ‘aggwndw’ tool on our end. It works when input file format is .ncf but not '.ncf4’ which is from smoke v4.8 updated BELD5 (1km x 1km)(https://drive.google.com/drive/u/0/folders/1v3i0iH3lqW36oyN9aytfkczkX5hl-zF0). Is aggwndw compatible with ncf4?

The log file, GRIDDESC, and run script are attached. Please let me know if you would like to have other complemented files.
error.txt (2.7 KB)
run_aggwndw.csh (848 Bytes)
GRIDDESC.txt (343 Bytes)

Thanks in advance.
Xiao

1 Like

This is an HDF5-netCDF file, not the expected netCDF-classic.

You’ll need to do a nertCDF-4 based build of the aggwndw program: First, build version-4.something netcdf-C with HDF5 enabled (which will probably need you to install a number of extra libraries, including those for HDF5) and do the command nc-config --libs to find out what extra libraries you’ll have to add to all the Makefiles that follow; build netCDF-Fortran; add -DIOAPI_NCF4=1 to the DEFINEFLAGS in the I/O API Makefile and then recompile the I/O API (make clean; make); add the extra libraries found above to the Makefile for aggwndw and re-build it. Then you should be able to run successfully.

1 Like

Dr. Coats @cjcoats
Thanks for your detailed guidance.

Xiao

Please check the data warehouse again. We have uploaded the regular IOAPI/NetCDF formatted BELD5 1km input file for your aggwndw program. We also included the run script as well. Good luck!

1 Like

Dr. Baek,

Sorry about my late response. Thank you for helping us on processing BELD5 and providing all needed information and files.

Best Regards,
Xiao

hi - I followed these scripts and successfully created a 4km BELD5 file for our domain. We also have a nested 1.3333km domain for our modeling demonstration. aggwndw throws this error when I try to make a 1.3km BELD5 file:

Checking input and output grids...
     ERROR: Output grid cell size is not an integer multiple of input grid cell size

     *** ERROR ABORT in subroutine AGGWNDW
     Input and output grids are not compatible

Do you have a tip for this type of grid? Or perhaps could EPA post the BELD5 tiles on the ftp and I can create my own gridded domain from there?

To know for sure, we’d need to see the grid-descriptions for the input and output grids.

However. aggwndw is used to create coarse-grid outputs from fine-grid inputs, and it looks as though you’re trying to do the reverse.

We have posted the original BELD5 data and some scripts here:

https://gaftp.epa.gov/Air/emismod/2017/biogenics/

Have you tried making the 1.33km file from that?

Yes, that is what I tried. Here is my script adapted from the sample script posted there;

source ../directory_definitions_4UDAQ_2017by_17.csh

#  BELD5 1km file
setenv INFILE ${GE_DAT}/beis/BELD5_1US3_FIA6.1_2017CLD_Canada.ncf

# See SMOKE Users Guide for info on GRIDDESC file
setenv GRIDDESC ${GE_DAT}/gridding/GRIDDESC_udaq_v7.txt

#  Must be set to N when aggregating land use percentages (BELD)
setenv AGGREGATE_EMIS_YN N

# Output grid name is IOAPI_GRIDNAME_1
# The definition of this output grid must be in the GRIDDESC file
setenv IOAPI_GRIDNAME_1 WF13UDAQ

setenv OUTFILE ${GE_DAT}/beis/beld5.aggwndw_v48.WF13UDAQ.ncf

setenv PROMPTFLAG N

# SMK_BIN is path to the aggwndw executable
$INSTALL_DIR/smoke4.8.1/Linux2_x86_64ifort/aggwndw

exit

I understand that the BELD5_1US3_FIA6.1_2017CLD_Canada.ncf is 1km resolution. My domain is 1.3km resolution, which is coarser than 1km, so the aggwndw tool should apply - correct?
Here is my GRIDDESC:

!  coords --2 lines:  name; type, P-alpha, P-beta, P-gamma, xcent, ycent
'LAM_40N97W'
2, 33.0D0, 45.D0, -97.D0, -97.D0, 40.D0
' '                                                               ! end coords
'WF13UDAQ' !  2 lines: WF13UDAQ; xorig,yorig,xcell,ycell,ncols,nrows,nthik
'LAM_40N97W', -1332000.000, 80000.000, 1333.333333, 1333.333333, 108, 207, 1
' '                                                !  end grids.

I was able to window the BELD4.1 for this WF13UDAQ domain using the convert_beld41_feb2017_epa_12US1.csh script and these tiles: https://gaftp.epa.gov/Air/emismod/2011/v3platform/beld4.1/
I could try that approach again if the individual BELD5 tiles are posted somewhere?

Unfortunately, aggwndw can not aggregate 1kmx1km to 1.33kmx1.33km grid cell although it is coarser than 1km. It does not interpolate the cells but simple summing.

Ok that makes sense. Can the individual BELD5 tiles be made available?