Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 0 additions & 35 deletions utilities/conv_gefs2datm/0readme

This file was deleted.

32 changes: 32 additions & 0 deletions utilities/conv_gefs2datm/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
# How to use conv_gefs2datm


## Input data (GEFS) sources

At HPSS : `/3year/NCEPDEV/GEFSRR/gefsrr_replay_${YYYYstream}stream/${YYYYMMDDHH}.tar`
At WCOSS : `(venus)/gpfs/dell2/emc/modeling/noscrub/Hyun-Chul.Lee/GEFS/Reanal`

## Output data (DATM) archive
At HPSS : `/5year/NCEPDEV/marineda/DATM_INPUT/GEFS/${YYYYMM}/gefs.${YYYYMMDDHH}.nc`
At Hera : `/scratch2/NCEPDEV/marineda/godas_input/DATM_INPUT/GEFS/${YYYYMM}/gefs.${YYYYMMDDHH}.nc`

## To conver from GEFS to DATM (netCDF),

1) Compile the code
`csh ./comp_f77_code.csh conv_gefs2datm`

2) Modify the run script of conv_gefs2datm.fort.csh
`set sdir = !<-- source of GEFS
set tdir = !<-- output dir
set wdir = !<-- work dir `

Define the starting and ending date at YYYYMMDD format
`set symd = 20130529 !<-- start date`
`set eymd = 20190831 !<-- end date`

3) Run the script
`csh ./conv_gefs2datm.fort.csh`

## More information can be found

https://docs.google.com/spreadsheets/d/1M32BvPgXuPqewQWO5cwsECLdcTj9o1x2Rq7GDvSpltk/edit#gid=0
11 changes: 6 additions & 5 deletions utilities/conv_gefs2datm/comp_f77_code.csh
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
#! /bin/csh
module load intel/18.0.5.274
module load impi/2019.0.4
module load netcdf/4.6.1
module load intel
module load netcdf

set name = $1
#--- in hera
ifort -132 $FFLAGS ${name}.f -o ${name} -I$NETCDF/include -L$NETCDF/lib -lnetcdff
#--- in hera
set FFLAGS='-extend-source 132'

ifort $FFLAGS ${name}.f -o ${name} -I$NETCDF/include -L$NETCDF/lib -lnetcdf
1 change: 0 additions & 1 deletion utilities/conv_gefs2datm/conv_gefs2datm.f
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ program conv_gefs2datm
integer NX,NY,NT,nerr,NDIM,i,j,k,NSTR
parameter (NX = 1536, NY = 768, NT = 1, NDIM = 3)
real*4 :: latitude(NY), longitude(NX)
C integer time(NT),NF_64BIT_OFFSET,vi_indx
integer time(NT),vi_indx
real coef,Tcel,Hn,term1,term2,g0,Rsp
real, dimension(NX,NY,NT) ::
Expand Down
12 changes: 6 additions & 6 deletions utilities/conv_gefs2datm/conv_gefs2datm.fort.csh
Original file line number Diff line number Diff line change
@@ -1,16 +1,17 @@
#! /bin/csh -x

module load netcdf/4.6.1
module load intel
module load netcdf

set hdir = #<-- set home dir
set sdir = #<-- set input source dir
set tdir = #<-- set dir for output
set wdir = #<-- set work dir

#<-- set intial date
#<-- set intial date YYYYMMDD
set symd = 20130529
#<-- set end date
set eymd = 20190831
#<-- set end date YYYYMMDD
set eymd = 20190831

cd $wdir

Expand All @@ -31,5 +32,4 @@ ncdump gefs_output.nc | sed -e "5s#^.time = 1 ;#time = UNLIMITED ; // (1 current
rm gefs_input.*
end
set ymd = `date -d "${ymd} 1 day" +%Y%m%d`
end

end