NetCDF error: NetCDF: Variable not found

1,768 views
Skip to first unread message

Xin Zhang

unread,
Nov 19, 2017, 7:29:57 AM11/19/17
to wrf-chem
Hi everyone,

After running wrf.exe, I get some error like this:

d01 2016-07-27_12:00:00  NetCDF error: NetCDF: Variable not found
d01
2016-07-27_12:00:00  NetCDF error in wrf_io.F90, line        2883 Varname E_NO2
 input_wrf
.F reading 4d real E_NO2 Status =        -1021
input_wrf
.F reading 4d real E_BIGALK
 date
2010-08-14_12:00:00
 ds            
1           1           1
 de          
140           1         140
 ps            
1           1           1
 pe          
35           1          24
 ms          
-4           1          -4
 me          
42           1          31
d01
2016-07-27_12:00:00 module_io.F: in wrf_read_field
d01
2016-07-27_12:00:00  NetCDF error: NetCDF: Variable not found
d01
2016-07-27_12:00:00  NetCDF error in wrf_io.F90, line        2883 Varname E_BIGALK
 input_wrf
.F reading 4d real E_BIGALK Status =        -1021
input_wrf
.F reading 4d real E_BIGENE
 date
2010-08-14_12:00:00
 ds            
1           1           1
 de          
140           1         140
 ps            
1           1           1
 pe          
35           1          24
 ms          
-4           1          -4
 me          
42           1          31
d01
2016-07-27_12:00:00 module_io.F: in wrf_read_field
d01
2016-07-27_12:00:00  NetCDF error: NetCDF: Variable not found
d01
2016-07-27_12:00:00  NetCDF error in wrf_io.F90, line        2883 Varname E_BIGENE

Details of WRF: WRF V3.9.1 NETCDF 4.3.0

In WRF3.9.1, WRF changed default netCDF file support for large files. So, it's not caused by 'netCDF files >2gb'.

Could you help me with this problem?

Best regards,
Xin
namelist.input
rsl.error.0000

Gabriele Pfister

unread,
Nov 19, 2017, 2:50:41 PM11/19/17
to Xin Zhang, wrf-chem
Xin, 

it looks that your wrfchemi* file does not include these emission species. WRF-Chem will still run, but you do so without having the needed anthropogenic emissions. You have to create the wrfchemi* files with all the species that are defined for a specific chemical scheme. When running with any of the MOZART schemes, you find more information on: https://www2.acom.ucar.edu/wrf-chem/wrf-chem-tools-community
You can also check out the file registry.chem in the WRF Source code to see which species a certain emiss_opt requires. 

Gabriele
--
================================
Gabriele Pfister
Atmospheric Chemistry Observations & Modeling
National Center for Atmospheric Research
Email: pfi...@ucar.edu
Phone: +1 303 497 2915
Web: https://staff.ucar.edu/users/pfister

Xin Zhang

unread,
Nov 20, 2017, 8:26:09 AM11/20/17
to Gabriele Pfister, wrf-chem
Hi Gabriele,

I checked registry.chem and found this part according to rsl.error.0000:

# Additional MOZART emission variables...
state    real  e_bigalk       i+jf     emis_ant     1         Z      i5     "E_BIGALK"     "EMISSIONS BIGALK"            "mol km^-2 hr^-1"
state    real  e_bigene       i+jf     emis_ant     1         Z      i5     "E_BIGENE"     "EMISSIONS BIGENE"            "mol km^-2 hr^-1"
state    real  e_c2h4         i+jf     emis_ant     1         Z      i5     "E_C2H4"       "EMISSIONS C2H4"              "mol km^-2 hr^-1"
state    real  e_c2h6         i+jf     emis_ant     1         Z      i5      "E_C2H6"       "EMISSIONS C2H6"              "mol km^-2 hr^-1"
state    real  e_c3h6         i+jf     emis_ant     1         Z      i5      "E_C3H6"       "EMISSIONS C3H6"              "mol km^-2 hr^-1"
state    real  e_c3h8         i+jf     emis_ant     1         Z      i5      "E_C3H8"       "EMISSIONS C3H8"              "mol km^-2 hr^-1"
state    real  e_ch2o         i+jf     emis_ant     1         Z      i5     "E_CH2O"       "EMISSIONS CH2O"              "mol km^-2 hr^-1"
state    real  e_ch3cho       i+jf     emis_ant     1         Z      i5     "E_CH3CHO"     "EMISSIONS CH3CHO"            "mol km^-2 hr^-1"
state    real  e_ch3coch3     i+jf     emis_ant     1         Z      i5     "E_CH3COCH3"   "EMISSIONS CH3COCH3"          "mol km^-2 hr^-1"
state    real  e_mek          i+jf     emis_ant     1         Z      i5      "E_MEK"        "EMISSIONS MEK"               "mol km^-2 hr^-1"
state    real  e_toluene      i+jf     emis_ant     1         Z      i5     "E_TOLUENE"    "EMISSIONS TOLUENE"           "mol km^-2 hr^-1"
state    real  e_isop         i+jf     emis_ant     1         Z      i5     "E_ISOP"       "EMISSIONS ISOP"              "mol km^-2 hr^-1"
state    real  e_c10h16       i+jf     emis_ant     1         Z      i5     "E_C10H16"     "EMISSIONS C10H16"            "mol km^-2 hr^-1"

