How-to: Process vertical scans.#

Daniel Sanchez-Rivas1 and Miguel A. Rico-Ramirez1

1Department of Civil Engineering, University of Bristol, Bristol, BS8 1TR, United Kingdom

This notebook describes the process of retrieving, quality-check and processing raw C-band radar data collected by the operational UK Met Office radar network.#

UK Met Office C-band rain radar dual-polarisation products are available at http://catalogue.ceda.ac.uk/uuid/82adec1f896af6169112d09cc1174499 (Met Office, 2003)

Import relevant packages#

import towerpy as tp

# %matplotlib notebook
---------------------------------------------------------------------------
ModuleNotFoundError                       Traceback (most recent call last)
Cell In[1], line 1
----> 1 import towerpy as tp
      3 # %matplotlib notebook

ModuleNotFoundError: No module named 'towerpy'

Define working directory and file name#

For this example, we’ll use data collected at the Chenies radar site; In the file name, augzdr stands for polarimetric data, sp for short-pulse and el8 refers to collected at 89.9° elevation angle.

RSITE = 'chenies'
WDIR = f'../../../datasets/ukmo-nimrod/data/single-site/2020/{RSITE}/spel8/'
FNAME = (f'metoffice-c-band-rain-radar_{RSITE}_202010030726_raw-dual-polar-'
         + 'augzdr-sp-el8.dat')

Use Towerpy to read in the raw radar variables.#

The Rad_scan class initialises a radar object.

Within the ukmo module, the ppi_ukmoraw function provides an interface to read the current binary format used by the MO to store the radar data.

Note that the argument exclude_vars was used to discard the ‘W [m/s]’, ‘SQI [-]’ and ‘CI [dB]’] variables, as they will not be used at this stage.

rdata = tp.io.ukmo.Rad_scan(WDIR+FNAME, RSITE)
rdata.ppi_ukmoraw(exclude_vars=['W [m/s]', 'SQI [-]', 'CI [dB]'])
rdata.ppi_ukmogeoref()

tp.datavis.rad_display.plot_setppi(rdata.georef, rdata.params, rdata.vars)
../_images/3b134923e612de90a2a9b5ad3d9197910c3796a06c180d07c1366859938b5fcd.png

Computation of the Signal-to-Noise-Ratio#

We use the signalnoiseratio function to compute the Signal-to-Noise-Ratio (SNR) (in dB) and discard data using a reference noise value equal to 55 dB. This value had been checked at all the UK Met office radar sites (valid only for short-pulse scans) and proved effective in removing noise within the scans.

The data2correct argument copies the original data and generates a new dictionary containing radar variables but SNR filtered.

rsnr = tp.eclass.snr.SNR_Classif(rdata)
rsnr.signalnoiseratio(rdata.georef, rdata.params, rdata.vars, min_snr=55,
                      data2correct=rdata.vars, plot_method=True)
../_images/243bf72049c2cc9ff152fcab3476db6f8266b2571bee38e26d54e70704900ab2.png

Generation of VPs of polarimetric variables#

We use the pol_vps function to generate vertical profiles of polarimetric variables.

Note that the argument stats is set to True to compute statistics related to the averaging process of the rays to enable a comprehensive analysis of the profiles.

rprofs = tp.profs.polprofs.PolarimetricProfiles(rdata)
rprofs.pol_vps(rdata.georef, rdata.params, rsnr.vars, stats=True)

Use the plot_radprofiles function to view the generated VPs.

tp.datavis.rad_display.plot_radprofiles(rprofs,
                                        rprofs.georef['profiles_height [km]'],
                                        colours=True)
../_images/fc59520e2e0c4b8262b8baaed261887f9c875c752a2075d89761d585f68174eb.png
<Figure size 640x480 with 0 Axes>

ML detection#

Then we will run the method proposed by Sanchez-Rivas, D. and Rico-Ramirez, M. A. (2021) to detect the boundaries of the ML within the VPs.

In the ml_detection function, we set a minimum height for the algorithm to search the ML signatures. The user can modify this and other arguments to fine-tune the algorithm’s performance.

Note that the plot_method argument is set to True. This argument displays an interactive plot that illustrates the steps followed by the ML detection algorithm. As the method computes all the possible combinations of the normalised profiles, it is possible to check each one by moving the slider.

rmlyr = tp.ml.mlyr.MeltingLayer(rprofs)
rmlyr.ml_detection(rprofs, min_h=1.1, comb_id=26, plot_method=True)
../_images/d89faabb932c521a1f19a86a5cdf44251ab5d6d689a3c3060464cb61308fe7c3.png
rmlyr.ml_top
np.float64(2.999995433130607)
rmlyr.ml_thickness
np.float64(0.9749985161215591)
rmlyr.ml_bottom
np.float64(2.024996917009048)

$Z_{DR}$ offset detection#

The offsetdetection_vps function adapts the method proposed by Gorgucci, E., et al. (1999) to detect the $Z_{DR}$ offset.

The mlyr is required to separate between liquid and solid precipitation. Whereas the min_h and other arguments help adjust the algorithm’s performance.

rcalzdr = tp.calib.calib_zdr.ZDR_Calibration(rdata)
rcalzdr.offsetdetection_vps(pol_profs=rprofs, mlyr=rmlyr, min_h=1.1,
                            rad_georef=rdata.georef, rad_params=rdata.params,
                            rad_vars=rsnr.vars, plot_method=True)
../_images/d3aa7787bd58929bd7b54355f60de0450383d5e69e2854a840e8a2aeadeef4cd.png
rcalzdr.zdr_offset
np.float64(-0.26271701388888885)

$\Phi_{DP}$ offset detection#

rcalpdp = tp.calib.calib_phidp.PhiDP_Calibration(rdata)
rcalpdp.offsetdetection_vps(pol_profs=rprofs, mlyr=rmlyr, rad_vars=rsnr.vars,
                            rad_georef=rdata.georef, rad_params=rdata.params,
                            plot_method=True)
../_images/3814148f35c5fdee66c5dff7ddbc2f21a370f5862b3118c8f48ba4d5329681bb.png
rcalpdp.phidp_offset
np.float64(40.147013767560324)

References#

Gorgucci, E., Scarchilli, G., and Chandrasekar, V. (1999), A procedure to calibrate multiparameter weather radar using properties of the rain medium, IEEE T. Geosci. Remote, 37, 269–276, https://doi.org/10.1109/36.739161

Met Office (2003): Met Office Rain Radar Data from the NIMROD System. NCAS British Atmospheric Data Centre, 2022. http://catalogue.ceda.ac.uk/uuid/82adec1f896af6169112d09cc1174499

Sanchez-Rivas, D. and Rico-Ramirez, M. A. (2021), “Detection of the melting level with polarimetric weather radar” in Atmospheric Measurement Techniques Journal, Volume 14, issue 4, pp. 2873–2890, 13 Apr 2021 https://doi.org/10.5194/amt-14-2873-2021