From 39caeeb73ecdb1a93aeea5d5a2132c727179340d Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Wed, 13 Sep 2023 11:49:02 +0000 Subject: [PATCH 01/14] Upgrade compiler/libraries to Intel 2022/spack-stack #18 --- modulefiles/gsiutils_common.lua | 17 +++++++++-------- modulefiles/gsiutils_hera.gnu.lua | 24 ++++++++++++------------ modulefiles/gsiutils_hera.intel.lua | 24 ++++++++++-------------- 3 files changed, 31 insertions(+), 34 deletions(-) diff --git a/modulefiles/gsiutils_common.lua b/modulefiles/gsiutils_common.lua index ecd3db73..81ffb0cd 100644 --- a/modulefiles/gsiutils_common.lua +++ b/modulefiles/gsiutils_common.lua @@ -2,11 +2,12 @@ help([[ Load common modules to build GSI utilities on all machines ]]) -local netcdf_ver=os.getenv("netcdf_ver") or "4.7.4" +local netcdf_c_ver=os.getenv("netcdf_c_ver") or "4.9.2" +local netcdf_fortran_ver=os.getenv("netcdf_fortran_ver") or "4.6.0" local bufr_ver=os.getenv("bufr_ver") or "11.7.0" local bacio_ver=os.getenv("bacio_ver") or "2.4.1" -local w3emc_ver=os.getenv("w3emc_ver") or "2.9.1" +local w3emc_ver=os.getenv("w3emc_ver") or "2.9.2" local sp_ver=os.getenv("sp_ver") or "2.3.3" local ip_ver=os.getenv("ip_ver") or "3.3.3" local sigio_ver=os.getenv("sigio_ver") or "2.3.2" @@ -14,10 +15,11 @@ local sfcio_ver=os.getenv("sfcio_ver") or "1.4.1" local nemsio_ver=os.getenv("nemsio_ver") or "2.5.2" local wrf_io_ver=os.getenv("wrf_io_ver") or "1.2.0" local ncio_ver=os.getenv("ncio_ver") or "1.1.2" -local crtm_ver=os.getenv("crtm_ver") or "2.3.0" -local ncdiag_ver=os.getenv("ncdiag_ver") or "1.0.0" +local crtm_ver=os.getenv("crtm_ver") or "2.4.0" +local ncdiag_ver=os.getenv("ncdiag_ver") or "1.1.1" -load(pathJoin("netcdf", netcdf_ver)) +load(pathJoin("netcdf-c", netcdf_c_ver)) +load(pathJoin("netcdf-fortran", netcdf_fortran_ver)) load(pathJoin("bufr", bufr_ver)) load(pathJoin("bacio", bacio_ver)) @@ -27,8 +29,7 @@ load(pathJoin("ip", ip_ver)) load(pathJoin("sigio", sigio_ver)) load(pathJoin("sfcio", sfcio_ver)) load(pathJoin("nemsio", nemsio_ver)) -load(pathJoin("wrf_io", wrf_io_ver)) +load(pathJoin("wrf-io", wrf_io_ver)) load(pathJoin("ncio", ncio_ver)) load(pathJoin("crtm", crtm_ver)) -load(pathJoin("ncdiag", ncdiag_ver)) - +load(pathJoin("gsi-ncdiag", ncdiag_ver)) diff --git a/modulefiles/gsiutils_hera.gnu.lua b/modulefiles/gsiutils_hera.gnu.lua index 2b366697..48747834 100644 --- a/modulefiles/gsiutils_hera.gnu.lua +++ b/modulefiles/gsiutils_hera.gnu.lua @@ -1,23 +1,23 @@ help([[ ]]) -prepend_path("MODULEPATH", "/scratch2/NCEPDEV/nwprod/hpc-stack/libs/hpc-stack/modulefiles/stack") +prepend_path("MODULEPATH", "/scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.4.1/envs/unified-env/install/modulefiles/Core") +prepend_path("MODULEPATH", "/scratch1/NCEPDEV/jcsda/jedipara/spack-stack/modulefiles") -local hpc_ver=os.getenv("hpc_ver") or "1.1.0" -local hpc_gnu_ver=os.getenv("hpc_gnu_ver") or "9.2.0" -local hpc_mpich_ver=os.getenv("hpc_mpich_ver") or "3.3.2" -local cmake_ver=os.getenv("cmake_ver") or "3.20.1" -local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" +local stack_python_ver=os.getenv("stack_python_ver") or "3.9.12" +local stack_intel_ver=os.getenv("stack_gcc_ver") or "9.2.0" +local stack_impi_ver=os.getenv("stack_openmpi_ver") or "4.1.5" +local cmake_ver=os.getenv("cmake_ver") or "3.23.1" +local openblas_ver=os.getenv("cmake_ver") or "0.3.19" -load(pathJoin("hpc", hpc_ver)) -load(pathJoin("hpc-gnu", hpc_gnu_ver)) -load(pathJoin("hpc-mpich", hpc_mpich_ver)) +load(pathJoin("stack-gcc", stack_gcc_ver)) +load(pathJoin("stack-openmpi", stack_openmpi_ver)) +load(pathJoin("stack-python", stack_python_ver)) load(pathJoin("cmake", cmake_ver)) load("gsiutils_common") -load(pathJoin("prod_util", prod_util_ver)) - -pushenv("MKLROOT", "/apps/oneapi/mkl/2022.0.2") +load(pathJoin("prod-util", prod_util_ver)) +load(pathJoin("openblas", openblas_ver)) whatis("Description: GSI utilities environment on Hera with GNU Compilers") diff --git a/modulefiles/gsiutils_hera.intel.lua b/modulefiles/gsiutils_hera.intel.lua index 68df0e24..fdd74cb1 100644 --- a/modulefiles/gsiutils_hera.intel.lua +++ b/modulefiles/gsiutils_hera.intel.lua @@ -1,27 +1,23 @@ help([[ ]]) -prepend_path("MODULEPATH", "/scratch2/NCEPDEV/nwprod/hpc-stack/libs/hpc-stack/modulefiles/stack") +prepend_path("MODULEPATH", "/scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.4.1/envs/unified-env/install/modulefiles/Core") +prepend_path("MODULEPATH", "/scratch1/NCEPDEV/jcsda/jedipara/spack-stack/modulefiles") -local hpc_ver=os.getenv("hpc_ver") or "1.1.0" -local hpc_intel_ver=os.getenv("hpc_intel_ver") or "18.0.5.274" -local hpc_impi_ver=os.getenv("hpc_impi_ver") or "2018.0.4" -local cmake_ver=os.getenv("cmake_ver") or "3.20.1" -local anaconda_ver=os.getenv("anaconda_ver") or "2.3.0" +local stack_python_ver=os.getenv("stack_python_ver") or "3.9.12" +local stack_intel_ver=os.getenv("stack_intel_ver") or "2021.5.0" +local stack_impi_ver=os.getenv("stack_impi_ver") or "2021.5.1" +local cmake_ver=os.getenv("cmake_ver") or "3.23.1" local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" -load(pathJoin("hpc", hpc_ver)) -load(pathJoin("hpc-intel", hpc_intel_ver)) -load(pathJoin("hpc-impi", hpc_impi_ver)) +load(pathJoin("stack-intel", stack_intel_ver)) +load(pathJoin("stack-intel-oneapi-mpi", stack_impi_ver)) +load(pathJoin("stack-python", stack_python_ver)) load(pathJoin("cmake", cmake_ver)) -prepend_path("MODULEPATH", "/contrib/anaconda/modulefiles") - -load(pathJoin("anaconda", anaconda_ver)) - load("gsiutils_common") -load(pathJoin("prod_util", prod_util_ver)) +load(pathJoin("prod-util", prod_util_ver)) pushenv("CFLAGS", "-xHOST") pushenv("FFLAGS", "-xHOST") From f7c6b751beb93983bfc52658c6844bf86d27df93 Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Wed, 20 Sep 2023 13:07:39 +0000 Subject: [PATCH 02/14] Updated CI for spack-stack. #18 --- ci/spack.yaml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/ci/spack.yaml b/ci/spack.yaml index d12629c5..7b5aa61e 100644 --- a/ci/spack.yaml +++ b/ci/spack.yaml @@ -7,8 +7,8 @@ spack: all: compiler: [intel, gcc] specs: - - netcdf-c@4.7.4 - - netcdf-fortran@4.5.3 + - netcdf-c@4.9.2 + - netcdf-fortran@4.6.0 - bufr@11.7.0 - bacio@2.4.1 - w3emc@2.9.2 @@ -20,7 +20,7 @@ spack: - wrf-io@1.2.0 - crtm@2.3.0 - ncio@1.1.2 - - gsi-ncdiag@1.0.0 + - gsi-ncdiag@1.1.1 view: true concretizer: unify: true From ae26670a2eb6b7bb4eb56b1e402ceebcbcdf456c Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Wed, 15 Nov 2023 15:56:30 +0000 Subject: [PATCH 03/14] Upgrade to spack-stack/1.5.1. --- ci/spack.yaml | 8 +++---- modulefiles/gsiutils_cheyenne.gnu.lua | 32 ------------------------- modulefiles/gsiutils_cheyenne.intel.lua | 26 -------------------- modulefiles/gsiutils_common.lua | 8 +++---- modulefiles/gsiutils_hera.gnu.lua | 7 +++--- modulefiles/gsiutils_hera.intel.lua | 9 ++++--- modulefiles/gsiutils_hercules.lua | 24 +++++++++++++++++++ modulefiles/gsiutils_jet.lua | 20 ++++++++-------- modulefiles/gsiutils_orion.lua | 18 +++++++------- modulefiles/gsiutils_s4.lua | 22 ++++++++--------- modulefiles/gsiutils_wcoss2.lua | 30 +++++++++++++++++++---- src/netcdf_io/interp_inc.fd/driver.f90 | 4 ++-- 12 files changed, 95 insertions(+), 113 deletions(-) delete mode 100644 modulefiles/gsiutils_cheyenne.gnu.lua delete mode 100644 modulefiles/gsiutils_cheyenne.intel.lua create mode 100644 modulefiles/gsiutils_hercules.lua diff --git a/ci/spack.yaml b/ci/spack.yaml index 7b5aa61e..bf29d263 100644 --- a/ci/spack.yaml +++ b/ci/spack.yaml @@ -11,16 +11,16 @@ spack: - netcdf-fortran@4.6.0 - bufr@11.7.0 - bacio@2.4.1 - - w3emc@2.9.2 + - w3emc@2.10.0 - sp@2.3.3 - - ip@3.3.3 + - ip@4.3.0 - sigio@2.3.2 - sfcio@1.4.1 - - nemsio@2.5.2 + - nemsio@2.5.4 - wrf-io@1.2.0 - crtm@2.3.0 - ncio@1.1.2 - - gsi-ncdiag@1.1.1 + - gsi-ncdiag@1.1.2 view: true concretizer: unify: true diff --git a/modulefiles/gsiutils_cheyenne.gnu.lua b/modulefiles/gsiutils_cheyenne.gnu.lua deleted file mode 100644 index 49628f21..00000000 --- a/modulefiles/gsiutils_cheyenne.gnu.lua +++ /dev/null @@ -1,32 +0,0 @@ -help([[ -]]) - -load("cmake/3.22.0") -load("python/3.7.9") -load("ncarenv/1.3") -load("gnu/10.1.0") -load("mpt/2.22") -load("ncarcompilers/0.5.0") -unload("netcdf") - -prepend_path("MODULEPATH", "/glade/work/epicufsrt/GMTB/tools/gnu/10.1.0/hpc-stack-v1.2.0/modulefiles/stack") - -load("hpc/1.2.0") -load("hpc-gnu/10.1.0") -load("hpc-mpt/2.22") - --- Preload w3nco to work around nemsio "find_dependency(w3nco)" hpc-stack bug -load("w3nco/2.4.1") - -load("gsiutils_common") - -local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" -load(pathJoin("prod_util", prod_util_ver)) - -pushenv("MKLROOT", "/glade/u/apps/opt/intel/2022.1/mkl/latest") - -pushenv("CC", "mpicc") -pushenv("FC", "mpif90") -pushenv("CXX", "mpicxx") - -whatis("Description: GSI utilities environment on Cheyenne with GNU Compilers") diff --git a/modulefiles/gsiutils_cheyenne.intel.lua b/modulefiles/gsiutils_cheyenne.intel.lua deleted file mode 100644 index 4c5e1038..00000000 --- a/modulefiles/gsiutils_cheyenne.intel.lua +++ /dev/null @@ -1,26 +0,0 @@ -help([[ -]]) - -load("cmake/3.22.0") -load("python/3.7.9") -load("ncarenv/1.3") -load("intel/2022.1") -load("mpt/2.25") -load("ncarcompilers/0.5.0") - -prepend_path("MODULEPATH", "/glade/work/epicufsrt/GMTB/tools/intel/2022.1/hpc-stack-v1.2.0_6eb6/modulefiles/stack") - -load("hpc/1.2.0") -load("hpc-intel/2022.1") -load("hpc-mpt/2.25") -load("mkl/2022.1") - -load("gsiutils_common") - -local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" -load(pathJoin("prod_util", prod_util_ver)) - -pushenv("CFLAGS", "-xHOST") -pushenv("FFLAGS", "-xHOST") - -whatis("Description: GSI utilities environment on Cheyenne with Intel Compilers") diff --git a/modulefiles/gsiutils_common.lua b/modulefiles/gsiutils_common.lua index 81ffb0cd..3e8dbccb 100644 --- a/modulefiles/gsiutils_common.lua +++ b/modulefiles/gsiutils_common.lua @@ -7,16 +7,16 @@ local netcdf_fortran_ver=os.getenv("netcdf_fortran_ver") or "4.6.0" local bufr_ver=os.getenv("bufr_ver") or "11.7.0" local bacio_ver=os.getenv("bacio_ver") or "2.4.1" -local w3emc_ver=os.getenv("w3emc_ver") or "2.9.2" +local w3emc_ver=os.getenv("w3emc_ver") or "2.10.0" local sp_ver=os.getenv("sp_ver") or "2.3.3" -local ip_ver=os.getenv("ip_ver") or "3.3.3" +local ip_ver=os.getenv("ip_ver") or "4.3.0" local sigio_ver=os.getenv("sigio_ver") or "2.3.2" local sfcio_ver=os.getenv("sfcio_ver") or "1.4.1" -local nemsio_ver=os.getenv("nemsio_ver") or "2.5.2" +local nemsio_ver=os.getenv("nemsio_ver") or "2.5.4" local wrf_io_ver=os.getenv("wrf_io_ver") or "1.2.0" local ncio_ver=os.getenv("ncio_ver") or "1.1.2" local crtm_ver=os.getenv("crtm_ver") or "2.4.0" -local ncdiag_ver=os.getenv("ncdiag_ver") or "1.1.1" +local ncdiag_ver=os.getenv("ncdiag_ver") or "1.1.2" load(pathJoin("netcdf-c", netcdf_c_ver)) load(pathJoin("netcdf-fortran", netcdf_fortran_ver)) diff --git a/modulefiles/gsiutils_hera.gnu.lua b/modulefiles/gsiutils_hera.gnu.lua index 48747834..d7c1b428 100644 --- a/modulefiles/gsiutils_hera.gnu.lua +++ b/modulefiles/gsiutils_hera.gnu.lua @@ -1,10 +1,9 @@ help([[ ]]) -prepend_path("MODULEPATH", "/scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.4.1/envs/unified-env/install/modulefiles/Core") -prepend_path("MODULEPATH", "/scratch1/NCEPDEV/jcsda/jedipara/spack-stack/modulefiles") +prepend_path("MODULEPATH", "/scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") -local stack_python_ver=os.getenv("stack_python_ver") or "3.9.12" +local python_ver=os.getenv("python_ver") or "3.10.8" local stack_intel_ver=os.getenv("stack_gcc_ver") or "9.2.0" local stack_impi_ver=os.getenv("stack_openmpi_ver") or "4.1.5" local cmake_ver=os.getenv("cmake_ver") or "3.23.1" @@ -12,7 +11,7 @@ local openblas_ver=os.getenv("cmake_ver") or "0.3.19" load(pathJoin("stack-gcc", stack_gcc_ver)) load(pathJoin("stack-openmpi", stack_openmpi_ver)) -load(pathJoin("stack-python", stack_python_ver)) +load(pathJoin("python", python_ver)) load(pathJoin("cmake", cmake_ver)) load("gsiutils_common") diff --git a/modulefiles/gsiutils_hera.intel.lua b/modulefiles/gsiutils_hera.intel.lua index fdd74cb1..52824554 100644 --- a/modulefiles/gsiutils_hera.intel.lua +++ b/modulefiles/gsiutils_hera.intel.lua @@ -1,10 +1,9 @@ help([[ ]]) -prepend_path("MODULEPATH", "/scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.4.1/envs/unified-env/install/modulefiles/Core") -prepend_path("MODULEPATH", "/scratch1/NCEPDEV/jcsda/jedipara/spack-stack/modulefiles") +prepend_path("MODULEPATH", "/scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") -local stack_python_ver=os.getenv("stack_python_ver") or "3.9.12" +local python_ver=os.getenv("python_ver") or "3.10.8" local stack_intel_ver=os.getenv("stack_intel_ver") or "2021.5.0" local stack_impi_ver=os.getenv("stack_impi_ver") or "2021.5.1" local cmake_ver=os.getenv("cmake_ver") or "3.23.1" @@ -12,12 +11,12 @@ local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" load(pathJoin("stack-intel", stack_intel_ver)) load(pathJoin("stack-intel-oneapi-mpi", stack_impi_ver)) -load(pathJoin("stack-python", stack_python_ver)) +load(pathJoin("python", python_ver)) load(pathJoin("cmake", cmake_ver)) load("gsiutils_common") -load(pathJoin("prod-util", prod_util_ver)) +load(pathJoin("prod_util", prod_util_ver)) pushenv("CFLAGS", "-xHOST") pushenv("FFLAGS", "-xHOST") diff --git a/modulefiles/gsiutils_hercules.lua b/modulefiles/gsiutils_hercules.lua new file mode 100644 index 00000000..4132c3c0 --- /dev/null +++ b/modulefiles/gsiutils_hercules.lua @@ -0,0 +1,24 @@ +help([[ +]]) + +prepend_path("MODULEPATH", "/work/noaa/epic/role-epic/spack-stack/hercules/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") + +local python_ver=os.getenv("python_ver") or "3.10.8" +local stack_intel_ver=os.getenv("stack_intel_ver") or "2021.9.0" +local stack_impi_ver=os.getenv("stack_impi_ver") or "2021.9.0" +local cmake_ver=os.getenv("cmake_ver") or "3.23.1" +local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" + +load(pathJoin("stack-intel", stack_intel_ver)) +load(pathJoin("stack-intel-oneapi-mpi", stack_impi_ver)) +load(pathJoin("python", python_ver)) +load(pathJoin("cmake", cmake_ver)) + +load("gsiutils_common") + +load(pathJoin("prod_util", prod_util_ver)) + +pushenv("CFLAGS", "-xHOST") +pushenv("FFLAGS", "-xHOST") + +whatis("Description: GSI utilities environment on Orion with Intel Compilers") diff --git a/modulefiles/gsiutils_jet.lua b/modulefiles/gsiutils_jet.lua index febb8e04..fe9b6ed1 100644 --- a/modulefiles/gsiutils_jet.lua +++ b/modulefiles/gsiutils_jet.lua @@ -1,21 +1,21 @@ help([[ ]]) -load("cmake/3.20.1") +prepend_path("MODULEPATH", "/mnt/lfs4/HFIP/hfv3gfs/role.epic/spack-stack/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") -prepend_path("MODULEPATH", "/contrib/anaconda/modulefiles") - -load("anaconda/5.3.1") - -prepend_path("MODULEPATH", "/lfs4/HFIP/hfv3gfs/nwprod/hpc-stack/libs/modulefiles/stack") +local python_ver=os.getenv("python_ver") or "3.10.8" +local stack_intel_ver=os.getenv("stack_intel_ver") or "2021.5.0" +local stack_impi_ver=os.getenv("stack_impi_ver") or "2021.5.1" +local cmake_ver=os.getenv("cmake_ver") or "3.23.1" +local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" -load("hpc/1.1.0") -load("hpc-intel/18.0.5.274") -load("hpc-impi/2018.4.274") +load(pathJoin("stack-intel", stack_intel_ver)) +load(pathJoin("stack-intel-oneapi-mpi", stack_impi_ver)) +load(pathJoin("python", python_ver)) +load(pathJoin("cmake", cmake_ver)) load("gsiutils_common") -local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" load(pathJoin("prod_util", prod_util_ver)) pushenv("CFLAGS", "-axSSE4.2,AVX,CORE-AVX2") diff --git a/modulefiles/gsiutils_orion.lua b/modulefiles/gsiutils_orion.lua index 95426149..adc7e37f 100644 --- a/modulefiles/gsiutils_orion.lua +++ b/modulefiles/gsiutils_orion.lua @@ -1,20 +1,18 @@ help([[ ]]) -prepend_path("MODULEPATH", "/apps/contrib/NCEP/libs/hpc-stack/modulefiles/stack") +prepend_path("MODULEPATH", "/work/noaa/epic/role-epic/spack-stack/orion/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") -local hpc_ver=os.getenv("hpc_ver") or "1.1.0" -local hpc_intel_ver=os.getenv("hpc_intel_ver") or "2018.4" -local hpc_impi_ver=os.getenv("hpc_impi_ver") or "2018.4" -local cmake_ver=os.getenv("cmake_ver") or "3.22.1" -local python_ver=os.getenv("python_ver") or "3.7.5" +local stack_python_ver=os.getenv("python_ver") or "3.10.8" +local stack_intel_ver=os.getenv("stack_intel_ver") or "2022.0.2" +local stack_impi_ver=os.getenv("stack_impi_ver") or "2021.5.1" +local cmake_ver=os.getenv("cmake_ver") or "3.23.1" local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" -load(pathJoin("hpc", hpc_ver)) -load(pathJoin("hpc-intel", hpc_intel_ver)) -load(pathJoin("hpc-impi", hpc_impi_ver)) +load(pathJoin("stack-intel", stack_intel_ver)) +load(pathJoin("stack-intel-oneapi-mpi", stack_impi_ver)) +load(pathJoin("python", stack_python_ver)) load(pathJoin("cmake", cmake_ver)) -load(pathJoin("python", python_ver)) load("gsiutils_common") diff --git a/modulefiles/gsiutils_s4.lua b/modulefiles/gsiutils_s4.lua index 1316a511..937ba754 100644 --- a/modulefiles/gsiutils_s4.lua +++ b/modulefiles/gsiutils_s4.lua @@ -1,20 +1,18 @@ help([[ ]]) -local hpc_ver=os.getenv("hpc_ver") or "1.1.0" -local hpc_intel_ver=os.getenv("hpc_intel_ver") or "18.0.4" -local hpc_impi_ver=os.getenv("hpc_impi_ver") or "18.0.4" -local miniconda_ver=os.getenv("miniconda_ver") or "3.8-s4" -local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" - -prepend_path("MODULEPATH", "/data/prod/hpc-stack/modulefiles/stack") +prepend_path("MODULEPATH", "/data/prod/jedi/spack-stack/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") -load("license_intel/S4") -load(pathJoin("hpc", hpc_ver)) -load(pathJoin("hpc-intel", hpc_intel_ver)) -load(pathJoin("hpc-impi", hpc_impi_ver)) +local python_ver=os.getenv("python_ver") or "3.10.8" +local stack_intel_ver=os.getenv("stack_intel_ver") or "2021.5.0" +local stack_impi_ver=os.getenv("stack_impi_ver") or "2021.5.0" +local cmake_ver=os.getenv("cmake_ver") or "3.23.1" +local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" -load(pathJoin("miniconda", miniconda_ver)) +load(pathJoin("stack-intel", stack_intel_ver)) +load(pathJoin("stack-intel-oneapi-mpi", stack_impi_ver)) +load(pathJoin("python", python_ver)) +load(pathJoin("cmake", cmake_ver)) load("gsiutils_common") diff --git a/modulefiles/gsiutils_wcoss2.lua b/modulefiles/gsiutils_wcoss2.lua index 515405fc..41a0149a 100644 --- a/modulefiles/gsiutils_wcoss2.lua +++ b/modulefiles/gsiutils_wcoss2.lua @@ -7,6 +7,19 @@ local craype_ver=os.getenv("craype_ver") or "2.7.8" local cray_mpich_ver=os.getenv("cray_mpich_ver") or "8.1.7" local cmake_ver= os.getenv("cmake_ver") or "3.20.2" local python_ver=os.getenv("python_ver") or "3.8.6" + +local netcdf_ver=os.getenv("netcdf_ver") or "4.7.4" + +local bufr_ver=os.getenv("bufr_ver") or "11.7.0" +local bacio_ver=os.getenv("bacio_ver") or "2.4.1" +local w3emc_ver=os.getenv("w3emc_ver") or "2.9.1" +local sp_ver=os.getenv("sp_ver") or "2.3.3" +local ip_ver=os.getenv("ip_ver") or "3.3.3" +local sigio_ver=os.getenv("sigio_ver") or "2.3.2" +local sfcio_ver=os.getenv("sfcio_ver") or "1.4.1" +local nemsio_ver=os.getenv("nemsio_ver") or "2.5.2" +local wrf_io_ver=os.getenv("wrf_io_ver") or "1.2.0" +local crtm_ver=os.getenv("crtm_ver") or "2.3.0" local prod_util_ver=os.getenv("prod_util_ver") or "2.0.10" load(pathJoin("PrgEnv-intel", PrgEnv_intel_ver)) @@ -16,11 +29,20 @@ load(pathJoin("cray-mpich", cray_mpich_ver)) load(pathJoin("cmake", cmake_ver)) load(pathJoin("python", python_ver)) -load(pathJoin("prod_util", prod_util_ver)) +load(pathJoin("netcdf", netcdf_ver)) -load("gsiutils_common") -unload("ncio") -unload("ncdiag") +load(pathJoin("bufr", bufr_ver)) +load(pathJoin("bacio", bacio_ver)) +load(pathJoin("w3emc", w3emc_ver)) +load(pathJoin("sp", sp_ver)) +load(pathJoin("ip", ip_ver)) +load(pathJoin("sigio", sigio_ver)) +load(pathJoin("sfcio", sfcio_ver)) +load(pathJoin("nemsio", nemsio_ver)) +load(pathJoin("wrf_io", wrf_io_ver)) +load(pathJoin("crtm", crtm_ver)) + +load(pathJoin("prod_util", prod_util_ver)) pushenv("HPC_OPT", "/apps/ops/para/libs") prepend_path("MODULEPATH", "/apps/ops/para/libs/modulefiles/compiler/intel/19.1.3.304") diff --git a/src/netcdf_io/interp_inc.fd/driver.f90 b/src/netcdf_io/interp_inc.fd/driver.f90 index cb45066e..03a563fe 100644 --- a/src/netcdf_io/interp_inc.fd/driver.f90 +++ b/src/netcdf_io/interp_inc.fd/driver.f90 @@ -24,14 +24,14 @@ program interp_inc use netcdf use mpi + use ip_mod, only: ipolates, ipolatev implicit none integer, parameter :: num_recs = 9 ! Declare externals - external :: w3tagb, netcdf_err, splat, ipolatev, & - ipolates, w3tage + external :: w3tagb, netcdf_err, splat, w3tage character(len=128) :: outfile, infile character(len=11) :: records(num_recs) From b84c95062eeb09936e1d6b5295fe81a7cf657da1 Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Mon, 20 Nov 2023 15:13:49 +0000 Subject: [PATCH 04/14] Test for ip v4+ for new ipolates interface. #18 --- src/netcdf_io/interp_inc.fd/CMakeLists.txt | 7 ++++++- src/netcdf_io/interp_inc.fd/{driver.f90 => driver.F90} | 5 +++++ 2 files changed, 11 insertions(+), 1 deletion(-) rename src/netcdf_io/interp_inc.fd/{driver.f90 => driver.F90} (99%) diff --git a/src/netcdf_io/interp_inc.fd/CMakeLists.txt b/src/netcdf_io/interp_inc.fd/CMakeLists.txt index 1c2d5af1..634495eb 100644 --- a/src/netcdf_io/interp_inc.fd/CMakeLists.txt +++ b/src/netcdf_io/interp_inc.fd/CMakeLists.txt @@ -4,13 +4,18 @@ elseif(CMAKE_Fortran_COMPILER_ID MATCHES "^(GNU)$") set(CMAKE_Fortran_FLAGS "${CMAKE_Fortran_FLAGS} -fconvert=big-endian -ffree-line-length-0 -ffast-math -fno-second-underscore -frecord-marker=4") endif() -add_executable(interp_inc.x driver.f90) +add_executable(interp_inc.x driver.F90) target_link_libraries(interp_inc.x PRIVATE NetCDF::NetCDF_Fortran) target_link_libraries(interp_inc.x PRIVATE MPI::MPI_Fortran) target_link_libraries(interp_inc.x PRIVATE w3emc::w3emc_d) target_link_libraries(interp_inc.x PRIVATE ip::ip_d) target_link_libraries(interp_inc.x PRIVATE sp::sp_d) +if(ip_VERSION VERSION_GREATER_EQUAL 4.0.0) + message("setting ip_v4") + target_compile_definitions(interp_inc.x PRIVATE "IP_V4") +endif() + # Install executable targets install(TARGETS interp_inc.x RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) diff --git a/src/netcdf_io/interp_inc.fd/driver.f90 b/src/netcdf_io/interp_inc.fd/driver.F90 similarity index 99% rename from src/netcdf_io/interp_inc.fd/driver.f90 rename to src/netcdf_io/interp_inc.fd/driver.F90 index 03a563fe..d009816a 100644 --- a/src/netcdf_io/interp_inc.fd/driver.f90 +++ b/src/netcdf_io/interp_inc.fd/driver.F90 @@ -24,7 +24,9 @@ program interp_inc use netcdf use mpi +#ifdef IP_V4 use ip_mod, only: ipolates, ipolatev +#endif implicit none @@ -32,6 +34,9 @@ program interp_inc ! Declare externals external :: w3tagb, netcdf_err, splat, w3tage +#ifndef IP_V4 + external :: ipolates, ipolatev +#endif character(len=128) :: outfile, infile character(len=11) :: records(num_recs) From 0cfedf6e12e90ecd0de2bd37becea98def6e33fc Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Mon, 20 Nov 2023 15:43:24 +0000 Subject: [PATCH 05/14] Remove Hercules module file. --- modulefiles/gsiutils_hercules.lua | 24 ------------------------ 1 file changed, 24 deletions(-) delete mode 100644 modulefiles/gsiutils_hercules.lua diff --git a/modulefiles/gsiutils_hercules.lua b/modulefiles/gsiutils_hercules.lua deleted file mode 100644 index 4132c3c0..00000000 --- a/modulefiles/gsiutils_hercules.lua +++ /dev/null @@ -1,24 +0,0 @@ -help([[ -]]) - -prepend_path("MODULEPATH", "/work/noaa/epic/role-epic/spack-stack/hercules/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") - -local python_ver=os.getenv("python_ver") or "3.10.8" -local stack_intel_ver=os.getenv("stack_intel_ver") or "2021.9.0" -local stack_impi_ver=os.getenv("stack_impi_ver") or "2021.9.0" -local cmake_ver=os.getenv("cmake_ver") or "3.23.1" -local prod_util_ver=os.getenv("prod_util_ver") or "1.2.2" - -load(pathJoin("stack-intel", stack_intel_ver)) -load(pathJoin("stack-intel-oneapi-mpi", stack_impi_ver)) -load(pathJoin("python", python_ver)) -load(pathJoin("cmake", cmake_ver)) - -load("gsiutils_common") - -load(pathJoin("prod_util", prod_util_ver)) - -pushenv("CFLAGS", "-xHOST") -pushenv("FFLAGS", "-xHOST") - -whatis("Description: GSI utilities environment on Orion with Intel Compilers") From 5d3a3f91d20cea43b9688ead9fb577873ae0aac7 Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Mon, 20 Nov 2023 15:47:02 +0000 Subject: [PATCH 06/14] Fix Hera GNU modulefile. Remove debug message. #18 --- modulefiles/gsiutils_hera.gnu.lua | 4 +++- src/netcdf_io/interp_inc.fd/CMakeLists.txt | 1 - 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/modulefiles/gsiutils_hera.gnu.lua b/modulefiles/gsiutils_hera.gnu.lua index d7c1b428..9c9186a5 100644 --- a/modulefiles/gsiutils_hera.gnu.lua +++ b/modulefiles/gsiutils_hera.gnu.lua @@ -2,6 +2,8 @@ help([[ ]]) prepend_path("MODULEPATH", "/scratch1/NCEPDEV/nems/role.epic/spack-stack/spack-stack-1.5.1/envs/gsi-addon/install/modulefiles/Core") +--Needed for openmpi build +prepend_path("MODULEPATH", "/scratch1/NCEPDEV/jcsda/jedipara/spack-stack/modulefiles") local python_ver=os.getenv("python_ver") or "3.10.8" local stack_intel_ver=os.getenv("stack_gcc_ver") or "9.2.0" @@ -16,7 +18,7 @@ load(pathJoin("cmake", cmake_ver)) load("gsiutils_common") -load(pathJoin("prod-util", prod_util_ver)) +load(pathJoin("prod_util", prod_util_ver)) load(pathJoin("openblas", openblas_ver)) whatis("Description: GSI utilities environment on Hera with GNU Compilers") diff --git a/src/netcdf_io/interp_inc.fd/CMakeLists.txt b/src/netcdf_io/interp_inc.fd/CMakeLists.txt index 634495eb..7a91d8d9 100644 --- a/src/netcdf_io/interp_inc.fd/CMakeLists.txt +++ b/src/netcdf_io/interp_inc.fd/CMakeLists.txt @@ -12,7 +12,6 @@ target_link_libraries(interp_inc.x PRIVATE ip::ip_d) target_link_libraries(interp_inc.x PRIVATE sp::sp_d) if(ip_VERSION VERSION_GREATER_EQUAL 4.0.0) - message("setting ip_v4") target_compile_definitions(interp_inc.x PRIVATE "IP_V4") endif() From f62c7f3f8e2e458066e487f3f48e54d0d73e12e2 Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Mon, 20 Nov 2023 15:50:52 +0000 Subject: [PATCH 07/14] Update cache version. --- .github/workflows/intel.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/intel.yml b/.github/workflows/intel.yml index 1df68389..332ca4c8 100644 --- a/.github/workflows/intel.yml +++ b/.github/workflows/intel.yml @@ -9,7 +9,7 @@ defaults: # Set I_MPI_CC/F90 so Intel MPI wrapper uses icc/ifort instead of gcc/gfortran env: - cache_key: intel5 # The number (#) following the cache_key "intel" is to flush Action cache. + cache_key: intel6 # The number (#) following the cache_key "intel" is to flush Action cache. CC: icc FC: ifort CXX: icpc From eae3149488868804290b5ebbce4a86ce58bdee8f Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Tue, 21 Nov 2023 19:01:22 +0000 Subject: [PATCH 08/14] Update CI workflows. --- .github/workflows/gcc.yml | 44 +++++++++++++++++----------------- .github/workflows/intel.yml | 48 ++++++++++++++++++------------------- ci/spack.yaml | 2 +- 3 files changed, 47 insertions(+), 47 deletions(-) diff --git a/.github/workflows/gcc.yml b/.github/workflows/gcc.yml index 374c22fe..080cfea2 100644 --- a/.github/workflows/gcc.yml +++ b/.github/workflows/gcc.yml @@ -8,7 +8,7 @@ defaults: shell: bash -leo pipefail {0} env: - cache_key: gcc4 # The number (#) following the cache_key "gcc" is to flush Action cache. + cache_key: gcc CC: gcc-10 FC: gfortran-10 CXX: g++-10 @@ -24,30 +24,29 @@ env: # The jobs are split into: # 1. a dependency build step (setup), and -# 2. a GSI-utils build step (build) +# 2. a GSI-utils build step (gsi-utils) # The setup is run once and the environment is cached, -# so each build of GSI-utils can reuse the cached dependencies to save time (and compute). +# so each subsequent build of GSI-utils can reuse the cached dependencies to save time (and compute). jobs: setup: runs-on: ubuntu-latest steps: + - name: checkout # This is for getting spack.yaml + uses: actions/checkout@v3 + with: + path: gsi-utils + # Cache spack, compiler and dependencies - name: cache-env id: cache-env - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: | spack ~/.spack - key: spack-${{ runner.os }}-${{ env.cache_key }} - - - name: checkout-gsiutils # This is for getting spack.yaml - if: steps.cache-env.outputs.cache-hit != 'true' - uses: actions/checkout@v2 - with: - path: GSI-utils + key: spack-${{ runner.os }}-${{ env.cache_key }}-${{ hashFiles('gsi-utils/ci/spack.yaml') }} # Install dependencies using Spack - name: install-dependencies-with-spack @@ -55,40 +54,41 @@ jobs: run: | git clone -c feature.manyFiles=true https://github.com/JCSDA/spack.git source spack/share/spack/setup-env.sh - spack env create gsiutils-env GSI-utils/ci/spack.yaml + spack env create gsiutils-env gsi-utils/ci/spack.yaml spack env activate gsiutils-env - spack compiler find + sudo apt install cmake spack external find spack add mpich@3.4.2 spack concretize - spack install -v --fail-fast + spack install -v --fail-fast --dirty + spack clean --all - build: + gsi-monitor: needs: setup runs-on: ubuntu-latest steps: - - name: checkout-gsiutils - uses: actions/checkout@v2 + - name: checkout + uses: actions/checkout@v3 with: - path: GSI-utils + path: gsi-utils - name: cache-env id: cache-env - uses: actions/cache@v2 + uses: actions/cache@v3 with: path: | spack ~/.spack - key: spack-${{ runner.os }}-${{ env.cache_key }} + key: spack-${{ runner.os }}-${{ env.cache_key }}-${{ hashFiles('gsi-utils/ci/spack.yaml') }} - - name: build-gsiutils + - name: build run: | source spack/share/spack/setup-env.sh spack env activate gsiutils-env export CC=mpicc export FC=mpif90 - cd GSI-utils + cd gsi-utils mkdir -p build && cd build cmake -DCMAKE_INSTALL_PREFIX=../install -DBUILD_UTIL_ALL=ON .. make -j2 VERBOSE=1 diff --git a/.github/workflows/intel.yml b/.github/workflows/intel.yml index 332ca4c8..eb0fe127 100644 --- a/.github/workflows/intel.yml +++ b/.github/workflows/intel.yml @@ -9,7 +9,7 @@ defaults: # Set I_MPI_CC/F90 so Intel MPI wrapper uses icc/ifort instead of gcc/gfortran env: - cache_key: intel6 # The number (#) following the cache_key "intel" is to flush Action cache. + cache_key: intel CC: icc FC: ifort CXX: icpc @@ -27,15 +27,20 @@ env: # The jobs are split into: # 1. a dependency build step (setup), and -# 2. a GSI-utils build step (build) +# 2. a GSI-utils build step (gsi-utils) # The setup is run once and the environment is cached, -# so each build of GSI-utils can reuse the cached dependencies to save time (and compute). +# so each subsequent build of gsi-utils can reuse the cached dependencies to save time (and compute). jobs: setup: - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 steps: + - name: checkout # This is for getting spack.yaml + uses: actions/checkout@v3 + with: + path: gsi-utils + # Cache spack, compiler and dependencies - name: cache-env id: cache-env @@ -45,53 +50,48 @@ jobs: spack ~/.spack /opt/intel - key: spack-${{ runner.os }}-${{ env.cache_key }} + key: spack-${{ runner.os }}-${{ env.cache_key }}-${{ hashFiles('gsi-utils/ci/spack.yaml') }} - name: install-intel-compilers - if: steps.cache-env.outputs.cache-hit != 'true' run: | wget https://apt.repos.intel.com/intel-gpg-keys/GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB sudo apt-key add GPG-PUB-KEY-INTEL-SW-PRODUCTS.PUB echo "deb https://apt.repos.intel.com/oneapi all main" | sudo tee /etc/apt/sources.list.d/oneAPI.list sudo apt-get update - sudo apt-get install intel-oneapi-dev-utilities intel-oneapi-mpi-devel intel-oneapi-openmp intel-oneapi-compiler-fortran intel-oneapi-compiler-dpcpp-cpp-and-cpp-classic + sudo apt-get install intel-oneapi-dev-utilities intel-oneapi-mpi-devel intel-oneapi-openmp intel-oneapi-compiler-fortran-2023.2.1 intel-oneapi-compiler-dpcpp-cpp-and-cpp-classic-2023.2.1 echo "source /opt/intel/oneapi/setvars.sh" >> ~/.bash_profile - - name: checkout-gsiutils # This is for getting spack.yaml - if: steps.cache-env.outputs.cache-hit != 'true' - uses: actions/checkout@v2 - with: - path: GSI-utils - # Install dependencies using Spack - name: install-dependencies-with-spack if: steps.cache-env.outputs.cache-hit != 'true' run: | git clone -c feature.manyFiles=true https://github.com/JCSDA/spack.git source spack/share/spack/setup-env.sh - spack env create gsiutils-env GSI-utils/ci/spack.yaml + spack env create gsiutils-env gsi-utils/ci/spack.yaml spack env activate gsiutils-env sudo mv /usr/local/ /usr/local_mv spack compiler find + sudo apt install cmake spack external find spack add intel-oneapi-mpi spack concretize spack install --dirty --fail-fast -v + spack clean --all - build: + gsi-utils: needs: setup - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 steps: - - name: checkout-gsiutils - uses: actions/checkout@v2 - with: - path: GSI-utils - - name: install-intel run: | echo "source /opt/intel/oneapi/setvars.sh" >> ~/.bash_profile + - name: checkout-gsiutils + uses: actions/checkout@v3 + with: + path: gsi-utils + - name: cache-env id: cache-env uses: actions/cache@v3 @@ -100,15 +100,15 @@ jobs: spack ~/.spack /opt/intel - key: spack-${{ runner.os }}-${{ env.cache_key }} + key: spack-${{ runner.os }}-${{ env.cache_key }}-${{ hashFile('gsi-utils/ci/spack.yaml') }} - - name: build-gsiutils + - name: build run: | source spack/share/spack/setup-env.sh spack env activate gsiutils-env export CC=mpiicc export FC=mpiifort - cd GSI-utils + cd gsi-utils mkdir -p build && cd build cmake -DCMAKE_INSTALL_PREFIX=../install -DBUILD_UTIL_ALL=ON .. make -j2 VERBOSE=1 diff --git a/ci/spack.yaml b/ci/spack.yaml index bf29d263..d71c3539 100644 --- a/ci/spack.yaml +++ b/ci/spack.yaml @@ -5,7 +5,7 @@ spack: packages: all: - compiler: [intel, gcc] + compiler: [intel, gcc@10:10] specs: - netcdf-c@4.9.2 - netcdf-fortran@4.6.0 From 9f56d3cc797120f9468eb719bdd9d2ccde6439e6 Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Tue, 21 Nov 2023 19:05:33 +0000 Subject: [PATCH 09/14] Fix CI yml files. --- .github/workflows/gcc.yml | 2 +- .github/workflows/intel.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/gcc.yml b/.github/workflows/gcc.yml index 080cfea2..8f709545 100644 --- a/.github/workflows/gcc.yml +++ b/.github/workflows/gcc.yml @@ -63,7 +63,7 @@ jobs: spack install -v --fail-fast --dirty spack clean --all - gsi-monitor: + gsi-monitor: needs: setup runs-on: ubuntu-latest diff --git a/.github/workflows/intel.yml b/.github/workflows/intel.yml index eb0fe127..c596e060 100644 --- a/.github/workflows/intel.yml +++ b/.github/workflows/intel.yml @@ -100,7 +100,7 @@ jobs: spack ~/.spack /opt/intel - key: spack-${{ runner.os }}-${{ env.cache_key }}-${{ hashFile('gsi-utils/ci/spack.yaml') }} + key: spack-${{ runner.os }}-${{ env.cache_key }}-${{ hashFiles('gsi-utils/ci/spack.yaml') }} - name: build run: | From 08494f823516cdbb74210423b8395e09fd839a49 Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Tue, 21 Nov 2023 19:13:52 +0000 Subject: [PATCH 10/14] Upgrade crtm to 2.4.0 in CI to match spack-stack. --- ci/spack.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ci/spack.yaml b/ci/spack.yaml index d71c3539..e2a7fa38 100644 --- a/ci/spack.yaml +++ b/ci/spack.yaml @@ -18,7 +18,7 @@ spack: - sfcio@1.4.1 - nemsio@2.5.4 - wrf-io@1.2.0 - - crtm@2.3.0 + - crtm@2.4.0 - ncio@1.1.2 - gsi-ncdiag@1.1.2 view: true From 3dc15b32e436f0889406e9bb1fbb51b346840b34 Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Tue, 21 Nov 2023 19:45:34 +0000 Subject: [PATCH 11/14] Revert to ubuntu-latest for Intel. --- .github/workflows/intel.yml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/intel.yml b/.github/workflows/intel.yml index c596e060..b8b51ff6 100644 --- a/.github/workflows/intel.yml +++ b/.github/workflows/intel.yml @@ -33,7 +33,7 @@ env: jobs: setup: - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - name: checkout # This is for getting spack.yaml @@ -69,7 +69,6 @@ jobs: source spack/share/spack/setup-env.sh spack env create gsiutils-env gsi-utils/ci/spack.yaml spack env activate gsiutils-env - sudo mv /usr/local/ /usr/local_mv spack compiler find sudo apt install cmake spack external find @@ -80,7 +79,7 @@ jobs: gsi-utils: needs: setup - runs-on: ubuntu-20.04 + runs-on: ubuntu-latest steps: - name: install-intel From fc13aea4c0476c7ef7e7e6106c864dd108e799da Mon Sep 17 00:00:00 2001 From: DavidHuber Date: Tue, 21 Nov 2023 21:15:48 +0000 Subject: [PATCH 12/14] Set cmake in spack.yaml. --- .github/workflows/gcc.yml | 1 - .github/workflows/intel.yml | 5 ++--- ci/spack.yaml | 1 + 3 files changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/gcc.yml b/.github/workflows/gcc.yml index 8f709545..e3bb0118 100644 --- a/.github/workflows/gcc.yml +++ b/.github/workflows/gcc.yml @@ -56,7 +56,6 @@ jobs: source spack/share/spack/setup-env.sh spack env create gsiutils-env gsi-utils/ci/spack.yaml spack env activate gsiutils-env - sudo apt install cmake spack external find spack add mpich@3.4.2 spack concretize diff --git a/.github/workflows/intel.yml b/.github/workflows/intel.yml index b8b51ff6..6a607196 100644 --- a/.github/workflows/intel.yml +++ b/.github/workflows/intel.yml @@ -33,7 +33,7 @@ env: jobs: setup: - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 steps: - name: checkout # This is for getting spack.yaml @@ -70,7 +70,6 @@ jobs: spack env create gsiutils-env gsi-utils/ci/spack.yaml spack env activate gsiutils-env spack compiler find - sudo apt install cmake spack external find spack add intel-oneapi-mpi spack concretize @@ -79,7 +78,7 @@ jobs: gsi-utils: needs: setup - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 steps: - name: install-intel diff --git a/ci/spack.yaml b/ci/spack.yaml index e2a7fa38..c79c3268 100644 --- a/ci/spack.yaml +++ b/ci/spack.yaml @@ -21,6 +21,7 @@ spack: - crtm@2.4.0 - ncio@1.1.2 - gsi-ncdiag@1.1.2 + - cmake@3.20.1 view: true concretizer: unify: true From 3cc02d3907c4f307155a1f94a37ddd77d1685952 Mon Sep 17 00:00:00 2001 From: Innocent Souopgui Date: Wed, 29 Nov 2023 19:40:52 +0000 Subject: [PATCH 13/14] Remove parallel opening in the nf90_open, parallel access is not used --- src/netcdf_io/interp_inc.fd/driver.F90 | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/netcdf_io/interp_inc.fd/driver.F90 b/src/netcdf_io/interp_inc.fd/driver.F90 index d009816a..584069a6 100644 --- a/src/netcdf_io/interp_inc.fd/driver.F90 +++ b/src/netcdf_io/interp_inc.fd/driver.F90 @@ -250,8 +250,12 @@ program interp_inc if (mype == npes-1) print*,'- OPEN INPUT FILE: ', trim(infile) - error = nf90_open(trim(infile), ior(nf90_nowrite, nf90_mpiio), & - comm=mpi_comm_world, info = mpi_info_null, ncid=ncid_in) + ! Opening for parallel access breaks gfsanalcalc & gdasanalcalc on S4 + ! Also there is no parallel access, so there is no need to open for parallel + ! access. By Innocent. + !error = nf90_open(trim(infile), ior(nf90_nowrite, nf90_mpiio), & + ! comm=mpi_comm_world, info = mpi_info_null, ncid=ncid_in) + error = nf90_open(trim(infile), ior(nf90_nowrite, nf90_mpiio), ncid=ncid_in) call netcdf_err(error, 'opening file='//trim(infile) ) error = nf90_inq_dimid(ncid_in, 'lon', id_dim) From 6ba12c1ddfb341e84843f634308c85d8fe6927c7 Mon Sep 17 00:00:00 2001 From: Innocent Souopgui Date: Wed, 29 Nov 2023 20:01:58 +0000 Subject: [PATCH 14/14] document the change in the code --- src/netcdf_io/interp_inc.fd/driver.F90 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/netcdf_io/interp_inc.fd/driver.F90 b/src/netcdf_io/interp_inc.fd/driver.F90 index 584069a6..722b5dde 100644 --- a/src/netcdf_io/interp_inc.fd/driver.F90 +++ b/src/netcdf_io/interp_inc.fd/driver.F90 @@ -250,9 +250,9 @@ program interp_inc if (mype == npes-1) print*,'- OPEN INPUT FILE: ', trim(infile) - ! Opening for parallel access breaks gfsanalcalc & gdasanalcalc on S4 + ! Opening for parallel access breaks global workflow on S4 ! Also there is no parallel access, so there is no need to open for parallel - ! access. By Innocent. + ! access. !error = nf90_open(trim(infile), ior(nf90_nowrite, nf90_mpiio), & ! comm=mpi_comm_world, info = mpi_info_null, ncid=ncid_in) error = nf90_open(trim(infile), ior(nf90_nowrite, nf90_mpiio), ncid=ncid_in)