Skip to content

Commit

Permalink
remove references to EUL dycore from nudging tools
Browse files Browse the repository at this point in the history
  • Loading branch information
brian-eaton committed Jan 22, 2025
1 parent 94564df commit 132a768
Show file tree
Hide file tree
Showing 15 changed files with 43 additions and 131 deletions.
16 changes: 16 additions & 0 deletions doc/ChangeLog
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,22 @@ src/utils/spmd_utils.F90
test/system/TR8.sh
. remove filepaths for eul dycore and advection.

tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/makeIC_Create_field_Master_List.ncl
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/makeIC_ERAI.csh
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/MAKEIC.f90-EXTEND
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/MAKEIC.f90-ORIG
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/makeIC_procedures.ncl
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/MAKEIC.stub
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/makeIC.ncl
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/MAKEIC.f90
tools/nudging/Gen_Data/Gen_Data_FVdycore/Gen_Data_SETNAME_f09/makeIC_extract_analyses_info.ncl
tools/nudging/Gen_Data/Gen_Data_SEdycore/Gen_Data_SETNAME_ne30/makeIC_Create_field_Master_List.ncl
tools/nudging/Gen_Data/Gen_Data_SEdycore/Gen_Data_SETNAME_ne30/makeIC_se_procedures.ncl
tools/nudging/Gen_Data/Gen_Data_SEdycore/Gen_Data_SETNAME_ne30/MAKEIC.stub
tools/nudging/Gen_Data/Gen_Data_SEdycore/Gen_Data_SETNAME_ne30/MAKEIC.f90
tools/nudging/Gen_Data/Gen_Data_SEdycore/Gen_Data_SETNAME_ne30/makeIC_extract_analyses_info.ncl
. remove references to EUL dycore

