Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AIRS AMSU-A converter #534

Closed
hkershaw-brown opened this issue Aug 30, 2023 · 1 comment · Fixed by #639
Closed

AIRS AMSU-A converter #534

hkershaw-brown opened this issue Aug 30, 2023 · 1 comment · Fixed by #639
Labels
obs_converters converting observations to DART format

Comments

@hkershaw-brown
Copy link
Member

related to #531 is a two step conversion needed? ( I think not )

There are several bits of the dart documentation that state "HDF5 is incompatible with HDF-EOS"

However, the converters build and link to hdf-eos and to rttov (with and without hdf5). I'm not sure what the incompatibility is.

/glade/p/cisl/dares/libraries/hdf-eos (version 2-3.0)
/glade/p/cisl/dares/rttov13_ifort.no-hdf5 (rttov built without hdf5 support)
/glade/p/cisl/dares/rttov13_ifort

Cheyenne modules:
mkl/2020.0.1
hdf/4.2.15

If you have a netcdf module loaded on Cheyenne anything you compile gets linked with hdf5 if you have the default modules loaded

$ module -t list
ncarenv/1.3
intel/19.1.1
ncarcompilers/0.5.0
mpt/2.25
netcdf/4.8.1

$ ifort --show
ifort   -I/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/include  -Wl,-Bstatic -lnetcdff -lnetcdf -lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 -lsz -lz -Wl,-Bdynamic -lcurl -lm -ldl -lrt -ldl  -Wl,--disable-new-dtags -L/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/lib -Wl,-rpath,/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/lib 

