Skip to content

Commit

Permalink
chgres_cube - Remove the wgrib2 library from the GRIB2 data read rout…
Browse files Browse the repository at this point in the history
…ines.

Update routines "read_input_atm_grib2_file", "read_input_sfc_grib2_file", "read_winds" and "read_grib_soil"
to read input GRIB2 files using G2LIB instead of WGRIB2.

Update routine "define_input_grid_gfs_grib2" to flip the pole of GFS GRIB2 data. WGRIB2 and 
G2LIB use different conventions for defining global gaussian grids.

Update to G2LIB v3.4.3 or higher, which eliminated occasional segmentation faults and slow wall 
clock times.

Add new units test for GRIB2 read routines "read_input_atm_grib2_file" and "read_input_sfc_grib2_file".

Part of #591.
  • Loading branch information
GeorgeGayno-NOAA authored Mar 22, 2022
1 parent 570ea39 commit 4fdee55
Show file tree
Hide file tree
Showing 18 changed files with 2,277 additions and 958 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ find_package(nemsio 2.5.0 REQUIRED)
find_package(sigio 2.3.0 REQUIRED)
find_package(sp 2.3.3 REQUIRED)
find_package(ip 3.3.3 REQUIRED)
find_package(g2 3.4.0 REQUIRED)
find_package(g2 3.4.3 REQUIRED)
find_package(wgrib2 2.0.8 REQUIRED)
find_package(sigio 2.3.0 REQUIRED)

Expand Down
2 changes: 1 addition & 1 deletion modulefiles/build.hera.gnu.lua
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ load(pathJoin("esmf", esmf_ver))
bacio_ver=os.getenv("bacio_ver") or "2.4.1"
load(pathJoin("bacio", bacio_ver))

g2_ver=os.getenv("g2_ver") or "3.4.1"
g2_ver=os.getenv("g2_ver") or "3.4.3"
load(pathJoin("g2", g2_ver))

ip_ver=os.getenv("ip_ver") or "3.3.3"
Expand Down
2 changes: 1 addition & 1 deletion modulefiles/build.hera.intel.lua
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ load(pathJoin("hpc-impi", impi_ver))
bacio_ver=os.getenv("bacio_ver") or "2.4.1"
load(pathJoin("bacio", bacio_ver))

g2_ver=os.getenv("g2_ver") or "3.4.1"
g2_ver=os.getenv("g2_ver") or "3.4.3"
load(pathJoin("g2", g2_ver))

ip_ver=os.getenv("ip_ver") or "3.3.3"
Expand Down
2 changes: 1 addition & 1 deletion modulefiles/build.jet.intel.lua
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ load(pathJoin("sfcio", sfcio_ver))
nemsio_ver=os.getenv("nemsio_ver") or "2.5.2"
load(pathJoin("nemsio", nemsio_ver))

g2_ver=os.getenv("g2_ver") or "3.4.1"
g2_ver=os.getenv("g2_ver") or "3.4.3"
load(pathJoin("g2", g2_ver))

wgrib2_ver=os.getenv("wgrib2_ver") or "2.0.8"
Expand Down
2 changes: 1 addition & 1 deletion modulefiles/build.orion.intel.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ load(pathJoin("hpc-impi", impi_ver))
bacio_ver=os.getenv("bacio_ver") or "2.4.1"
load(pathJoin("bacio", bacio_ver))

g2_ver=os.getenv("g2_ver") or "3.4.1"
g2_ver=os.getenv("g2_ver") or "3.4.3"
load(pathJoin("g2", g2_ver))

ip_ver=os.getenv("ip_ver") or "3.3.3"
Expand Down
5 changes: 4 additions & 1 deletion modulefiles/build.wcoss_cray.intel
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ module load cray-hdf5/1.8.14

module use /usrx/local/nceplibs/NCEPLIBS/cmake/install/NCEPLIBS-v1.3.0/modules
module load bacio/2.4.1
module load g2/3.4.1
module load ip/3.3.3
module load nemsio/2.5.2
module load sp/2.3.3
Expand All @@ -31,7 +30,11 @@ setenv ZLIB_ROOT /usrx/local/prod/zlib/1.2.7/intel/haswell
setenv PNG_ROOT /usrx/local/prod/png/1.2.49/intel/haswell
setenv Jasper_ROOT /usrx/local/prod/jasper/1.900.1/intel/haswell

module use /usrx/local/nceplibs/NCEPLIBS/cmake/install/NCEPLIBS-v1.4.0/modules
module load g2/3.4.5

module load esmf/820

setenv NETCDF /opt/cray/netcdf/4.3.3.1/INTEL/14.0
module rm gcc
module load gcc/6.3.0
2 changes: 1 addition & 1 deletion modulefiles/build.wcoss_dell_p3.intel.lua
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ load(pathJoin("esmf", esmf_ver))
bacio_ver=os.getenv("bacio_ver") or "2.4.1"
load(pathJoin("bacio", bacio_ver))

g2_ver=os.getenv("g2_ver") or "3.4.2"
g2_ver=os.getenv("g2_ver") or "3.4.5"
load(pathJoin("g2", g2_ver))

ip_ver=os.getenv("ip_ver") or "3.3.3"
Expand Down
4 changes: 2 additions & 2 deletions reg_tests/chgres_cube/driver.wcoss_dell_p3.sh
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ bsub -e $LOG_FILE -o $LOG_FILE -q $QUEUE -P $PROJECT_CODE -J chgres01 -W 0:05 -x

LOG_FILE=consistency.log02
export OMP_NUM_THREADS=1
bsub -e $LOG_FILE -o $LOG_FILE -q $QUEUE -P $PROJECT_CODE -J chgres02 -W 0:07 -x -n 6 \
bsub -e $LOG_FILE -o $LOG_FILE -q $QUEUE -P $PROJECT_CODE -J chgres02 -W 0:10 -x -n 6 \
-R "span[ptile=6]" -R "affinity[core(${OMP_NUM_THREADS}):distribute=balance]" "$PWD/3km.conus.hrrr.gfssdf.grib2.sh"

#-----------------------------------------------------------------------------
Expand All @@ -103,7 +103,7 @@ bsub -e $LOG_FILE -o $LOG_FILE -q $QUEUE -P $PROJECT_CODE -J chgres04 -W 0:05 -x

LOG_FILE=consistency.log05
export OMP_NUM_THREADS=1
bsub -e $LOG_FILE -o $LOG_FILE -q $QUEUE -P $PROJECT_CODE -J chgres05 -W 0:05 -x -n 6 \
bsub -e $LOG_FILE -o $LOG_FILE -q $QUEUE -P $PROJECT_CODE -J chgres05 -W 0:10 -x -n 6 \
-R "span[ptile=6]" -R "affinity[core(${OMP_NUM_THREADS}):distribute=balance]" "$PWD/13km.conus.rap.grib2.sh"

#-----------------------------------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions sorc/chgres_cube.fd/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ target_include_directories(chgres_cube_lib INTERFACE ${mod_dir})
target_link_libraries(
chgres_cube_lib
PUBLIC
g2::g2_d
nemsio::nemsio
sfcio::sfcio
sigio::sigio
Expand Down
Loading

0 comments on commit 4fdee55

Please sign in to comment.