If there were any failures reported from running test_driver.sh on any test
platform, and checkin with these failures has been OK'd by the gatekeeper,
then copy the lines from the td.*.status files for the failed tests to the
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -571,8 +571,8 @@ subroutine binning(plev ,plato ,plono ,plat ,plon , &
! ! starting at 0 deg and moving
! ! eastward
real*8 gwo (plato) ! Output Gaussian wgts (if relevant grid)
integer dyn_flag ! Dynamics flag of input grid: Eul=1, FV=0
integer dyn_flago ! Dynamics flag of output grid: Eul=1, FV=0
integer dyn_flag ! Dynamics flag of input grid: FV=0
integer dyn_flago ! Dynamics flag of output grid: FV=0
real*8 bin_factor ! bin-box area expansion/contraction factor relative to
! ! output grid-box area.
!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -571,8 +571,8 @@
! ! starting at 0 deg and moving
! ! eastward
real*8 gwo (plato) ! Output Gaussian wgts (if relevant grid)
integer dyn_flag ! Dynamics flag of input grid: Eul=1, FV=0
integer dyn_flago ! Dynamics flag of output grid: Eul=1, FV=0
integer dyn_flag ! Dynamics flag of input grid: FV=0
integer dyn_flago ! Dynamics flag of output grid: FV=0
real*8 bin_factor ! bin-box area expansion/contraction factor relative to
! ! output grid-box area.
!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -571,8 +571,8 @@
! ! starting at 0 deg and moving
! ! eastward
real*8 gwo (plato) ! Output Gaussian wgts (if relevant grid)
integer dyn_flag ! Dynamics flag of input grid: Eul=1, FV=0
integer dyn_flago ! Dynamics flag of output grid: Eul=1, FV=0
integer dyn_flag ! Dynamics flag of input grid: FV=0
integer dyn_flago ! Dynamics flag of output grid: FV=0
real*8 bin_factor ! bin-box area expansion/contraction factor relative to
! ! output grid-box area.
!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@ C ! starting from southern-most lat
C ! starting at 0 deg and moving
C ! eastward
real*8 gwo (plato) ! Output Gaussian wgts (if relevant grid)
integer dyn_flag ! Dynamics flag of input grid: Eul=1, FV=0
integer dyn_flago ! Dynamics flag of output grid: Eul=1, FV=0
integer dyn_flag ! Dynamics flag of input grid: FV=0
integer dyn_flago ! Dynamics flag of output grid: FV=0
real*8 bin_factor ! bin-box area expansion/contraction factor relative to
C ! output grid-box area.
C
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,9 +62,6 @@ begin
adjust_state_from_topo = field@adjust_state_from_topo

mass_fix = False
if(dycore .eq. "eul") then
mass_fix = True
end if

;------------------------
; Define disk directories
Expand Down Expand Up @@ -231,8 +228,8 @@ begin

exit_script = False

if(dycore .ne. "eul" .and. dycore .ne. "fv" .and. dycore .ne. "homme" ) then
print("Error: 'dycore' must be: 'eul', 'fv', or 'homme'")
if(dycore .ne. "fv" .and. dycore .ne. "homme" ) then
print("Error: 'dycore' must be: 'fv', or 'homme'")
print(" 'dycore' is currently: "+dycore)
exit_script = True
end if
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ function Create_field_Master_List(spectral_trunc_setting:integer, field:string )
;********************************************************************************************;
; ;
; Create_field_Master_List ;
; spectral_trunc_setting : integer; Spectral truncation (Eulerian only) ;
; spectral_trunc_setting : integer; Spectral truncation (if Gaussian grid) ;
; "field" is a master variable carrying meta-data needed for file ;
; processing ;
; ;
Expand All @@ -29,7 +29,7 @@ begin
Master_List@dimensions = new( (/field_dim/), string ) ; "2D" or "3D" designation
Master_List@horz_interp = new( (/field_dim/), string ) ; flag to indicate which type of horizontal interpolation to use
Master_List@vert_interp = new( (/field_dim/), string ) ; flag to indicate which type of vertical interpolation to use
Master_List@spec_trunc = new( (/field_dim/), integer) ; Spectral truncation to use (if Eulerian dycore)
Master_List@spec_trunc = new( (/field_dim/), integer) ; Spectral truncation (if Gaussian grid).
Master_List@bin_factor = new( (/field_dim/), double ) ; bin factor to use if horizontal interpolation is "binning"
; (typical value: 1.)
Master_List@loutput = new( (/field_dim/), logical) ; Flag to output field (if False, field is used only for internal processing
Expand All @@ -56,7 +56,7 @@ begin
; Options for horizontal: "no_interp"
; "cubic" ; recommended only for non-tracer species
; "cubic_sp" ; should only be used for tracers and water products like Q, CLDLIQ, CLDICE, CLOUD, etc.
; "spectral" ; only for non-tracer species in the Eulerian dycore
; "spectral" ; only for non-tracer species (if Gaussian grid)
; "binning" ; "conservative remapping" --> recommended for all horizontal interpolations
;
; Options for vertical: "no_interp"
Expand Down Expand Up @@ -733,9 +733,6 @@ begin
print(" Valid post-processing options are: '"+post_process_flags+"'")
exit
end if
if( field@dycore .ne. "eul") then
Master_List@spec_trunc(ifield) = -1
end if
end do

delete(Master_List@_FillValue)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ setenv REF_DATE 20070901
# Output file format

setenv CASE ERAI_f09_L30 # Case name that will be appended to name of output file
setenv DYCORE fv # Dycore ("eul" or "fv" are the current choices)
setenv DYCORE fv # Dycore ("fv" is the only current choice)
setenv PRECISION float # "double" or "float" are the current choices of output precision
setenv PTRM -1 # "M" spectral truncation (for "eul" dycore only; ignored for other dycores; "-1" = no trunc)
setenv PTRN -1 # "N" spectral truncation (for "eul" dycore only; ignored for other dycores; "-1" = no trunc)
setenv PTRK -1 # "K" spectral truncation (for "eul" dycore only; ignored for other dycores; "-1" = no trunc)
setenv PTRM -1 # "M" spectral truncation (for Gaussian grid; "-1" = no trunc)
setenv PTRN -1 # "N" spectral truncation (for Gaussian grid; "-1" = no trunc)
setenv PTRK -1 # "K" spectral truncation (for Gaussian grid; "-1" = no trunc)
setenv PLAT 192 # Number of latitudes on output IC file
setenv PLON 288 # Number of longitudes on output IC file
setenv PLEV 30 # Number of vert levs on output IC file
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ begin

if(ftype .eq. "CAM") then

; Standard CAM Eulerian or FV file
; Standard CAM FV file

file_dim_names = getvardims (data)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2493,7 +2493,7 @@ begin
; extracted
field@horz_interp = new( (/field_dim/), string ) ; flag to indicate which type of horizontal interpolation to use
field@vert_interp = new( (/field_dim/), string ) ; flag to indicate which type of vertical interpolation to use
field@spec_trunc = new( (/field_dim/), integer) ; Spectral truncation to use (if Eulerian dycore)
field@spec_trunc = new( (/field_dim/), integer) ; Spectral truncation to use (if Gaussian grid)
field@bin_factor = new( (/field_dim/), double ) ; bin factor to use if horizontal interpolation is "binning"
; (typical value: 1.)
field@processed = new( (/field_dim/), logical) ; Set to False until field is processed
Expand Down Expand Up @@ -2738,24 +2738,12 @@ begin
;-------------------------

if(field@plevo .gt. 0) then
if(field@dycore .eq. "eul") then
filedimdef(cdf,(/"lat" ,"lon" ,"lev" ,"ilev" ,"time","scalar"/),\
(/field@plato,field@plono,field@plevo,field@plevo+1,1 ,1 /),\
(/False ,False , False , False , True , False /) )
end if

if(field@dycore .eq. "fv") then
filedimdef(cdf,(/"lat" ,"lon" ,"slat" ,"slon" ,"lev" ,"ilev" ,"time","scalar"/),\
(/field@plato,field@plono,field@plato-1,field@plono,field@plevo,field@plevo+1,1 ,1 /),\
(/False ,False ,False ,False , False , False , True , False /) )
end if
else
if(field@dycore .eq. "eul") then
filedimdef(cdf,(/"lat" ,"lon" ,"time","scalar"/),\
(/field@plato,field@plono,1 ,1 /),\
(/False ,False , True , False /) )
end if

if(field@dycore .eq. "fv") then
filedimdef(cdf,(/"lat" ,"lon" ,"slat" ,"slon" ,"time","scalar"/),\
(/field@plato,field@plono,field@plato-1,field@plono,1 ,1 /),\
Expand Down Expand Up @@ -2877,89 +2865,6 @@ begin
; Define dycore-specific parameters and coordinates
;--------------------------------------------------

;---------
; Eulerian
;---------

if(field@dycore .eq. "eul") then

filevardef (cdf,"lat","double",(/"lat"/))
cdf->lat@long_name = "latitude"
cdf->lat@units = "degrees_north"

filevardef (cdf,"lon","double",(/"lon"/))
cdf->lon@long_name = "longitude"
cdf->lon@units = "degrees_east"

filevardef (cdf,"ntrm","integer",(/"scalar"/))
cdf->ntrm@long_name = "spectral truncation parameter M"

filevardef (cdf,"ntrn","integer",(/"scalar"/))
cdf->ntrn@long_name = "spectral truncation parameter N"

filevardef (cdf,"ntrk","integer",(/"scalar"/))
cdf->ntrk@long_name = "spectral truncation parameter K"

filevardef (cdf,"gw","double",(/"lat"/))
cdf->gw@long_name = "gauss weights"

;-----------------------
; Pre-set some variables
;-----------------------

del_lon = (360./field@plono)

cdf->lon = ispan(0,field@plono-1,1)*del_lon
gau_info = gaus(field@plato/2)
cdf->lat = gau_info(:,0)
cdf->gw = gau_info(:,1)

cdf->ntrm = field@ptrmo
cdf->ntrn = field@ptrno
cdf->ntrk = field@ptrko

field@lat = cdf->lat
field@lon = cdf->lon

;---------------------------------------------------
; Define field variables, dimensions, and attributes
;---------------------------------------------------

time_dim = "time"
lev_dim = "lev"
count = 0
do i = 0,nfields-1

if(field@loutput(i)) then
count = count + 1

print (" Declare space for output field: "+field(i)+ \
" (field "+count+" of "+nfields_out+")")

lat_dim = "lat"
lon_dim = "lon"

if(field@dimensions(i) .eq. "2D") then
filevardef (cdf,field(i),field@precision,(/time_dim,lat_dim,lon_dim/))
end if
if(field@dimensions(i) .eq. "3D") then
filevardef (cdf,field(i),field@precision,(/time_dim,lev_dim,lat_dim,lon_dim /))
end if

cdf->$field(i)$@long_name = field@long_name (i)
cdf->$field(i)$@units = field@units (i)
cdf->$field(i)$@source_file = fname(field@source_file (i))
cdf->$field(i)$@source_field_name = field@source_field(i)
cdf->$field(i)$@horz_interp_flag = field@horz_interp (i)
if(field@dimensions(i) .eq. "3D") then
cdf->$field(i)$@vert_interp_flag = field@vert_interp (i)
end if
end if

end do

end if

;---
; FV
;---
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -571,8 +571,8 @@ subroutine binning(plev ,plato ,plono ,plat ,plon , &
! ! starting at 0 deg and moving
! ! eastward
real*8 gwo (plato) ! Output Gaussian wgts (if relevant grid)
integer dyn_flag ! Dynamics flag of input grid: Eul=1, FV=0
integer dyn_flago ! Dynamics flag of output grid: Eul=1, FV=0
integer dyn_flag ! Dynamics flag of input grid: FV=0
integer dyn_flago ! Dynamics flag of output grid: FV=0
real*8 bin_factor ! bin-box area expansion/contraction factor relative to
! ! output grid-box area.
!
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@ C ! starting from southern-most lat
C ! starting at 0 deg and moving
C ! eastward
real*8 gwo (plato) ! Output Gaussian wgts (if relevant grid)
integer dyn_flag ! Dynamics flag of input grid: Eul=1, FV=0
integer dyn_flago ! Dynamics flag of output grid: Eul=1, FV=0
integer dyn_flag ! Dynamics flag of input grid: FV=0
integer dyn_flago ! Dynamics flag of output grid: FV=0
real*8 bin_factor ! bin-box area expansion/contraction factor relative to
C ! output grid-box area.
C
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ function Create_field_Master_List(spectral_trunc_setting:integer, field:string )
;********************************************************************************************;
; ;
; Create_field_Master_List ;
; spectral_trunc_setting : integer; Spectral truncation (Eulerian only) ;
; spectral_trunc_setting : integer; Spectral truncation (Gaussian grid only) ;
; "field" is a master variable carrying meta-data needed for file ;
; processing ;
; ;
Expand All @@ -29,7 +29,7 @@ begin
Master_List@dimensions = new( (/field_dim/), string ) ; "2D" or "3D" designation
Master_List@horz_interp = new( (/field_dim/), string ) ; flag to indicate which type of horizontal interpolation to use
Master_List@vert_interp = new( (/field_dim/), string ) ; flag to indicate which type of vertical interpolation to use
Master_List@spec_trunc = new( (/field_dim/), integer) ; Spectral truncation to use (if Eulerian dycore)
Master_List@spec_trunc = new( (/field_dim/), integer) ; Spectral truncation to use (if Gaussian grid)
Master_List@bin_factor = new( (/field_dim/), double ) ; bin factor to use if horizontal interpolation is "conserve"
; (typical value: 1.)
Master_List@loutput = new( (/field_dim/), logical) ; Flag to output field (if False, field is used only for internal processing
Expand Down Expand Up @@ -746,9 +746,6 @@ begin
print(" Valid post-processing options are: '"+post_process_flags+"'")
exit
end if
if( field@dycore .ne. "eul") then
Master_List@spec_trunc(ifield) = -1
end if
end do

delete(Master_List@_FillValue)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ begin

if(ftype .eq. "CAM") then

; Standard CAM Eulerian or FV file
; Standard CAM FV file

file_dim_names = getvardims (data)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1216,7 +1216,7 @@ begin
; interpolation to use
field@vert_interp =new( (/field_dim/), string ) ; flag to indicate which type of vertical
; interpolation to use
field@spec_trunc =new( (/field_dim/), integer) ; Spectral truncation to use (if Eulerian dycore)
field@spec_trunc =new( (/field_dim/), integer) ; Spectral truncation to use (if Gaussian grid)
field@bin_factor =new( (/field_dim/), double ) ; bin factor to use if horizontal
; interpolation is "binning" (typical value: 1.)
field@processed =new( (/field_dim/), logical) ; Set to False until field is processed
Expand Down

0 comments on commit 132a768

Please sign in to comment.