Maybe it is runtime error only? Or at some point there was code that had hdf-eos and hdf5 calls in the same file (I'll check this, but I think you can do that)

hkershaw@cheyenne4:/glade/p/cisl/dares/libraries/hdf/src/hdf-4.2.15/hdf/fortran/examples$ ifort GR_read_image.f -L/glade/p/cisl/dares/libraries/hdf/lib -lmfhdf -ldf -ljpeg -lz -lnetcdf
hkershaw@cheyenne4:/glade/p/cisl/dares/libraries/hdf/src/hdf-4.2.15/hdf/fortran/examples$ readelf -d a.out | head -20

Dynamic section at offset 0x12ad00 contains 35 entries:
  Tag        Type                         Name/Value
 0x0000000000000001 (NEEDED)             Shared library: [libjpeg.so.62]
 0x0000000000000001 (NEEDED)             Shared library: [libsz.so.2]
 0x0000000000000001 (NEEDED)             Shared library: [libz.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libcurl.so.4]
 0x0000000000000001 (NEEDED)             Shared library: [libm.so.6]
 0x0000000000000001 (NEEDED)             Shared library: [libdl.so.2]
 0x0000000000000001 (NEEDED)             Shared library: [librt.so.1]
 0x0000000000000001 (NEEDED)             Shared library: [libpthread.so.0]
 0x0000000000000001 (NEEDED)             Shared library: [libc.so.6]
 0x0000000000000001 (NEEDED)             Shared library: [libgcc_s.so.1]
 0x000000000000000f (RPATH)              Library rpath: [/glade/u/apps/ch/opt/hdf/4.2.15/intel/19.1.1/lib:/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/lib]
 0x000000000000000c (INIT)               0x403f48
 0x000000000000000d (FINI)               0x4f4f5c
 0x0000000000000019 (INIT_ARRAY)         0x72a900
 0x000000000000001b (INIT_ARRAYSZ)       16 (bytes)
 0x000000000000001a (FINI_ARRAY)         0x72a910
 0x000000000000001c (FINI_ARRAYSZ)       8 (bytes)

hdf5 seems to be the netcdf module with different environment variables on Cheyenne

hkershaw@cheyenne4:/glade/p/cisl/dares/libraries/hdf/src/hdf-4.2.15/hdf/fortran/examples$ module show netcdf
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   /glade/u/apps/ch/modulefiles/default/intel/19.1.1/netcdf/4.8.1.lua:
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
whatis("netcdf v4.8.1")
help([[NetCDF is a set of software libraries and self-describing,
machine-independent data formats that support the creation, access,
and sharing of array-oriented scientific data.

This module loads the serial NetCDF interfaces for C (v4.8.1), Fortran
(v4.5.2), and C++ (v4.3.1).

Software website - http://www.unidata.ucar.edu/software/netcdf/

Built on Tue Nov 23 12:27:41 MST 2021
Modules used:
   ncarenv/1.3  
   intel/19.1.1  
   ncarcompilers/0.5.0
]])
conflict("hdf5","hdf5-mpi","netcdf-mpi","gdal")
prepend_path("PATH","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/bin")
prepend_path("PKG_CONFIG_PATH","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/lib/pkgconfig")
prepend_path("MANPATH","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/share/man")
setenv("NCAR_ROOT_NETCDF","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/")
setenv("NCAR_INC_NETCDF","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/include")
setenv("NCAR_LDFLAGS_NETCDF","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/lib")
setenv("NCAR_LIBS_NETCDF","-Wl,-Bstatic -lnetcdff -lnetcdf -lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 -lsz -lz -Wl,-Bdynamic -lcurl -lm -ldl")
setenv("NETCDF","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/")

hkershaw@cheyenne4:/glade/p/cisl/dares/libraries/hdf/src/hdf-4.2.15/hdf/fortran/examples$ module show hdf5
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
   /glade/u/apps/ch/modulefiles/default/intel/19.1.1/hdf5/1.10.8.lua:
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
whatis("hdf5 v1.10.8")
help([[HDF5 is a unique technology suite that makes possible the management
of extremely large and complex data collections. This module loads the
serial version of the HDF5 library, including Fortran, C, and C++ APIs.

Software website - https://www.hdfgroup.org/solutions/hdf5/

Built on Tue Nov 23 12:27:41 MST 2021
Modules used:
   ncarenv/1.3  
   intel/19.1.1  
   ncarcompilers/0.5.0
]])
conflict("netcdf","netcdf-mpi","hdf5-mpi","gdal")
prepend_path("PATH","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/bin")
prepend_path("PKG_CONFIG_PATH","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/lib/pkgconfig")
prepend_path("MANPATH","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/share/man")
setenv("NCAR_ROOT_HDF5","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/")
setenv("NCAR_INC_HDF5","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/include")
setenv("NCAR_LDFLAGS_HDF5","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/lib")
setenv("NCAR_LIBS_HDF5","-Wl,-Bstatic -lhdf5hl_fortran -lhdf5_hl -lhdf5_fortran -lhdf5 -lsz -lz -Wl,-Bdynamic -lm -ldl")
setenv("HDF5","/glade/u/apps/ch/opt/netcdf/4.8.1/intel/19.1.1/")

Documentation notes

The documentation states:

Be aware that if the RTTOV namelist option use_zeeman = .true. certain metadata must be available in the observation. This is >not fully implemented in the AMSU-A observation converter. For more information, please see GitHub Issue 99 “AIRS AMSUA ?>observation converter … Zeeman coefficients and channels

However it looks like issue #99 was fixed

There is code L1_AMSUA_to_netcdf.f90 which has this:

call error_handler(E_ERR,source,'ROUTINE NOT USABLE.', &
text2='Routine barely started. Needs a lot of work and expect', &
text3='complications with simultaneous HDF4, netCDF, and HDF5.')

There are people using AMSU-A (KOPI, CCMC?) so I'm not sure if the documentation is out of date or if the code has not made it back to the dart repo.

@braczka
Copy link
Contributor

braczka commented Aug 31, 2023

Thanks @hkershaw-brown for looking into this -- I will definitely keep track of this and how it relates to #531. Maybe worth contacting CMCC for more context......

@hkershaw-brown hkershaw-brown added the obs_converters converting observations to DART format label Nov 27, 2023
@hkershaw-brown hkershaw-brown closed this as not planned Won't fix, can't repro, duplicate, stale Nov 27, 2023
@hkershaw-brown hkershaw-brown mentioned this issue Feb 16, 2024
15 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
obs_converters converting observations to DART format
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants