Skip to content

Commit

Permalink
Merge pull request NOAA-EMC#9 from DavidHuber-NOAA/intel2022_dh
Browse files Browse the repository at this point in the history
Update CI version of ncdiag, merge in develop
  • Loading branch information
hu5970 authored Jun 9, 2023
2 parents 5d4cf66 + b601e59 commit 9434673
Show file tree
Hide file tree
Showing 16 changed files with 2,184 additions and 1,130 deletions.
2 changes: 1 addition & 1 deletion ci/spack.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ spack:
- [email protected]
- [email protected]
- [email protected]
- gsi-ncdiag@1.0.0
- gsi-ncdiag@1.1.0
view: true
concretizer:
unify: true
11 changes: 7 additions & 4 deletions src/enkf/controlvec.f90
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ subroutine init_controlvec()
cvars3d(nc3d) = trim(adjustl(var))
clevels(nc3d) = ilev + clevels(nc3d-1)
else
if (nproc .eq. 0) print *,'Error: only ', nlevs, ' and ', nlevs+1,' number of levels is supported in current version, got ',ilev
if (nproc .eq. 0) print *,'Error controlvec: only ', nlevs, ' and ', nlevs+1,' number of levels is supported in current version, got ',ilev
call stop2(503)
endif
enddo
Expand Down Expand Up @@ -212,7 +212,10 @@ subroutine read_control()
! read in whole control vector on i/o procs - keep in memory
! (needed in write_ensemble)
allocate(grdin(npts,ncdim,nbackgrounds,nanals_per_iotask))
allocate(qsat(npts,nlevs,nbackgrounds,nanals_per_iotask))
! if only updating the sfc fields, qsat will not be calculated in readgriddata
! only allocate if needed.
q_ind = getindex(cvars3d, 'q')
if (q_ind > 0) allocate(qsat(npts,nlevs,nbackgrounds,nanals_per_iotask))
if (paranc) then
if (nproc == 0) t1 = mpi_wtime()
call readgriddata_pnc(cvars3d,cvars2d,nc3d,nc2d,clevels,ncdim,nbackgrounds, &
Expand All @@ -225,7 +228,8 @@ subroutine read_control()
fgfileprefixes,fgsfcfileprefixes,reducedgrid,grdin,qsat)
end if
!print *,'min/max qsat',nanal,'=',minval(qsat),maxval(qsat)
if (use_qsatensmean) then
q_ind = getindex(cvars3d, 'q')
if (use_qsatensmean .and. q_ind>0 ) then
allocate(qsatmean(npts,nlevs,nbackgrounds))
allocate(qsat_tmp(npts))
! compute ensemble mean qsat
Expand Down Expand Up @@ -257,7 +261,6 @@ subroutine read_control()
! print *,'min/max qsatmean proc',nproc,'=',&
! minval(qsatmean(:,:,nbackgrounds/2+1)),maxval(qsatmean(:,:,nbackgrounds/2+1))
!endif
q_ind = getindex(cvars3d, 'q')
if (pseudo_rh .and. q_ind > 0) then
if (use_qsatensmean) then
do ne=1,nanals_per_iotask
Expand Down
2 changes: 1 addition & 1 deletion src/enkf/gridinfo_gfs.f90
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ module gridinfo
! supported variable names in anavinfo
character(len=max_varname_length),public, dimension(13) :: vars3d_supported = (/'u ', 'v ', 'tv ', 'q ', 'oz ', 'cw ', 'tsen', 'prse', &
'ql ', 'qi ', 'qr ', 'qs ', 'qg '/)
character(len=max_varname_length),public, dimension(3) :: vars2d_supported = (/'ps ', 'pst', 'sst' /)
character(len=max_varname_length),public, dimension(13) :: vars2d_supported = (/'ps ', 'pst', 'sst', 't2m', 'q2m', 'st1', 'st2', 'st3', 'st4', 'sl1', 'sl2', 'sl3', 'sl4' /)
! supported variable names in anavinfo
contains

Expand Down
Loading

0 comments on commit 9434673

Please sign in to comment.