Skip Navigation Links www.nws.noaa.gov 
NOAA logo - Click to go to the NOAA home page National Weather Service   NWS logo - Click to go to the NWS home page
Climate Prediction Center
 
 

 
About Us
   Our Mission
   Who We Are

Contact Us
   CPC Information
   CPC Web Team

 
HOME > Monitoring_and_Data > Oceanic and Atmospheric Data > Reanalysis: Atmospheric Data > wgrib2-set_bitmap
 

wgrib2: -set_bitmap

Introduction

Complex packed grib files can have undefined grid values stored in the grib files as either a bitmap or a special value. You should use the special value method because it results in significantly smaller files. If software is a concern, you should use whatever is compatible with the decoding software. Note: only complex packing allows for using a special value for undefined grid values.

Wgrib2's will store undefined grib values using a special value when using complex packing unless the -set_bitmap 1 option is used. The option -set_grib_type same will not enable the bitmap option.

Software Concerns

NDFD (National Digital Forecast Database) which is produced by NOAA has used complex packing with a special value since the beginning (many years ago). Consequently many decoders will be able to handle special-value undefineds. Many codes will handle bitmaps because bitmaps were used in jpeg2000 packed grib2 files which have been used by NCEP for many years. At least one organization has codes that will not read special-value undefineds.

Usage

-set_bitmap X   X=0, 1   0=do not use bitmap (default) 1=use bitmap
                when packing undefined values with complex packing

Example

$ wgrib2 in.grb -set_bitmap 1 -set_grib_type complex3 -grib_out out.grb 
The above line rewrites a file using complex3 packing and a bitmap. A bitmap is not used if all the grid values are defined.

See also: -grib_out, See also: -set_grib_type,


NOAA/ National Weather Service
National Centers for Environmental Prediction
Climate Prediction Center
5830 University Research Court
College Park, Maryland 20740
Climate Prediction Center Web Team
Page last modified: Jan 14, 2015
Disclaimer Privacy Policy