{"id":34692,"date":"2019-10-08T13:40:51","date_gmt":"2019-10-08T13:40:51","guid":{"rendered":"http:\/\/cimss.ssec.wisc.edu\/satellite-blog\/?p=34692"},"modified":"2021-11-17T16:24:10","modified_gmt":"2021-11-17T16:24:10","slug":"displaying-nucaps-values-at-one-horizontal-level-using-polar2grid","status":"publish","type":"post","link":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/archives\/34692","title":{"rendered":"Displaying NUCAPS values at one horizontal level using Polar2Grid"},"content":{"rendered":"<div id=\"attachment_34704\" style=\"width: 610px\" class=\"wp-caption aligncenter\"><a href=\"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-content\/uploads\/sites\/5\/2019\/10\/npp_nucaps_Temperature_707mb_20190920_062135_wgs84_fit.annotate.toggle.gif\"><img loading=\"lazy\" decoding=\"async\" aria-describedby=\"caption-attachment-34704\" class=\"wp-image-34704\" src=\"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-content\/uploads\/sites\/5\/2019\/10\/npp_nucaps_Temperature_707mb_20190920_062135_wgs84_fit.annotate.toggle.gif\" alt=\"\" width=\"600\" height=\"781\"><\/a><p id=\"caption-attachment-34704\" class=\"wp-caption-text\">Temperature at 707 hPa at 0621 UTC on 20 September 2019, from NUCAPS profiles (Click to enlarge)<\/p><\/div>\n<p>&nbsp;<\/p>\n<p>NOAA-Unique Combined Atmospheric Processing System (<a href=\"https:\/\/www.ospo.noaa.gov\/Products\/atmosphere\/soundings\/nucaps\/\">NUCAPS<\/a>) vertical profiles provide useful information derived from data from CrIS and ATMS instruments on board both Suomi-NPP and NOAA-20.&nbsp; Infrared Sounder information from CrIS gives profiles in clear\/partly cloud regions, and ATMS supplies information in regions that are uniformly cloudy.&nbsp; (Click <a href=\"https:\/\/www.youtube.com\/watch?v=8uVmSWlRrfk\">here<\/a> for more information on NUCAPS profiles in AWIPS (profiles are also available <a href=\"https:\/\/www.ospo.noaa.gov\/Products\/atmosphere\/soundings\/nucaps\/pskewt\/WORLD.html\">here<\/a>) ;&nbsp; there are also CIMSS Blog entries on NUCAPS vertical profiles at <a href=\"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/archives\/category\/nucaps\">this link<\/a>, and at <a href=\"http:\/\/goesrhwt.blogspot.com\/search\/label\/NUCAPS\">this link<\/a> from the Hazardous Weather Testbed).<\/p>\n<p><a href=\"https:\/\/www.ssec.wisc.edu\/software\/polar2grid\/\">Polar2Grid<\/a> is a Python-based data reader\/converter designed as part of the <a href=\"https:\/\/cimss.ssec.wisc.edu\/cspp\/\">Community Satellite Processing Package (CSPP)<\/a> for Direct Broadcast data (such as found <a href=\"ftp:\/\/ftp.ssec.wisc.edu\/pub\/eosdb\/\">at this site<\/a>);&nbsp; it also works with data downloaded from <a href=\"https:\/\/www.bou.class.noaa.gov\/saa\/products\/welcome\">NOAA CLASS<\/a>.<\/p>\n<p>NUCAPS vertical profiles can be used to create horizontal fields using data from pressure levels at each sounding location &#8212; each sounding generates values at the same levels that are present in the radiative transfer model used in retrieval that creates data (including levels at 852.78, 706.57, 496.6, 300 mb).&nbsp; Polar2Grid can read these levels, but will not interpolate in the vertical (separate processing could be created for that).<\/p>\n<p>The data that is downloaded (you might have to untar the data) from NOAA CLASS (choose &#8220;JPSS Sounder Products (JPSS_SND)&#8221; in the drop-down menu) will include file names that look something like this:<\/p>\n<blockquote>\n<p>NUCAPS-EDR_v2r0_npp_s201909200622390_e201909200623090_c201909200758180.nc<\/p>\n<\/blockquote>\n<p>The file above refers to an Environmental Data Record (EDR) from Suomi NPP (npp is in the filename;&nbsp; if these data were from NOAA-20, &#8216;j01&#8217; would be there instead);&nbsp; the files contains data from 20 September 2019, starting at 0622 and ending at 0623 UTC.&nbsp; You might also see files with v1r0 &#8212; this flag distinguishes between NUCAPS 3 (v1r0) and NUCAPS 4.3 (v2r0).&nbsp; Polar2Grid will read both.<\/p>\n<p>After ordering and downloading the data from NOAA CLASS, and downloading and installing the Polar2Grid data, use polar2grid to create a field (in this case, using multiple EDRs between 0620 and 0650 UTC that have been downloaded into the \/data-hdd\/NUCAPSFromCLASS\/ directory:<\/p>\n<blockquote>\n<p>$POLAR2GRID_HOME\/bin\/polar2grid.sh nucaps gtiff -p Temperature_707mb &#8211;grid-coverage 0 -vvv -f \/data-hdd\/NUCAPSFromCLASS\/NUCAPS-EDR_v2r0_npp_s2019092006*.nc &#8211;rescale-configs Temperature.ini &#8211;distance-upper-bound 200<\/p>\n<\/blockquote>\n<p>$POLAR2GRID_HOME has been defined using the unix export function, and it tells the package into which directory Polar2Grid was installed.&nbsp; &#8216;nucaps gtiff&#8217; tells the software that it will be reading nucaps data and outputting a geotiff file.&nbsp; The &#8216;-p&#8217; flag controls which product is being created, in this case Temperature at 707 mb &#8212; the integer value closest to the 706.57 mb level in the Radiative Transfer Model (the valid pressure values can be determined by inspecting the netCDF file and finding &#8220;Pressure&#8221; values).&nbsp; (Other variables that can be displayed are listed at <a href=\"https:\/\/www.ssec.wisc.edu\/software\/polar2grid\/readers\/nucaps.html\">this website).<\/a> The &#8216;-f&#8217; flag directs the software to the directory holding the downloaded data; &#8211;distance-upper-bound 200 controls how far a data point extends its influence.&nbsp; By default Polar2Grid will automatically rescale fields based on the data&#8217;s maximum\/minimum.&nbsp; To control this, create a file such as Temperature.ini, and include &#8211;rescale-configs flag.&nbsp; The Temperature.ini file used&nbsp; is below:<\/p>\n<blockquote>\n<p>[rescale:temperature]<br>\ndata_kind=air_temperature<br>\nmethod=linear<br>\nmin_in=200.0<br>\nmax_in=320.0<\/p>\n<\/blockquote>\n<p>The output of the polar2grid invocation above will be a geotiff file: npp_nucaps_Temperature_707mb_20190920_062135_wgs84_fit.tif ;&nbsp; note that the time\/day are contained within the filename, as well as the satellite, parameter and level.<\/p>\n<p>Colormaps can be applied to the geotiffs with the add_colormaps.sh script:<\/p>\n<blockquote>\n<p>$POLAR2GRID_HOME\/bin\/add_colormap.sh $POLAR2GRID_HOME\/colormaps\/T200_320.cmap npp_nucaps_Temperature_707mb_20190920_062135_wgs84_fit.tif<\/p>\n<\/blockquote>\n<p>This will overwrite the greyscale tif file with a color-enhanced image controlled by the specified color map.&nbsp; In this case, I created a colormap that spans from 200 to 320 K, the wide range of data allowed in the Temperature.ini file.&nbsp; That cmap is shown below.<\/p>\n<blockquote>\n<p>#0,128,0,127,255<br>\n# This is a cmap for temperatures from 200 to 320 K<br>\n0,0,0,0,0<br>\n1,75,0,130,255<br>\n# 75,0,130 is deep indigo &#8212; at the cold end<br>\n85,0,5,75,255<br>\n# 85 is at about 240 K &#8212; 1\/3rd of the way from 200-320, 1\/3rd of the way from 0-255<br>\n# 0,5,75 is a deep blue<br>\n129,0,200,200,255<br>\n# 129 is half-ish way from 1-255, so 260 K<br>\n# 0,200,200 is darkish cyan<br>\n# 140 is at about 265, 0, 150, 0 is a darkish green<br>\n140,0,150,0,255<br>\n# 155 is about 273, 255, 255, 0 is yellow<br>\n155,255,255,0,255<br>\n# 166 is about 278, 5K, 255,15,15 is red<br>\n166,255,15,15,255<br>\n# 176 is about 283 K, 255,182,193 is pink<br>\n176,255,182,193,255<br>\n# 186 is about 288 K, white<br>\n186,255,255,255,255<br>\n# 255 is at 320 K &#8212; slide from white at 288 K to grey at 320 K<br>\n255,127,127,127,255<\/p>\n<\/blockquote>\n<p>Finally, apply a map to the tif file using the &#8216;add_coastlines.sh&#8217; script.&nbsp; I usually move the color-enhanced tif file into the $POLAR2GRID_HOME\/bin directory to do this, and for this case executed this command:<\/p>\n<blockquote>\n<p>$POLAR2GRID_HOME\/bin\/add_coastlines.sh npp_nucaps_Temperature_707mb_20190920_062135_wgs84_fit.tif &#8211;coastlines-resolution=f &#8211;coastlines-level=6 &#8211;coastlines-outline=&#8217;magenta&#8217; &#8211;add-coastlines &#8211;add-grid &#8211;add-borders &#8211;borders-level 1 &#8211;borders-resolution h<\/p>\n<\/blockquote>\n<p>This will create a .png file.&nbsp; I&#8217;ve done this with two 707-mb temperature fields, with different &#8211;distance-upper-bound values:&nbsp; 200, and 100, as indicated.&nbsp; They are toggling together at the top of this blog post.<\/p>\n<p>Polar2Grid v 2.3 (coming soon!) will allow the inclusion of a colorbar in the imagery.&nbsp; Polar2Grid documentation can be found <a href=\"https:\/\/www.ssec.wisc.edu\/software\/polar2grid\/introduction.html\">here<\/a>.<\/p>\n<p>&nbsp;<\/p>\n\n\n<hr class=\"wp-block-separator\" \/>\n\n\n\n<p><p>Update:  November 2021.<\/p><\/p>\n\n\n\n<hr class=\"wp-block-separator\" \/>\n\n\n\n<p>Polar2Grid v 3.0 is slated to be released in late 2021\/early 2022.  Some features discussed above have been deprecated in the latest version.  A new blog post will be forthcoming once the new version is released.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp; NOAA-Unique Combined Atmospheric Processing System (NUCAPS) vertical profiles provide useful information derived from data from CrIS and ATMS instruments on board both Suomi-NPP and NOAA-20.&nbsp; Infrared Sounder information from CrIS gives profiles in clear\/partly cloud regions, and ATMS supplies information in regions that are uniformly cloudy.&nbsp; (Click here for more information on NUCAPS profiles [&hellip;]<\/p>\n","protected":false},"author":19,"featured_media":34705,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[83,39],"tags":[],"class_list":["post-34692","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-nucaps","category-training"],"acf":[],"_links":{"self":[{"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/posts\/34692","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/users\/19"}],"replies":[{"embeddable":true,"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/comments?post=34692"}],"version-history":[{"count":13,"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/posts\/34692\/revisions"}],"predecessor-version":[{"id":43302,"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/posts\/34692\/revisions\/43302"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/media\/34705"}],"wp:attachment":[{"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/media?parent=34692"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/categories?post=34692"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/cimss.ssec.wisc.edu\/satellite-blog\/wp-json\/wp\/v2\/tags?post=34692"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}