Skip to content

Provides functionality for interacting with, reading, writing, and manipulating GRIB2 files.

Notifications You must be signed in to change notification settings

AlysonStahl-NOAA/wgrib2

 
 

Repository files navigation

WGRIB 2

Provides functionality for interacting with, reading, writing, and manipulating grib2 files, with a CMake build.

See wgrib2 documentation here.

See also the develop branch doxygen build.

This release of the wgrib2 package, with CMake build capability, is part of the NCEPLIBS project.

Users

Wgrib2 is used by the following projects:

  • NOMADS uses wgrib2 in grib_filter (a wrapper for wgrib2) wgrib2 is used to create the *.idx files for random access.
  • global-workflow, including post-processing and downstream products. Downstream jobs use wgrib2 to regrid GRIB2 files and extract variables. The new ocean/ice components will use wgrib2 to convert netCDF files to GRIB2 files.
  • Ensemble Verification System(EVS), for processing GRIB2 files.
  • Rapid Refresh Forecast System (RRFS).
  • The Climate Prediction Center (CPC) uses wgrib2 extensively to process GRIB2 files in their real-time applications.
  • The MET/METplus software uses wgrib2 to extract information from GRIB2 files.
  • The Global Forecast System (GFS) post-processing of the atmosphere component has been using wgrib2 to interplate the UPP output master files in Gaussian grid into pgrb2/pgrb2b files in lat-lon grid.
  • Wgrib2 is the suggested regridding tool for GRIB2 by UPP.
  • pywgrib2_s and pywgrib2_xy call wgrib2.
  • RNomads is an R module that can get grib files from nomads.ncep.noaa.gov and read them. RNomads will run in windows and linux, and the code uses wgrib2.
  • wgrib2 is included in anaconda, redhat and other repositories.
  • GrADS uses wgrib2 to create control files. Also used to create ctl files for the grads dods server.

Authors

Wesley Ebisuzaki, Reinoud Bokhorst, John Howard, Jaakko Hyvätti, Dusan Jovic, Daniel Lee, Kristian Nilssen, Karl Pfeiffer, Pablo Romero, Manfred Schwarb, Gregor Schee, Arlindo da Silva, Niklas Sondell, Sam Trahan, George Trojan, Sergey Varlamov

CMake Build and testing: Kyle Gerheiser, Alyson Stahl, Edward Hartnett, Alex Richert

Installing

Building wgrib2 requires, CMake, a C compiler, a Fortran compiler (optional), and various 3rd party libraries depending on build configuration.

The CMake build provided here supports most build options (NetCDF, PNG, Jasper, spectral, and ipolates), but not certain features such as MySQL.

mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=install -DCMAKE_PREFIX_PATH=path/to/dependencies
make
make install

Using the wgrib2 library

To use the wgrib2 library the CMake build offers a package config.

After running find_package(wgrib2) CMake will generate the following targets for use in your project:

wgrib2::wgrib2_lib (c library)
wgrib2::wgrib2_api (fortran target)

References

Wesley Ebisuzaki 20170214 EMC seminar on wgrib2api.

Disclaimer

The United States Department of Commerce (DOC) GitHub project code is provided on an "as is" basis and the user assumes responsibility for its use. DOC has relinquished control of the information and no longer has responsibility to protect the integrity, confidentiality, or availability of the information. Any claims against the Department of Commerce stemming from the use of its GitHub project will be governed by all applicable Federal law. Any reference to specific commercial products, processes, or services by service mark, trademark, manufacturer, or otherwise, does not constitute or imply their endorsement, recommendation or favoring by the Department of Commerce. The Department of Commerce seal and logo, or the seal and logo of a DOC bureau, shall not be used in any manner to imply endorsement of any commercial product or activity by DOC or the United States Government.

About

Provides functionality for interacting with, reading, writing, and manipulating GRIB2 files.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C 90.8%
  • Shell 3.2%
  • PostScript 2.3%
  • CMake 1.5%
  • Fortran 1.4%
  • Python 0.4%
  • Other 0.4%