# Anthropogenic emissions
state    real  e_pm_25        i+jf     emis_ant     1         Z      i5r    "E_PM_25"             "EMISSIONS"          "ug/m3 m/s"

# GOCART
state    real  e_bc          i+jf     emis_ant     1         Z      i5     "E_BC"                "EMISSIONS BC AER"       "ug/m3 m/s"
state    real  e_oc          i+jf     emis_ant     1         Z      i5     "E_OC"                "EMISSIONS BC AER"       "ug/m3 m/s"
state    real  e_sulf        i+jf     emis_ant     1         Z      i5     "E_sulf"              "EMISSIONS SO4"          "mol km^-2 hr^-1"

# Additional CBMZ and MOSAIC emission variables...
state    real  e_no2          i+jf     emis_ant     1         Z      i5r     "E_NO2"                "EMISSIONS NO2"                 "mol km^-2 hr^-1"
state    real  e_ch3oh        i+jf     emis_ant     1         Z      i5     "E_CH3OH"              "EMISSIONS CH3OH"               "mol km^-2 hr^-1"
state    real  e_c2h5oh       i+jf     emis_ant     1         Z      i5     "E_C2H5OH"             "EMISSIONS C2H5OH"              "mol km^-2 hr^-1"

If I set io_style_emissions, emiss_opt and emiss_inpt_opt to 0, wrf.exe works fine. Is that error related to my anthropogenic emissions? But, most of the error of emissions is shown in 'Additional MOZART emission variables' as you can see in registry.chem.

By the way, I attach the head file of wrfchemi_file.

Thank you,
Xin
wrfchemi_headfile

Gabriele Pfister

unread,
Nov 20, 2017, 11:22:08 AM11/20/17
to Xin Zhang, wrf-chem
Xin, 

a few comments. You run with chem_opt=112 but the aerosol emissions in your wrfchemi* file are for MOZART with MOZAIC. These are the list of anthropogenic emission species for option 112 (as taken from registry.chem): 
package   mozcem          emiss_opt==8                   -             emis_ant:e_co,e_no,e_no2,e_bigalk,e_bigene,e_c2h4,e_c2h5oh,e_c2h6,e_c3h6,e_c3h8,e_ch2o,e_ch3cho,e_ch3coch3,e_ch3oh,e_mek,e_so2,e_toluene,e_nh3,e_isop,e_c10h16,e_pm_10,e_pm_25,e_bc,e_oc,e_sulf

It seems you have two wrfchemi* files each with 12 hours of data, which you are cycling through. As explained in the WRF-Chem User's Guide in this case you have to set io_style_emissions = 1 and you might also want to comment out any entries related to auxinput5 except  io_form_auxinput5 = 2.

I also recommend including some of the emission species in the history output file which allows you to check that they are read in.

​Gabriele​

Xin Zhang

unread,
Nov 30, 2017, 9:17:13 AM11/30/17
to Gabriele Pfister, wrf-chem
Hi Gabriele,

I have tried convert MEIC(Multi-resolution Emission Inventory for China)-CB05 to MOZART. But, some variables aren't included in the conversion's guide or MEIC. I attach the guide and conclusion to this e-mail. You can check it. Should I set these missing variables to 0?

Best regards,
Xin

MEIC.md
MOZART_MOSAIC_V3.6.readme_dec2016.pdf

Gabriele Pfister

unread,
Nov 30, 2017, 11:12:40 AM11/30/17
to Xin Zhang, wrf-chem
Hello Xin

I am sorry but we cannot help you with the mapping. Any species that is not in the wrfchemi* file is simply assumed as having zero emissions and it is up to your scientific judgement whether this is acceptable or if you have to find a way to map them to any other species. 

Gabriele

Xin Zhang

unread,
Dec 5, 2017, 9:18:51 AM12/5/17
to Gabriele Pfister, wrf-chem
Hi Gabriele,

Thank you for your help! Now, I generate wrfchemi* files successfully.

Xin
Reply all
Reply to author
Forward
0 new messages