[Dart-dev] DART/branches Revision: 12020

dart at ucar.edu dart at ucar.edu
Thu Oct 26 11:56:14 MDT 2017


thoar at ucar.edu
2017-10-26 11:56:13 -0600 (Thu, 26 Oct 2017)
102
fixed issues when the compiler tries to check the declared array lengths
vs the portions being used.




Modified: DART/branches/mizzi/obs_def/obs_def_IASI_CO_mod.f90
===================================================================
--- DART/branches/mizzi/obs_def/obs_def_IASI_CO_mod.f90	2017-10-26 17:20:18 UTC (rev 12019)
+++ DART/branches/mizzi/obs_def/obs_def_IASI_CO_mod.f90	2017-10-26 17:56:13 UTC (rev 12020)
@@ -166,8 +166,8 @@
    iasi_nlevelsp_1 = iasi_nlevels_1+1
    iasi_prior_1 = read_iasi_prior(ifile, fileformat)
    iasi_psurf_1 = read_iasi_psurf(ifile, fileformat)
-   avg_kernels_1(1:iasi_nlevels_1) = read_iasi_avg_kernels(ifile, iasi_nlevels_1, fileformat)
-   pressure_1(1:iasi_nlevelsp_1) = read_iasi_pressure(ifile, iasi_nlevelsp_1, fileformat)
+   avg_kernels_1(:) = read_iasi_avg_kernels(ifile, iasi_nlevels_1, fileformat)
+   pressure_1(:) = read_iasi_pressure(ifile, iasi_nlevelsp_1, fileformat)
    read(ifile) keyin
    CASE DEFAULT
    iasi_nlevels_1 = read_iasi_nlevels(ifile, fileformat)
@@ -177,8 +177,8 @@
    iasi_nlevelsp_1 = iasi_nlevels_1+1
    iasi_prior_1 = read_iasi_prior(ifile, fileformat)
    iasi_psurf_1 = read_iasi_psurf(ifile, fileformat)
-   avg_kernels_1(1:iasi_nlevels_1) = read_iasi_avg_kernels(ifile, iasi_nlevels_1, fileformat)
-   pressure_1(1:iasi_nlevelsp_1) = read_iasi_pressure(ifile, iasi_nlevelsp_1, fileformat)
+   avg_kernels_1(:) = read_iasi_avg_kernels(ifile, iasi_nlevels_1, fileformat)
+   pressure_1(:) = read_iasi_pressure(ifile, iasi_nlevelsp_1, fileformat)
    read(ifile, *) keyin
 END SELECT
 counts1 = counts1 + 1
@@ -237,7 +237,6 @@
 !
 ! Make sure there's enough space, if not die for now (clean later)
 if(num_iasi_co_obs >= MAX_IASI_CO_OBS) then
-   ! PUT IN ERROR HANDLER CALL
    write(string1, *)'Not enough space for a iasi CO obs.'
    write(string2, *)'Can only have max_iasi_co obs (currently ',MAX_IASI_CO_OBS,')'
    call error_handler(E_ERR,'interactive_iasi_co',string1,source,revision,revdate,text2=string2)
@@ -258,7 +257,9 @@
 write(*, *) 'Input the 20 Averaging Pressure Levels '
 read(*, *) pressure(num_iasi_co_obs,:)
 end subroutine interactive_iasi_co
-!
+
+
+
 subroutine get_expected_iasi_co(state, location, key, val, istatus)
 !----------------------------------------------------------------------
 !subroutine get_expected_iasi_co(state, location, key, val, istatus)
@@ -279,6 +280,8 @@
    integer             :: nlevels,nlevelsp
 
    real(r8)            :: vert_mode_filt
+
+   character(len=*), parameter :: routine = 'get_expected_iasi_co'
 !
 ! Initialize DART
    if ( .not. module_initialized ) call initialize_module
@@ -327,7 +330,7 @@
 ! Check WRF carbon monoxide at surface
    if(istatus/=0) then
       write(string1, *)'APM NOTICE: WRF co_wrf_sfc is bad ',istatus
-      call error_handler(E_MSG,'set_obs_def_iasi_o3',string1,source,revision,revdate)
+      call error_handler(E_MSG,routine,string1,source,revision,revdate)
       obs_val=missing
       return
    endif              
@@ -357,7 +360,7 @@
 ! check for lower bound
          if (istatus.eq.0 .and. obs_val.lt.co_min) then
             write(string1, *)'APM: NOTICE resetting minimum IASI CO value ',ilev
-            call error_handler(E_MSG,'set_obs_def_iasi_co',string1,source,revision,revdate)
+            call error_handler(E_MSG,routine,string1,source,revision,revdate)
             obs_val = co_min 
          endif
       endif
@@ -365,7 +368,7 @@
 ! interpolation failed
       if (istatus /= 0) then
          write(string1, *)'APM: NOTICE reject IASI CO ob - WRF interpolation failed ',istatus,ilev
-         call error_handler(E_MSG,'set_obs_def_iasi_co',string1,source,revision,revdate)
+         call error_handler(E_MSG,routine,string1,source,revision,revdate)
          obs_val = missing 
          return
       endif
@@ -399,21 +402,23 @@
 ! Allows passing of obs_def special information 
 
 integer,                 intent(in) :: key, co_nlevels, co_nlevelsp
-real(r8), dimension(19), intent(in) :: co_avgker
-real(r8), dimension(20), intent(in) :: co_press
+real(r8), dimension(IASI_DIM),  intent(in) :: co_avgker
+real(r8), dimension(IASI_DIMP), intent(in) :: co_press
 real(r8),                intent(in) :: co_prior
 real(r8),                intent(in) :: co_psurf
 
+character(len=*), parameter :: routine = 'set_obs_def_iasi_co'
+
 if ( .not. module_initialized ) call initialize_module
 
 if(num_iasi_co_obs >= MAX_IASI_CO_OBS) then
    write(string1, *)'Not enough space for a iasi CO obs.'
    write(string2, *)'Can only have MAX_IASI_CO_OBS (currently ',MAX_IASI_CO_OBS,')'
-   call error_handler(E_ERR,'set_obs_def_iasi_co',string1,source,revision,revdate,text2=string2)
+   call error_handler(E_ERR,routine,string1,source,revision,revdate,text2=string2)


More information about the Dart-dev mailing list