Modifying EPA EMF SMOKE Platform for LADCO
Contents
Modifications needed for modeling
Scripting Modifications
Here is the script to convert EPA's Scripts in LADCO's Scripts.
foreach sname (Annual_afdust_NAMENAME.csh Annual_afdust_adj_NAMENAME.csh Annual_cmv_c1c2_12US1_2016ff_16j.csh Annual_np_oilgas_NAMENAME.csh Annual_othafdust_NAMENAME.csh Annual_othafdust_adj_NAMENAME.csh Annual_rail_NAMENAME.csh Annual_rwc_NAMENAME.csh Monthly_ag_NAMENAME.csh Monthly_nonroad_NAMENAME.csh Monthly_onroad_can_NAMENAME.csh Monthly_onroad_mex_NAMENAME.csh Monthly_onroad_mex_NAMENAME_part2_combine.csh Monthly_othar_NAMENAME.csh) echo "Working on :" $sname setenv INNAME `echo $sname | sed s/NAMENAME/12US1_2016fh_16j/g` setenv OUTNAME `echo $sname | sed s/NAMENAME/ladco_2016_v1/g` #ls $INNAME #echo $OUTNAME cat $INNAME | sed s/griddesc_lambertonly_18jan2019_v7.txt/griddesc_lambertonly_aug302019_v8_LADCO.txt/g | sed s/2016fh_16j/2016_ladco_v1/g | sed s/directory_definitions.csh/directory_definitions.12US2.csh/g | sed s/smoke4.7/smoke4.6/g > $OUTNAME end
==
For C1C2 marine script Changed
setenv SECTORLIST "$CASESCRIPTS/sectorlist_2016ff_12dec2018_v1"
to
setenv SECTORLIST "$CASESCRIPTS/sectorlist_2016fh_02aug2019_v0
Files that needed to be added
ge_dat/gridding/agref_us_2014platform_03dec2018_nf_v11.txt ge_dat/temporal/amptref_general_2014platform_tref_07dec2018_nf_v15 ge_dat/costcy_for_2007platform_28nov2018_nf_v23.txt 2016fh_16j/inputs/cmv_c1c2/* ge_dat/costcy_for_2007platform_28nov2018_nf_v23.txt ge_dat/gridding/srgdesc_CONUS12_2014_v1_3_29nov2016_13oct2017_v1.txt ge_dat/smkreport/sccdesc_2014platform_07dec2018_nf_v2.txt ge_dat/speciation/gscnv_Create_Speciate4_5_CB6CMAQ_04jan2018_nf_v1.txt ge_dat/gridding/surrogates/CONUS12_2014_03dec2018/USA_100_NOFILL.txt ge_dat/smkreport/repconfig_area_inv_2011platform_11aug2014_v0.txt ge_dat/smkreport/repconfig_area_invgrid_2011platform_11aug2014_v0.txt ge_dat/smkreport/repconfig_area_inv2_2011platform_11aug2014_v0.txt ge_dat/gridding/artopnt_2002detroit_30mar2012_v1.txt ge_dat/gridding/griddesc_lambertonly_29nov2018_nf_v7.txt ge_dat/invtable_2014platform_integrate_27nov2018_nf_v3.txt
Mexico_2016_onroad_MOVES_interpolated_02mar2018_v0.csv
Everything in
ge_dat/gridding/surrogates/CONUS12_2014_03dec2018/*
Area Sources
Smoke Compile and source code notes
When I compare the source code from EPA with the Code downloaded from Github I get the following differences.
Files assigns/ASSIGNS.EDGAR.cmaq.cb05_soa.HEMI_108k and ../assigns/ASSIGNS.EDGAR.cmaq.cb05_soa.HEMI_108k differ Only in ../assigns: ASSIGNS.emf Files assigns/ASSIGNS.nctox.cmaq.cb05_soa.us12-nc and ../assigns/ASSIGNS.nctox.cmaq.cb05_soa.us12-nc differ Only in ../assigns: check_settings.csh Only in ../assigns: runsettings.csh Only in ../assigns: set_dirs.csh Files assigns/smk_mkdir and ../assigns/smk_mkdir differ Only in ../assigns: smk_mkdir_unc Only in ../assigns: smk_rmfiles_v3.scr
In scripts the differences are:
Only in scripts: aermod Only in ../scripts: afdust_adj Only in ../scripts: annual_report Only in ../scripts: emf Only in ../scripts: emisqa Only in scripts: install Only in ../scripts: log_analyzer Only in ../scripts: platform Common subdirectories: scripts/run and ../scripts/run Only in ../scripts: smk_dates
So it would appear that simply pulling SMOKE from CMAS is not enough you must include EPA's versions of those folders.
I also created a short script called testenv.csh which looks at environment variables that have file names on our primary drive "t5" and looks for their existence and lists all the files that don't exist into missing.txt. Handling of directory references is not working great but it is pretty easy to see any glaring problem areas.
Here is my script
#!/bin/csh -f echo "" > missing.txt for file in `printenv | cut -d'=' -f2 | grep t5 | grep -v ":" ` do [ ! -d $file ] && [ ! -f $file ] && echo "File $file DOES NOT exists." >> missing.txt done