From 7bea9594cdd0c425906056703b182fd687b43c1b Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Fri, 18 Mar 2022 09:49:38 -0600 Subject: [PATCH 01/21] Change MODEL to COMP_NAME fixing #259 --- cime_config/buildlib | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cime_config/buildlib b/cime_config/buildlib index c8670e0aa..459106d26 100755 --- a/cime_config/buildlib +++ b/cime_config/buildlib @@ -56,7 +56,7 @@ def _main_func(): complib = os.path.join(libroot,"librof.a") makefile = os.path.join(casetools, "Makefile") - cmd = "{} complib -j {} MODEL=mizuRoute COMPLIB={} -f {} {}" \ + cmd = "{} complib -j {} COMP_NAME=mizuRoute COMPLIB={} -f {} {}" \ .format(gmake, gmake_j, complib, makefile, get_standard_makefile_args(case)) rc, out, err = run_cmd(cmd) From 3b7eef6f23201ac87f9eede5e209985819c49b02 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Fri, 18 Mar 2022 09:50:29 -0600 Subject: [PATCH 02/21] Start adding list of files to rof.input_data_list file dealing with #266 --- cime_config/buildnml | 25 ++++++++++++++++++++----- 1 file changed, 20 insertions(+), 5 deletions(-) diff --git a/cime_config/buildnml b/cime_config/buildnml index 774dd1f34..5185199f4 100755 --- a/cime_config/buildnml +++ b/cime_config/buildnml @@ -52,6 +52,10 @@ def _create_control_files(case, caseroot, srcroot, confdir, inst_string, infile, logger.debug(" mizuRoute lnd grid is %s ", config['lnd_grid']) logger.debug(" mizuRoute rof grid is %s ", config['rof_grid']) #---------------------------------------------------- + # Create dictionary of files that will be read in + #---------------------------------------------------- + files = {} + #---------------------------------------------------- # Settings that depend on the resolution #---------------------------------------------------- if ( config['rof_grid'] == "HDMAmz" ): @@ -175,6 +179,8 @@ def _create_control_files(case, caseroot, srcroot, confdir, inst_string, infile, ctl.set( "varname_downSegId", varname_downSegId ) ctl.set( "varname_pfafCode", varname_pfafCode ) + files['fname_ntopold'] = os.path.join( ctl.get('ancil_dir'), ctl.get('fname_ntopOld') ) + #---------------------------------------------------- # Set the restart file depending on start type #---------------------------------------------------- @@ -189,6 +195,7 @@ def _create_control_files(case, caseroot, srcroot, confdir, inst_string, infile, filename = "%s.mizuRoute.r.%s-%s.nc" %(run_refcase, run_refdate, run_tod) ctl.set( "fname_state_in", filename ) + files['fname_state_in'] = ctl.get('fname_state_in') elif fname_state_in.strip() == '': fname_state_in = "empty" @@ -215,15 +222,23 @@ def _create_control_files(case, caseroot, srcroot, confdir, inst_string, infile, #---------------------------------------------------- control_file = os.path.join(confdir, "mizuRoute.control") nml_file = os.path.join(confdir, "mizuRoute_in") - write_nml_in_file(case, nmlgen, confdir, nml_file) + write_nml_in_file(case, nmlgen, confdir, nml_file, data_list_path) ctl.write( control_file ) + #---------------------------------------------------- + # Append list of files needed to file list file + #---------------------------------------------------- + print( data_list_path ) + fileslist = open( data_list_path, "a" ) + print( files ) + for datafile in files: + print( datafile ) + fileslist.write( datafile + " = " + files[datafile] + "\n" ) + + fileslist.close() ############################################################################### -def write_nml_in_file(case, nmlgen, confdir, nml_file): +def write_nml_in_file(case, nmlgen, confdir, nml_file, data_list_path): ############################################################################### - data_list_path = os.path.join(case.get_case_root(), "Buildconf", "rof.input_data_list") - if os.path.exists(data_list_path): - os.remove(data_list_path) namelist_file = os.path.join(confdir, nml_file) nmlgen.write_output_file(namelist_file, data_list_path ) From 4c845c941fb63feef3e9733770141e9501c9093a Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 31 Mar 2022 17:05:55 -0600 Subject: [PATCH 03/21] Mark the USGS tests as failing because of issue #273 --- cime_config/testdefs/ExpectedTestFails.xml | 26 +++++++++++++++++++++- 1 file changed, 25 insertions(+), 1 deletion(-) diff --git a/cime_config/testdefs/ExpectedTestFails.xml b/cime_config/testdefs/ExpectedTestFails.xml index 834397d6c..2954f6ae7 100644 --- a/cime_config/testdefs/ExpectedTestFails.xml +++ b/cime_config/testdefs/ExpectedTestFails.xml @@ -39,7 +39,31 @@ FAIL - ESMCI/cime#143 + #273 + + + + + FAIL + #273 + + + + + FAIL + #273 + + + + + FAIL + #273 + + + + + FAIL + #273 From d2dfabceac1a1d00dc38360a635d933dc385b39c Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 14 Apr 2022 14:16:37 -0600 Subject: [PATCH 04/21] Fix type in expected fail --- cime_config/testdefs/ExpectedTestFails.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cime_config/testdefs/ExpectedTestFails.xml b/cime_config/testdefs/ExpectedTestFails.xml index 2954f6ae7..11dcb53fe 100644 --- a/cime_config/testdefs/ExpectedTestFails.xml +++ b/cime_config/testdefs/ExpectedTestFails.xml @@ -60,7 +60,7 @@ #273 - + FAIL #273 From 9b3f6a55d9e55fa8ace2bd261e618bc7bf44b048 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 14 Apr 2022 14:21:29 -0600 Subject: [PATCH 05/21] Remove all but one USGS test, since they fail --- cime_config/testdefs/ExpectedTestFails.xml | 24 --------------------- cime_config/testdefs/testlist_mizuRoute.xml | 15 ++----------- 2 files changed, 2 insertions(+), 37 deletions(-) diff --git a/cime_config/testdefs/ExpectedTestFails.xml b/cime_config/testdefs/ExpectedTestFails.xml index 11dcb53fe..02b351a17 100644 --- a/cime_config/testdefs/ExpectedTestFails.xml +++ b/cime_config/testdefs/ExpectedTestFails.xml @@ -42,30 +42,6 @@ #273 - - - FAIL - #273 - - - - - FAIL - #273 - - - - - FAIL - #273 - - - - - FAIL - #273 - - FAIL diff --git a/cime_config/testdefs/testlist_mizuRoute.xml b/cime_config/testdefs/testlist_mizuRoute.xml index 8a05cf4b3..f44d0e0cf 100644 --- a/cime_config/testdefs/testlist_mizuRoute.xml +++ b/cime_config/testdefs/testlist_mizuRoute.xml @@ -13,6 +13,7 @@ + @@ -116,19 +117,7 @@ - - - - - - - - - - - - - + From 7bfc0b647618875df1526a9de9f33a3589f653d7 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 14 Apr 2022 14:27:07 -0600 Subject: [PATCH 06/21] Shorten some lines to remove the warning on nag, and add required length for the X edit descriptor, which is required to compile with nag, it is required in the fortran standard, so this addresses part of #275 --- route/build/cpl/RtmTimeManager.F90 | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/route/build/cpl/RtmTimeManager.F90 b/route/build/cpl/RtmTimeManager.F90 index a938c142c..699035e5b 100644 --- a/route/build/cpl/RtmTimeManager.F90 +++ b/route/build/cpl/RtmTimeManager.F90 @@ -82,7 +82,9 @@ SUBROUTINE init_time(ierr, message) case('hours','hour','hr','h'); secPerTime=3600._r8; timePerDay=24._r8 case('days','day','d'); secPerTime=86400._r8; timePerDay=1._r8 case default - ierr=20; message=trim(message)//'= '//trim(time_units)//': must be seconds, minutes, hours or days.'; return + ierr=20 + message=trim(message)//'= '//trim(time_units)//': must be seconds, minutes, hours or days.' + return end select dt_day = dt/secprday ! dt [sec] -> dt_day @@ -122,7 +124,11 @@ SUBROUTINE init_time(ierr, message) end if ! check that the dates are aligned - if(endDatetime < begDatetime) then; ierr=20; message=trim(message)//'simulation end is before simulation start'; return; endif + if(endDatetime < begDatetime) then + ierr=20 + message=trim(message)//'simulation end is before simulation start' + return + endif ! initialize model time at first time step (1) and previous time step (0) iTime = 1 @@ -132,8 +138,10 @@ SUBROUTINE init_time(ierr, message) if (masterproc .and. debug_write) then write(iulog,*) 'simStart datetime = ', trim(simStart) write(iulog,*) 'simEnd datetime = ', trim(simEnd) - write(iulog,*) 'reference datetime = ', refDatetime%year(), refDatetime%month(), refDatetime%day(), refDatetime%hour(), refDatetime%minute(), refDatetime%sec() - write(iulog,*) 'simDatetime = ', simDatetime(1)%year(), simDatetime(1)%month(), simDatetime(1)%day(), simDatetime(1)%hour(), simDatetime(1)%minute(), simDatetime(1)%sec() + write(iulog,*) 'reference datetime = ', refDatetime%year(), refDatetime%month(), refDatetime%day() & + , refDatetime%hour(), refDatetime%minute(), refDatetime%sec() + write(iulog,*) 'simDatetime = ', simDatetime(1)%year(), simDatetime(1)%month(), simDatetime(1)%day() & + , simDatetime(1)%hour(), simDatetime(1)%minute(), simDatetime(1)%sec() write(iulog,*) 'dt [sec] = ', dt write(iulog,*) 'nTime = ', nTime write(iulog,*) 'iTime, timeVar(iTime) = ', iTime, timeVar(iTime) @@ -158,7 +166,7 @@ SUBROUTINE shr_timeStr(esmfTime, timeStr) call ESMF_TimeGet(esmfTime , yy=yy, mm=mm, dd=dd, h=hr, m=mn, s=sec, rc=rc ) - write(timeStr,'(i4.4,a,i2.2,a,i2.2,a,i2.2,a,i2.2,a,i2.2)'), yy,'-',mm,'-',dd,' ',hr,':',mn,':',sec + write(timeStr,'(i4.4,a,i2.2,a,i2.2,a,i2.2,a,i2.2,a,i2.2)') yy,'-',mm,'-',dd,' ',hr,':',mn,':',sec END SUBROUTINE shr_timeStr From 3052156b943ac296cdd14c97b4edd4a00e46cd64 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 14 Apr 2022 14:28:15 -0600 Subject: [PATCH 07/21] Use shsr_sys_system call rather than system intrinsic which isn't always available on all compilers, addresses #275 --- route/build/src/init_model_data.f90 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/route/build/src/init_model_data.f90 b/route/build/src/init_model_data.f90 index 8e12c85bf..b30d738e1 100644 --- a/route/build/src/init_model_data.f90 +++ b/route/build/src/init_model_data.f90 @@ -509,6 +509,7 @@ SUBROUTINE init_ntopo(nHRU_out, nRch_out, USE process_ntopo, ONLY: check_river_properties ! check if river network data is physically valid USE ncio_utils, ONLY: get_var_dims USE process_ntopo, ONLY: augment_ntopo ! compute all the additional network topology (only compute option = on) + USE shr_sys_mod, ONLY: shr_sys_system ! share system call implicit none ! input: None @@ -597,7 +598,8 @@ SUBROUTINE init_ntopo(nHRU_out, nRch_out, ! --> users can modify the hard-coded parameter "maxUpstreamFile" if desired if(tot_upstream > maxUpstreamFile) tot_upstream=0 - call system('rm -f '//trim(ancil_dir)//trim(fname_ntopNew)) + call shr_sys_system('rm -f '//trim(ancil_dir)//trim(fname_ntopNew), ierr) + if(ierr/=0)then; message=trim(message)//' problem deleting fname_ntopNew'; return; endif call writeData(& ! input From f43518c1331645b68949ccade1fc8c84241d1732 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 14 Apr 2022 14:29:06 -0600 Subject: [PATCH 08/21] Use shsr_sys_flush call rather than flush intrinsic which isn't always available on all compilers, addresses #275 --- route/build/src/mpi_utils.f90 | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/route/build/src/mpi_utils.f90 b/route/build/src/mpi_utils.f90 index bd2a1fcb1..f4b743dc5 100644 --- a/route/build/src/mpi_utils.f90 +++ b/route/build/src/mpi_utils.f90 @@ -9,6 +9,7 @@ MODULE mpi_utils USE globalData, ONLY: masterproc USE public_var, ONLY: root USE public_var, ONLY: iulog + USE shr_sys_mod,ONLY: shr_sys_flush implicit none private @@ -846,7 +847,7 @@ SUBROUTINE shr_mpi_abort(message, ierr, comm) !------------------------------------------------------------------------------- write(iulog,*) trim(subName),trim(message),ierr - call flush(6) + call shr_sys_flush(6) if (present(comm)) then call MPI_ABORT(comm, ierr, jerr) @@ -885,7 +886,7 @@ SUBROUTINE mpi_handle_err(ierr,pid) ! finalize MPI call MPI_FINALIZE(jerr) - call flush(6) + call shr_sys_flush(6) stop endif From 31b8d9c8237c9e893ebacb6cc29a8111d6a74da0 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 14 Apr 2022 14:30:29 -0600 Subject: [PATCH 09/21] Add required length to the X edit descriptor, addressing #275 --- route/build/src/accum_runoff.f90 | 6 +++--- route/build/src/dfw_route.f90 | 14 ++++++------- route/build/src/domain_decomposition.f90 | 4 ++-- route/build/src/irf_route.f90 | 8 ++++---- route/build/src/kwe_route.f90 | 16 +++++++-------- route/build/src/kwt_route.f90 | 26 ++++++++++++------------ route/build/src/mc_route.f90 | 19 +++++++++-------- route/build/src/read_control.f90 | 2 +- route/build/src/write_restart_pio.f90 | 2 +- route/build/src/write_simoutput_pio.f90 | 2 +- 10 files changed, 50 insertions(+), 49 deletions(-) diff --git a/route/build/src/accum_runoff.f90 b/route/build/src/accum_runoff.f90 index 8a41e75e6..1fd80b665 100644 --- a/route/build/src/accum_runoff.f90 +++ b/route/build/src/accum_runoff.f90 @@ -164,13 +164,13 @@ SUBROUTINE accum_qupstream(iEns, & ! input: index of runoff ensemble to write(fmt1,'(A,I5,A)') '(A,1X',nUps,'(1X,I10))' write(fmt2,'(A,I5,A)') '(A,1X',nUps,'(1X,F20.7))' write(*,'(2a)') new_line('a'),'** Check upstream discharge accumulation **' - write(*,'(a,x,I10,x,I10)') ' Reach index & ID =', segIndex, NETOPO_in(segIndex)%REACHID + write(*,'(a,1x,I10,1x,I10)') ' Reach index & ID =', segIndex, NETOPO_in(segIndex)%REACHID write(*,'(a)') ' * upstream reach index (NETOPO_in%UREACH) and discharge (uprflux) [m3/s] :' write(*,fmt1) ' UREACHK =', (NETOPO_in(segIndex)%UREACHK(iUps), iUps=1,nUps) write(*,fmt2) ' prflux =', (RCHFLX_out(iens,NETOPO_in(segIndex)%UREACHI(iUps))%ROUTE(idxSUM)%REACH_Q, iUps=1,nUps) write(*,'(a)') ' * local area discharge (RCHFLX_out%BASIN_QR(1)) and final discharge (RCHFLX_out%ROUTE(idxSUM)%REACH_Q) [m3/s] :' - write(*,'(a,x,F15.7)') ' RCHFLX_out%BASIN_QR(1) =', RCHFLX_out(iEns,segIndex)%BASIN_QR(1) - write(*,'(a,x,F15.7)') ' RCHFLX_out%ROUTE(idxSUM)%REACH_Q =', RCHFLX_out(iens,segIndex)%ROUTE(idxSUM)%REACH_Q + write(*,'(a,1x,F15.7)') ' RCHFLX_out%BASIN_QR(1) =', RCHFLX_out(iEns,segIndex)%BASIN_QR(1) + write(*,'(a,1x,F15.7)') ' RCHFLX_out%ROUTE(idxSUM)%REACH_Q =', RCHFLX_out(iens,segIndex)%ROUTE(idxSUM)%REACH_Q endif END SUBROUTINE accum_qupstream diff --git a/route/build/src/dfw_route.f90 b/route/build/src/dfw_route.f90 index 41dc1ee8d..b359e7350 100644 --- a/route/build/src/dfw_route.f90 +++ b/route/build/src/dfw_route.f90 @@ -192,10 +192,10 @@ SUBROUTINE dfw_rch(iEns, segIndex, & ! input: index of runoff ensemble to be pro if (nUps>0) then do iUps = 1,nUps iRch_ups = NETOPO_in(segIndex)%UREACHI(iUps) ! index of upstream of segIndex-th reach - write(iulog,'(A,X,I12,X,G15.4)') ' UREACHK, uprflux=',NETOPO_in(segIndex)%UREACHK(iUps),RCHFLX_out(iens, iRch_ups)%ROUTE(idxDW)%REACH_Q + write(iulog,'(A,1X,I12,1X,G15.4)') ' UREACHK, uprflux=',NETOPO_in(segIndex)%UREACHK(iUps),RCHFLX_out(iens, iRch_ups)%ROUTE(idxDW)%REACH_Q enddo end if - write(iulog,'(A,X,G15.4)') ' RCHFLX_out(iEns,segIndex)%BASIN_QR(1)=',RCHFLX_out(iEns,segIndex)%BASIN_QR(1) + write(iulog,'(A,1X,G15.4)') ' RCHFLX_out(iEns,segIndex)%BASIN_QR(1)=',RCHFLX_out(iEns,segIndex)%BASIN_QR(1) endif ! solve diffusive wave equation @@ -208,12 +208,12 @@ SUBROUTINE dfw_rch(iEns, segIndex, & ! input: index of runoff ensemble to be pro doCheck, & ! input: reach index to be examined ierr, cmessage) ! output: error control if(ierr/=0)then - write(message, '(A,X,I12,X,A)') trim(message)//'/segment=', NETOPO_in(segIndex)%REACHID, '/'//trim(cmessage) + write(message, '(A,1X,I12,1X,A)') trim(message)//'/segment=', NETOPO_in(segIndex)%REACHID, '/'//trim(cmessage) return endif if(doCheck)then - write(iulog,'(A,X,G15.4)') ' RCHFLX_out(iens,segIndex)%REACH_Q=', RCHFLX_out(iens,segIndex)%ROUTE(idxDW)%REACH_Q + write(iulog,'(A,1X,G15.4)') ' RCHFLX_out(iens,segIndex)%REACH_Q=', RCHFLX_out(iens,segIndex)%ROUTE(idxDW)%REACH_Q endif END SUBROUTINE dfw_rch @@ -333,14 +333,14 @@ SUBROUTINE diffusive_wave(rch_param, & ! input: river parameter data structu dt = T1-T0 if (doCheck) then - write(iulog,'(4(A,X,G15.4))') ' length [m] =',rch_param%RLENGTH,'slope [-] =',rch_param%R_SLOPE,'channel width [m] =',rch_param%R_WIDTH,'manning coef =',rch_param%R_MAN_N + write(iulog,'(4(A,1X,G15.4))') ' length [m] =',rch_param%RLENGTH,'slope [-] =',rch_param%R_SLOPE,'channel width [m] =',rch_param%R_WIDTH,'manning coef =',rch_param%R_MAN_N end if ! time-step adjustment so Courant number is less than 1 dTsub = dt/ntSub if (doCheck) then - write(iulog,'(A,X,I3,A,X,G12.5)') ' No. sub timestep=',nTsub,' sub time-step [sec]=',dTsub + write(iulog,'(A,1X,I3,A,1X,G12.5)') ' No. sub timestep=',nTsub,' sub time-step [sec]=',dTsub end if allocate(Qlocal(1:nMolecule%DW_ROUTE, 0:1), stat=ierr, errmsg=cmessage) @@ -453,7 +453,7 @@ SUBROUTINE diffusive_wave(rch_param, & ! input: river parameter data structu endif if (doCheck) then - write(iulog,'(A,X,G12.5)') ' Qout(t) =', rflux%ROUTE(idxDW)%REACH_Q + write(iulog,'(A,1X,G12.5)') ' Qout(t) =', rflux%ROUTE(idxDW)%REACH_Q endif END SUBROUTINE diffusive_wave diff --git a/route/build/src/domain_decomposition.f90 b/route/build/src/domain_decomposition.f90 index e40135369..f3dd547c9 100644 --- a/route/build/src/domain_decomposition.f90 +++ b/route/build/src/domain_decomposition.f90 @@ -115,11 +115,11 @@ SUBROUTINE print_screen() associate (segIndexSub => domains_mpi(ix)%segIndex, nSubSeg => size(domains_mpi(ix)%segIndex)) do iSeg = 1,size(segIndexSub) if (downIndex(segIndexSub(iSeg)) > 0) then - write(iulog, "(I9,x,I12,x,I9,x,I12,x,I5,x,I3)") segIndexSub(iSeg),segId(segIndexSub(iSeg)), & + write(iulog, "(I9,1x,I12,1x,I9,1x,I12,1x,I5,1x,I3)") segIndexSub(iSeg),segId(segIndexSub(iSeg)), & downIndex(segIndexSub(iSeg)),segId(downIndex(segIndexSub(iSeg))), & ix, domains_mpi(ix)%idNode else - write(iulog, "(I9,x,I12,x,I9,x,I12,x,I5,x,I3)") segIndexSub(iSeg),segId(segIndexSub(iSeg)), & + write(iulog, "(I9,1x,I12,1x,I9,1x,I12,1x,I5,1x,I3)") segIndexSub(iSeg),segId(segIndexSub(iSeg)), & downIndex(segIndexSub(iSeg)),-999, & ix, domains_mpi(ix)%idNode endif diff --git a/route/build/src/irf_route.f90 b/route/build/src/irf_route.f90 index 034a37c9e..d25df3ad9 100644 --- a/route/build/src/irf_route.f90 +++ b/route/build/src/irf_route.f90 @@ -222,12 +222,12 @@ subroutine segment_irf(iEns, & ! input: index of runoff ensemble to be p ntdh = size(NETOPO_in(segIndex)%UH) write(fmt1,'(A,I5,A)') '(A, 1X',ntdh,'(1X,F20.7))' write(*,'(2a)') new_line('a'),'** Check Impulse Response Function routing **' - write(*,'(a,x,I10,x,I10)') ' Reach index & ID =', segIndex, NETOPO_in(segIndex)%REACHID + write(*,'(a,1x,I10,1x,I10)') ' Reach index & ID =', segIndex, NETOPO_in(segIndex)%REACHID write(*,fmt1) ' Unit-Hydrograph =', (NETOPO_in(segIndex)%UH(itdh), itdh=1,ntdh) write(*,'(a)') ' * total discharge from upstream(q_upstream) [m3/s], local area discharge [m3/s], and Final discharge [m3/s]:' - write(*,'(a,x,F15.7)') ' q_upstream =', q_upstream - write(*,'(a,x,F15.7)') ' RCHFLX_out%BASIN_QR(1) =', RCHFLX_out(iens,segIndex)%BASIN_QR(1) - write(*,'(a,x,F15.7)') ' RCHFLX_out%REACH_Q =', RCHFLX_out(iens,segIndex)%ROUTE(idxIRF)%REACH_Q + write(*,'(a,1x,F15.7)') ' q_upstream =', q_upstream + write(*,'(a,1x,F15.7)') ' RCHFLX_out%BASIN_QR(1) =', RCHFLX_out(iens,segIndex)%BASIN_QR(1) + write(*,'(a,1x,F15.7)') ' RCHFLX_out%REACH_Q =', RCHFLX_out(iens,segIndex)%ROUTE(idxIRF)%REACH_Q endif end subroutine segment_irf diff --git a/route/build/src/kwe_route.f90 b/route/build/src/kwe_route.f90 index b398432ea..594b41fd0 100644 --- a/route/build/src/kwe_route.f90 +++ b/route/build/src/kwe_route.f90 @@ -192,10 +192,10 @@ SUBROUTINE kw_rch(iEns, segIndex, & ! input: index of runoff ensemble to be proc if (nUps>0) then do iUps = 1,nUps iRch_ups = NETOPO_in(segIndex)%UREACHI(iUps) ! index of upstream of segIndex-th reach - write(iulog,'(A,X,I12,X,G15.4)') ' UREACHK, uprflux=',NETOPO_in(segIndex)%UREACHK(iUps),RCHFLX_out(iens, iRch_ups)%ROUTE(idxKW)%REACH_Q + write(iulog,'(A,1X,I12,1X,G15.4)') ' UREACHK, uprflux=',NETOPO_in(segIndex)%UREACHK(iUps),RCHFLX_out(iens, iRch_ups)%ROUTE(idxKW)%REACH_Q enddo end if - write(iulog,'(A,X,G15.4)') ' RCHFLX_out(iEns,segIndex)%BASIN_QR(1)=',RCHFLX_out(iEns,segIndex)%BASIN_QR(1) + write(iulog,'(A,1X,G15.4)') ' RCHFLX_out(iEns,segIndex)%BASIN_QR(1)=',RCHFLX_out(iEns,segIndex)%BASIN_QR(1) endif ! perform river network KW routing @@ -208,11 +208,11 @@ SUBROUTINE kw_rch(iEns, segIndex, & ! input: index of runoff ensemble to be proc doCheck, & ! input: reach index to be examined ierr, cmessage) ! output: error control if(ierr/=0)then - write(message, '(A,X,I12,X,A)') trim(message)//'/segment=', NETOPO_in(segIndex)%REACHID, '/'//trim(cmessage); return + write(message, '(A,1X,I12,1X,A)') trim(message)//'/segment=', NETOPO_in(segIndex)%REACHID, '/'//trim(cmessage); return endif if(doCheck)then - write(iulog,'(A,X,G15.4)') ' RCHFLX_out(iens,segIndex)%REACH_Q=', RCHFLX_out(iens,segIndex)%ROUTE(idxKW)%REACH_Q + write(iulog,'(A,1X,G15.4)') ' RCHFLX_out(iens,segIndex)%REACH_Q=', RCHFLX_out(iens,segIndex)%ROUTE(idxKW)%REACH_Q endif END SUBROUTINE kw_rch @@ -298,8 +298,8 @@ SUBROUTINE kinematic_wave(rch_param, & ! input: river parameter data structu Q(1,0) = q_upstream if (doCheck) then - write(iulog,'(3(A,X,G12.5))') ' R_SLOPE=',rch_param%R_SLOPE,' R_WIDTH=',rch_param%R_WIDTH,' R_MANN=',rch_param%R_MAN_N - write(iulog,'(3(A,X,G12.5))') ' Q(0,0)=',Q(0,0),' Q(0,1)=',Q(0,1),' Q(1,0)=',Q(1,0) + write(iulog,'(3(A,1X,G12.5))') ' R_SLOPE=',rch_param%R_SLOPE,' R_WIDTH=',rch_param%R_WIDTH,' R_MANN=',rch_param%R_MAN_N + write(iulog,'(3(A,1X,G12.5))') ' Q(0,0)=',Q(0,0),' Q(0,1)=',Q(0,1),' Q(1,0)=',Q(1,0) end if ! ---------- @@ -340,7 +340,7 @@ SUBROUTINE kinematic_wave(rch_param, & ! input: river parameter data structu endif if (doCheck) then - write(iulog,'(1(A,X,G15.4))') ' Q(1,1)=',Q(1,1) + write(iulog,'(1(A,1X,G15.4))') ' Q(1,1)=',Q(1,1) end if else ! if head-water @@ -350,7 +350,7 @@ SUBROUTINE kinematic_wave(rch_param, & ! input: river parameter data structu if (doCheck) then write(iulog,'(A)') ' This is headwater ' - write(iulog,'(1(A,X,G15.4))') ' Q(1,1)=',Q(1,1) + write(iulog,'(1(A,1X,G15.4))') ' Q(1,1)=',Q(1,1) endif endif diff --git a/route/build/src/kwt_route.f90 b/route/build/src/kwt_route.f90 index 3e351fc2a..4bb40a2eb 100644 --- a/route/build/src/kwt_route.f90 +++ b/route/build/src/kwt_route.f90 @@ -249,11 +249,11 @@ SUBROUTINE qroute_rch(IENS,JRCH, & ! input: array indices if(JRCH==ixDesire) then write(iulog,'(2a)') new_line('a'),'** Check kinematic wave tracking routing **' - write(iulog,"(a,x,I10,x,I10)") ' Reach index & ID =', JRCH, NETOPO_in(JRCH)%REACHID - write(iulog,"(a,x,F20.7,1x,F20.7)") ' time step(T0,T1) =', T0, T1 - write(iulog,'(a,x,F15.7)') ' RPARAM_in%R_SLOPE =', RPARAM_in(JRCH)%R_SLOPE - write(iulog,'(a,x,F15.7)') ' RPARAM_in%R_MAN_N =', RPARAM_in(JRCH)%R_MAN_N - write(iulog,'(a,x,F15.7)') ' RPARAM_in%R_WIDTH =', RPARAM_in(JRCH)%R_WIDTH + write(iulog,"(a,1x,I10,1x,I10)") ' Reach index & ID =', JRCH, NETOPO_in(JRCH)%REACHID + write(iulog,"(a,1x,F20.7,1x,F20.7)") ' time step(T0,T1) =', T0, T1 + write(iulog,'(a,1x,F15.7)') ' RPARAM_in%R_SLOPE =', RPARAM_in(JRCH)%R_SLOPE + write(iulog,'(a,1x,F15.7)') ' RPARAM_in%R_MAN_N =', RPARAM_in(JRCH)%R_MAN_N + write(iulog,'(a,1x,F15.7)') ' RPARAM_in%R_WIDTH =', RPARAM_in(JRCH)%R_WIDTH end if ! RCHFLX_out(IENS,JRCH)%TAKE=0.0_dp ! initialize take from this reach @@ -297,7 +297,7 @@ SUBROUTINE qroute_rch(IENS,JRCH, & ! input: array indices if(JRCH==ixDesire) then write(iulog,'(a)') ' * Final discharge (RCHFLX_out(IENS,JRCH)%REACH_Q) [m3/s]:' - write(iulog,'(x,F20.7)') RCHFLX_out(IENS,JRCH)%ROUTE(idxKWT)%REACH_Q + write(iulog,'(1x,F20.7)') RCHFLX_out(IENS,JRCH)%ROUTE(idxKWT)%REACH_Q end if return ! no upstream reaches (routing for sub-basins done using time-delay histogram) endif @@ -531,9 +531,9 @@ SUBROUTINE extract_from_rch(iens, jrch, & ! input: ensemble and rea call interp_rch(TENTRY(0:NR-1),Q_jrch_abs(0:NR-1), TP, Qavg, ierr,cmessage) Qabs = Qavg(1)*RPARAM_in(JRCH)%R_WIDTH write(*,'(a)') ' * Target abstraction (Qtake) [m3/s], Available discharge (totQ) [m3/s], Actual abstraction (Qabs) [m3/s] ' - write(*,'(a,x,F15.7)') ' Qtake =', Qtake - write(*,'(a,x,F15.7)') ' totQ =', totQ - write(*,'(a,x,F15.7)') ' Qabs =', Qabs + write(*,'(a,1x,F15.7)') ' Qtake =', Qtake + write(*,'(a,1x,F15.7)') ' totQ =', totQ + write(*,'(a,1x,F15.7)') ' Qabs =', Qabs end if ! modify wave speed at modified wave discharge and re-compute exit time @@ -679,7 +679,7 @@ subroutine getusq_rch(IENS,JRCH,LAKEFLAG,T0,T1,ixDesire, & ! input if (JRCH == ixDesire) then write(fmt1,'(A,I5,A)') '(A,1X',ND,'(1X,F15.7))' write(*,'(a)') ' * After qexmul_rch: # of routed wave from upstreams (ND) and wave discharge (QD) [m2/s]:' - write(*,'(A,x,I5)') ' ND=', ND + write(*,'(A,1x,I5)') ' ND=', ND write(*,fmt1) ' QD=', (QD(iw), iw=1,ND) end if end if @@ -863,7 +863,7 @@ SUBROUTINE qexmul_rch(IENS,JRCH,T0,T1,ixDesire, & ! input TD(1) = T1 if(JRCH == ixDesire) then - write(iulog,'(A,x,I8,x,I8)') ' * Special case - This reach has one headwater upstream: IR, NETOPO_in(IR)%REACHID = ', IR, NETOPO_in(IR)%REACHID + write(iulog,'(A,1x,I8,1x,I8)') ' * Special case - This reach has one headwater upstream: IR, NETOPO_in(IR)%REACHID = ', IR, NETOPO_in(IR)%REACHID end if return @@ -1406,7 +1406,7 @@ SUBROUTINE kinwav_rch(JRCH,T_START,T_END,ixDesire, & ! input: loca if(jRch==ixDesire) then write(fmt1,'(A,I5,A)') '(A,1X',NN,'(1X,F15.7))' write(iulog,'(a)') ' * Wave discharge (q1) [m2/s] and wave celertiy (wc) [m/s]:' - write(iulog,'(a,x,I3)') ' Number of wave =', NN + write(iulog,'(a,1x,I3)') ' Number of wave =', NN write(iulog,fmt1) ' q1=', (q1(iw), iw=1,NN) write(iulog,fmt1) ' wc=', (wc(iw), iw=1,NN) end if @@ -1466,7 +1466,7 @@ SUBROUTINE kinwav_rch(JRCH,T_START,T_END,ixDesire, & ! input: loca if(jRch==ixDesire) then write(fmt1,'(A,I5,A)') '(A,1X',NN,'(1X,F15.7))' write(iulog,'(a)') ' * After wave merge: wave celertiy (wc) [m/s]:' - write(iulog,'(a,x,I3)') ' Number of wave =', NN + write(iulog,'(a,1x,I3)') ' Number of wave =', NN write(iulog,fmt1) ' wc=', (wc(iw), iw=1,NN) end if diff --git a/route/build/src/mc_route.f90 b/route/build/src/mc_route.f90 index 4978e2456..dbb40415a 100644 --- a/route/build/src/mc_route.f90 +++ b/route/build/src/mc_route.f90 @@ -194,10 +194,10 @@ SUBROUTINE mc_rch(iEns, segIndex, & ! input: index of runoff ensemble to be proc if (nUps>0) then do iUps = 1,nUps iRch_ups = NETOPO_in(segIndex)%UREACHI(iUps) ! index of upstream of segIndex-th reach - write(iulog,'(A,X,I6,X,G12.5)') ' UREACHK, uprflux=',NETOPO_in(segIndex)%UREACHK(iUps),RCHFLX_out(iens, iRch_ups)%ROUTE(idxMC)%REACH_Q + write(iulog,'(A,1X,I6,1X,G12.5)') ' UREACHK, uprflux=',NETOPO_in(segIndex)%UREACHK(iUps),RCHFLX_out(iens, iRch_ups)%ROUTE(idxMC)%REACH_Q enddo end if - write(iulog,'(A,X,G12.5)') ' RCHFLX_out(iEns,segIndex)%BASIN_QR(1)=',RCHFLX_out(iEns,segIndex)%BASIN_QR(1) + write(iulog,'(A,1X,G12.5)') ' RCHFLX_out(iEns,segIndex)%BASIN_QR(1)=',RCHFLX_out(iEns,segIndex)%BASIN_QR(1) endif ! solve muskingum-cunge alogorithm @@ -210,11 +210,11 @@ SUBROUTINE mc_rch(iEns, segIndex, & ! input: index of runoff ensemble to be proc doCheck, & ! input: reach index to be examined ierr, cmessage) ! output: error control if(ierr/=0)then - write(message, '(A,X,I10,X,A)') trim(message)//'/segment=', NETOPO_in(segIndex)%REACHID, '/'//trim(cmessage); return + write(message, '(A,1X,I10,1X,A)') trim(message)//'/segment=', NETOPO_in(segIndex)%REACHID, '/'//trim(cmessage); return endif if(doCheck)then - write(iulog,'(A,X,G12.5)') ' RCHFLX_out(iens,segIndex)%REACH_Q=', RCHFLX_out(iens,segIndex)%ROUTE(idxMC)%REACH_Q + write(iulog,'(A,1X,G12.5)') ' RCHFLX_out(iens,segIndex)%REACH_Q=', RCHFLX_out(iens,segIndex)%ROUTE(idxMC)%REACH_Q endif END SUBROUTINE mc_rch @@ -244,6 +244,7 @@ SUBROUTINE muskingum_cunge(rch_param, & ! input: river parameter data struct ! state array: ! (time:0:1, loc:0:1) 0-previous time step/inlet, 1-current time step/outlet. ! Q or A(1,2,3,4): 1: (t=0,x=0), 2: (t=0,x=1), 3: (t=1,x=0), 4: (t=1,x=1) + use shr_infnan_mod, only : isnan => shr_infnan_isnan implicit none ! argument variables @@ -301,8 +302,8 @@ SUBROUTINE muskingum_cunge(rch_param, & ! input: river parameter data struct Q(1,0) = q_upstream if (doCheck) then - write(iulog,'(4(A,X,G12.5))') ' length [m] =',rch_param%RLENGTH,'slope [-] =',rch_param%R_SLOPE,'channel width [m] =',rch_param%R_WIDTH,'manning coef =',rch_param%R_MAN_N - write(iulog,'(3(A,X,G12.5))') ' Qin(t-1) Q(0,0)=',Q(0,0),' Qin(t) Q(0,1)=',Q(0,1),' Qout(t-1) Q(1,0)=',Q(1,0) + write(iulog,'(4(A,1X,G12.5))') ' length [m] =',rch_param%RLENGTH,'slope [-] =',rch_param%R_SLOPE,'channel width [m] =',rch_param%R_WIDTH,'manning coef =',rch_param%R_MAN_N + write(iulog,'(3(A,1X,G12.5))') ' Qin(t-1) Q(0,0)=',Q(0,0),' Qin(t) Q(0,1)=',Q(0,1),' Qout(t-1) Q(1,0)=',Q(1,0) end if ! first, using 3-point average in computational molecule, check Cournat number is less than 1, otherwise subcycle within one time step @@ -320,7 +321,7 @@ SUBROUTINE muskingum_cunge(rch_param, & ! input: river parameter data struct dTsub = dt/ntSub end if if (doCheck) then - write(iulog,'(A,X,I3,A,X,G12.5)') ' No. sub timestep=',nTsub,' sub time-step [sec]=',dTsub + write(iulog,'(A,1X,I3,A,1X,G12.5)') ' No. sub timestep=',nTsub,' sub time-step [sec]=',dTsub end if allocate(QoutLocal(0:ntSub), QinLocal(0:ntSub), stat=ierr, errmsg=cmessage) @@ -353,7 +354,7 @@ SUBROUTINE muskingum_cunge(rch_param, & ! input: river parameter data struct end if if (doCheck) then - write(iulog,'(A,I3,X,A,G12.5,X,A,G12.5)') ' sub time-step= ',ix,'Courant number= ',Cn, 'Q= ',QoutLocal(ix) + write(iulog,'(A,I3,1X,A,G12.5,1X,A,G12.5)') ' sub time-step= ',ix,'Courant number= ',Cn, 'Q= ',QoutLocal(ix) end if end do @@ -379,7 +380,7 @@ SUBROUTINE muskingum_cunge(rch_param, & ! input: river parameter data struct rflux%ROUTE(idxMC)%REACH_Q = Q(1,1)+rflux%BASIN_QR(1) if (doCheck) then - write(iulog,'(A,X,G12.5)') ' Qout(t)=',Q(1,1) + write(iulog,'(A,1X,G12.5)') ' Qout(t)=',Q(1,1) endif ! save inflow (index 1) and outflow (index 2) at current time step diff --git a/route/build/src/read_control.f90 b/route/build/src/read_control.f90 index 8f6131785..e8a7db090 100644 --- a/route/build/src/read_control.f90 +++ b/route/build/src/read_control.f90 @@ -94,7 +94,7 @@ SUBROUTINE read_control(ctl_fname, err, message) cName = adjustl(cLines(iLine)(ibeg_name:iend_name)) cData = adjustl(cLines(iLine)(iend_name+1:iend_data-1)) if (masterproc) then - write(iulog,'(x,a,a,a)') trim(cName), ' --> ', trim(cData) + write(iulog,'(1x,a,a,a)') trim(cName), ' --> ', trim(cData) endif ! populate variables diff --git a/route/build/src/write_restart_pio.f90 b/route/build/src/write_restart_pio.f90 index 700a263d6..abce51db4 100644 --- a/route/build/src/write_restart_pio.f90 +++ b/route/build/src/write_restart_pio.f90 @@ -220,7 +220,7 @@ SUBROUTINE restart_fname(fname, timeStamp, ierr, message) type(datetime) :: restartTimeStamp ! datetime corresponding to file name time stamp character(len=strLen) :: cmessage ! error message of downwind routine integer(i4b) :: sec_in_day ! second within day - character(len=50),parameter :: fmtYMDHMS = '(2a,I0.4,a,I0.2,a,I0.2,x,I0.2,a,I0.2,a,I0.2)' + character(len=50),parameter :: fmtYMDHMS = '(2a,I0.4,a,I0.2,a,I0.2,1x,I0.2,a,I0.2,a,I0.2)' character(len=50),parameter :: fmtYMDS='(a,I0.4,a,I0.2,a,I0.2,a,I0.5,a)' ierr=0; message='restart_fname/' diff --git a/route/build/src/write_simoutput_pio.f90 b/route/build/src/write_simoutput_pio.f90 index f083864df..04db1073f 100644 --- a/route/build/src/write_simoutput_pio.f90 +++ b/route/build/src/write_simoutput_pio.f90 @@ -92,7 +92,7 @@ SUBROUTINE new_file_alarm(newFileAlarm, ierr, message) ! print progress if (masterproc) then - write(iulog,'(a,I4,4(x,I4))') new_line('a'), simDatetime(1)%year(), simDatetime(1)%month(), simDatetime(1)%day(), simDatetime(1)%hour(), simDatetime(1)%minute() + write(iulog,'(a,I4,4(1x,I4))') new_line('a'), simDatetime(1)%year(), simDatetime(1)%month(), simDatetime(1)%day(), simDatetime(1)%hour(), simDatetime(1)%minute() endif ! check need for the new file From bb2892d00a8cb20d7fc3f94c9ce8f09fbb7748d5 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Thu, 14 Apr 2022 17:18:20 -0600 Subject: [PATCH 10/21] Use case convention for mizuRoute USE statements --- route/build/src/mc_route.f90 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/route/build/src/mc_route.f90 b/route/build/src/mc_route.f90 index dbb40415a..7cc9c965b 100644 --- a/route/build/src/mc_route.f90 +++ b/route/build/src/mc_route.f90 @@ -244,7 +244,7 @@ SUBROUTINE muskingum_cunge(rch_param, & ! input: river parameter data struct ! state array: ! (time:0:1, loc:0:1) 0-previous time step/inlet, 1-current time step/outlet. ! Q or A(1,2,3,4): 1: (t=0,x=0), 2: (t=0,x=1), 3: (t=1,x=0), 4: (t=1,x=1) - use shr_infnan_mod, only : isnan => shr_infnan_isnan + USE shr_infnan_mod, ONLY: isnan => shr_infnan_isnan implicit none ! argument variables From fd99715dc24f2b461ec1b4e753b55ad91ba45130 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Wed, 27 Apr 2022 14:27:54 -0600 Subject: [PATCH 11/21] Update ntopo file with CDF5 version --- cime_config/buildnml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cime_config/buildnml b/cime_config/buildnml index 5185199f4..4d5dbbe0a 100755 --- a/cime_config/buildnml +++ b/cime_config/buildnml @@ -99,7 +99,7 @@ def _create_control_files(case, caseroot, srcroot, confdir, inst_string, infile, varname_downSegId = "Tosegment" varname_pfafCode = "pfaf" elif ( config['rof_grid'] == "USGS_GFmz" ): - fname_ntopOld = "ntopo_USGS-GFmz_Conus_cdf5_c20201008.nc" + fname_ntopOld = "ntopo_USGS-GFmz_Conus_cdf5_c20220427.nc" varname_area = "Basin_Area" varname_length = "Length" varname_slope = "Slope" From 976d74e472e869b4f18ebb57bb278ec329e36607 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Wed, 27 Apr 2022 14:28:17 -0600 Subject: [PATCH 12/21] Add PGI test to expected fails --- cime_config/testdefs/ExpectedTestFails.xml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cime_config/testdefs/ExpectedTestFails.xml b/cime_config/testdefs/ExpectedTestFails.xml index 02b351a17..d8a5fe80f 100644 --- a/cime_config/testdefs/ExpectedTestFails.xml +++ b/cime_config/testdefs/ExpectedTestFails.xml @@ -30,6 +30,12 @@ + + + FAIL + PGI problems with the nuopc driver + + FAIL From 326c2fc80d4672842ff15c6894169b91bd001a1a Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Fri, 13 May 2022 13:17:26 -0600 Subject: [PATCH 13/21] Nag compiler complains about this line, because the deallocate was already done just above, you could nullify the previous pointer after deallocating it, and then you could check if list is associated, since it would be nullified, as is now it fails on doing the associated function on a dangling pointer --- route/build/src/ascii_util.f90 | 1 - 1 file changed, 1 deletion(-) diff --git a/route/build/src/ascii_util.f90 b/route/build/src/ascii_util.f90 index 7abdc0f8c..d47462740 100644 --- a/route/build/src/ascii_util.f90 +++ b/route/build/src/ascii_util.f90 @@ -205,7 +205,6 @@ SUBROUTINE get_vlines(unt,vlines,err,message) previous=>current; current=>current%next deallocate(previous) end do - if(associated(list)) nullify(list) END SUBROUTINE get_vlines ! ********************************************************************************************** From bd15154e52eef112b026fd08e26066c291d29289 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Fri, 13 May 2022 13:58:48 -0600 Subject: [PATCH 14/21] Nag compiler pointed out that you shouldn't send the same variable to two dummy arguments in a subroutine, so added a check that the index weren't the same, and also only do the swap if the valus are actually different --- route/build/src/nr_utility.f90 | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/route/build/src/nr_utility.f90 b/route/build/src/nr_utility.f90 index 7fa124419..cc6e2d80e 100644 --- a/route/build/src/nr_utility.f90 +++ b/route/build/src/nr_utility.f90 @@ -124,7 +124,7 @@ SUBROUTINE indexx(arr,index) if (arr(index(j)) <= a) exit end do if (j < i) exit - call swap(index(i),index(j)) + if ( i /= j ) call swap(index(i),index(j)) end do index(l+1)=index(j) index(j)=indext @@ -157,9 +157,11 @@ END SUBROUTINE indexx SUBROUTINE swap(a,b) INTEGER(I4B), INTENT(INOUT) :: a,b INTEGER(I4B) :: dum - dum=a - a=b - b=dum + if ( a /= b )then + dum=a + a=b + b=dum + end if END SUBROUTINE swap ! ************************************************************************************************ From 97dbabb720dd4dfa7c8dddabe996d724d2ad68e0 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Fri, 13 May 2022 17:27:32 -0600 Subject: [PATCH 15/21] Fix misspelling --- cime_config/testdefs/testlist_mizuRoute.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cime_config/testdefs/testlist_mizuRoute.xml b/cime_config/testdefs/testlist_mizuRoute.xml index f44d0e0cf..654ce2dd1 100644 --- a/cime_config/testdefs/testlist_mizuRoute.xml +++ b/cime_config/testdefs/testlist_mizuRoute.xml @@ -3,7 +3,7 @@ - + From 8bde4a287fb5edc8a7e1cf7a5a9f10665aaba49f Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Sat, 14 May 2022 16:55:19 -0600 Subject: [PATCH 16/21] Add expected fail --- cime_config/testdefs/ExpectedTestFails.xml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cime_config/testdefs/ExpectedTestFails.xml b/cime_config/testdefs/ExpectedTestFails.xml index d8a5fe80f..1e4dc1f37 100644 --- a/cime_config/testdefs/ExpectedTestFails.xml +++ b/cime_config/testdefs/ExpectedTestFails.xml @@ -66,6 +66,12 @@ #226 + + + FAIL + #280 + + FAIL From ca94d1c478e5fc5a9cc4f38388941ce010459f58 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Sat, 14 May 2022 18:01:20 -0600 Subject: [PATCH 17/21] Rename user_ctl_mizuroute files to user_nl_mizuroute_ctl fixing #281 --- cime_config/buildnml | 4 ++-- .../default/{user_ctl_mizuroute => user_nl_mizuroute_ctl} | 0 .../monthly/{user_ctl_mizuroute => user_nl_mizroute_ctl} | 0 cime_config/{user_ctl_mizuroute => user_nl_mizuroute_ctl} | 0 4 files changed, 2 insertions(+), 2 deletions(-) rename cime_config/testdefs/testmods_dirs/mizuroute/default/{user_ctl_mizuroute => user_nl_mizuroute_ctl} (100%) rename cime_config/testdefs/testmods_dirs/mizuroute/monthly/{user_ctl_mizuroute => user_nl_mizroute_ctl} (100%) rename cime_config/{user_ctl_mizuroute => user_nl_mizuroute_ctl} (100%) diff --git a/cime_config/buildnml b/cime_config/buildnml index 4d5dbbe0a..f55e5f6a0 100755 --- a/cime_config/buildnml +++ b/cime_config/buildnml @@ -206,7 +206,7 @@ def _create_control_files(case, caseroot, srcroot, confdir, inst_string, infile, ctl.set( "fname_state_in", fname_state_in ) # Read in the user control file for the case and change settings to it - file_src = "user_ctl_mizuroute" + file_src = "user_nl_mizuroute_ctl" user_ctl_file = os.path.join(caseroot, file_src + inst_string) if ( not os.path.exists( user_ctl_file ) ): safe_copy( os.path.join( srcroot, "cime_config", file_src), user_ctl_file ) @@ -214,7 +214,7 @@ def _create_control_files(case, caseroot, srcroot, confdir, inst_string, infile, usrctl.read( user_ctl_file, allowEmpty=True ) for element in usrctl.get_elmList(): value = ctl.get( element ) - expect( value != "UNSET", "Element in the user_ctl_mizuroute file is NOT in the control file: "+element ) + expect( value != "UNSET", "Element in the user_nl_mizuroute_ctl file is NOT in the control file: "+element ) ctl.set( element, usrctl.get( element ) ) #---------------------------------------------------- diff --git a/cime_config/testdefs/testmods_dirs/mizuroute/default/user_ctl_mizuroute b/cime_config/testdefs/testmods_dirs/mizuroute/default/user_nl_mizuroute_ctl similarity index 100% rename from cime_config/testdefs/testmods_dirs/mizuroute/default/user_ctl_mizuroute rename to cime_config/testdefs/testmods_dirs/mizuroute/default/user_nl_mizuroute_ctl diff --git a/cime_config/testdefs/testmods_dirs/mizuroute/monthly/user_ctl_mizuroute b/cime_config/testdefs/testmods_dirs/mizuroute/monthly/user_nl_mizroute_ctl similarity index 100% rename from cime_config/testdefs/testmods_dirs/mizuroute/monthly/user_ctl_mizuroute rename to cime_config/testdefs/testmods_dirs/mizuroute/monthly/user_nl_mizroute_ctl diff --git a/cime_config/user_ctl_mizuroute b/cime_config/user_nl_mizuroute_ctl similarity index 100% rename from cime_config/user_ctl_mizuroute rename to cime_config/user_nl_mizuroute_ctl From 8654f4aadaa374245803fd7b87f8b59a8aa4c0a9 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Sat, 14 May 2022 18:08:03 -0600 Subject: [PATCH 18/21] Replace pgi test with nvhpc --- cime_config/testdefs/testlist_mizuRoute.xml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cime_config/testdefs/testlist_mizuRoute.xml b/cime_config/testdefs/testlist_mizuRoute.xml index 654ce2dd1..7e41959ef 100644 --- a/cime_config/testdefs/testlist_mizuRoute.xml +++ b/cime_config/testdefs/testlist_mizuRoute.xml @@ -7,7 +7,7 @@ - + @@ -78,10 +78,10 @@ + - From 74d196df886832f8ac33f495bc7356b7f3ff828a Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Sun, 15 May 2022 18:24:41 -0600 Subject: [PATCH 19/21] Adjust test list, nvhpc should be only DEBUG off for now, do only one ER test with nag, add a 5x5 threaded test since the 1x25 one fails on izumi --- cime_config/testdefs/testlist_mizuRoute.xml | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/cime_config/testdefs/testlist_mizuRoute.xml b/cime_config/testdefs/testlist_mizuRoute.xml index 7e41959ef..2beedd5cf 100644 --- a/cime_config/testdefs/testlist_mizuRoute.xml +++ b/cime_config/testdefs/testlist_mizuRoute.xml @@ -47,6 +47,7 @@ + @@ -57,7 +58,6 @@ - @@ -78,7 +78,6 @@ - @@ -105,7 +104,17 @@ - + + + + + + + + + + + From 29eb14fa112c611ec60fd6aca85a055c22d799e7 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Sun, 15 May 2022 18:25:45 -0600 Subject: [PATCH 20/21] Add to expected fails list --- cime_config/testdefs/ExpectedTestFails.xml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cime_config/testdefs/ExpectedTestFails.xml b/cime_config/testdefs/ExpectedTestFails.xml index 1e4dc1f37..84348f7ba 100644 --- a/cime_config/testdefs/ExpectedTestFails.xml +++ b/cime_config/testdefs/ExpectedTestFails.xml @@ -72,6 +72,12 @@ #280 + + + FAIL + ESCOMP/CDEPS/#161 + + FAIL From 2d616864f8205aa5a0bcf039d6d567368cad9f41 Mon Sep 17 00:00:00 2001 From: Erik Kluzek Date: Sun, 15 May 2022 20:50:27 -0600 Subject: [PATCH 21/21] Remove two tests from expected fails that are working now --- cime_config/testdefs/ExpectedTestFails.xml | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/cime_config/testdefs/ExpectedTestFails.xml b/cime_config/testdefs/ExpectedTestFails.xml index 84348f7ba..d977011ae 100644 --- a/cime_config/testdefs/ExpectedTestFails.xml +++ b/cime_config/testdefs/ExpectedTestFails.xml @@ -36,24 +36,12 @@ PGI problems with the nuopc driver - - - FAIL - #227 - - FAIL #273 - - - FAIL - #227 - - FAIL