USEPA / CMAQ

Code for U.S. EPA’s Community Multiscale Air Quality Model (CMAQ) which helps in conducting air quality model simulations
https://epa.gov/CMAQ
MIT License
276 stars 197 forks source link

MCIP error when processing WRF V4.0.3 output #123

Closed rpedruzzi closed 5 years ago

rpedruzzi commented 5 years ago

Dear all,

I am trying to run MCIP v4.5 with WRF V4.0.3 output but I am getting this error:

Mon Apr 15 13:57:50 EDT 2019
rm: No match.

     This program uses the EPA-AREAL/MCNC-EnvPgms/BAMS Models-3
     I/O Applications Programming Interface, [I/O API] which is
     built on top of the netCDF I/O library (Copyright 1993, 1996
     University Corporation for Atmospheric Research/Unidata
     Program) and the PVM parallel-programming library (from
     Oak Ridge National Laboratory).
     Copyright (C) 1992-2002 MCNC,
     (C) 1992-2013 Carlie J. Coats, Jr.,
     (C) 2003-2012 Baron Advanced Meteorological Systems, LLC, and
     (C) 2014-2016 UNC Institute for the Environment.
     Released under the GNU LGPL  License, version 2.1.  See URL

         https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html

     for conditions of use.

     ioapi-3.2: $Id: init3.F90 98 2018-04-05 14:35:07Z coats $
     Version with PARMS3.EXT/PARAMETER::MXVARS3= 2048
     netCDF version 4.1.3 of Jun 19 2018 15:50:22 $

     EXECUTION_ID: mcip

 ==============================================================================

                  US EPA COMMUNITY MULTISCALE AIR QUALITY MODEL
                    METEOROLOGY-CHEMISTRY INTERFACE PROCESSOR

                           MCIP V4.5 FROZEN 03/16/2018

 ==============================================================================

 **********************************************************************
 *** SUBROUTINE: SETUP
 ***   UNKNOWN OR UNSUPPORTED WRF OUTPUT VERSION
 ***   VERSION =  OUTPUT FROM WRF V4.0.3 MODEL
 **********************************************************************

     *** ERROR ABORT in subroutine SETUP
     ABNORMAL TERMINATION IN SETUP
     Date and time  0:00:00   July 22, 2015   (2015203:000000)

Error running mcip

My WRF V4.0.3 is with terrain following sigma levels and not with hybrid vertical levels.

Is there a way to fix or I just need to add the "V4" label in the "ifs" that are checking the model version in /src/setup.f90 and /src/setup_wrfem.f90 ?

I changed the MCIP code at /src/setup.f90 and /src/setup_wrfem.f90 to also accept the V4 version:

in /src/setup.f90 at line 131 from: IF (wrfversion(18:19) == "V3" ) THEN to:
IF ( (wrfversion(18:19) == "V3") .OR. (wrfversion(18:19) == "V4") ) THEN

in /src/setup_wrfem.f90 at line 918 from: IF ( (wrfversion(18:21) == "V2.2") .OR. (wrfversion(18:19) >= "V3") ) THEN

to:

IF ( (wrfversion(18:21) == "V2.2") .OR. (wrfversion(18:19) >= "V3") &
                                     .OR. (wrfversion(18:19) >= "V4")) THEN

If I do this changes, MCIP will keep the consistency or I'll have problems with it?

Thank you so much for your help

rpedruzzi commented 5 years ago

The explanation is on this link on CMAS Forum

https://forum.cmascenter.org/t/mcip-error-when-processing-wrf-v4-0-3-output/615