radarx.retrieve.tornado.tornet_inputs#
- radarx.retrieve.tornado.tornet_inputs(obj, *, elevations=(0.5, 0.9), field='VRADH', dealias=True, nyquist_velocity=None, kdp=None, max_range=None, tolerance=0.25)[source]#
The inputs of the TorNet CNN prepared from a WSR-88D volume.
- Parameters:
obj (
xarray.DataTree) – A volume withsweep_*groups (xradar), e.g. NEXRAD Level II with split cuts: each tilt takes the polarimetric variables from the first sweep at that elevation holding them and the velocity and spectrum width from the first sweep holding velocity.elevations (
tupleoffloat, optional) – Fixed angles (degrees) of the two tilts. Default(0.5, 0.9).field (
str, optional) – Radial velocity field. Default"VRADH".dealias (
bool, optional) – Dealiasfieldwithradarx.retrieve.dealias_velocity()(default). PassFalsefor velocities that are already dealiased.nyquist_velocity (
floatordict, optional) – Nyquist velocity (m s⁻¹) for dealiasing, or a dict mapping the fixed angle (rounded to 0.1°) to it. By default it is read from the sweep (nyquist_velocityvariable or attribute).kdp (
str, optional) – Specific differential phase field. By defaultKDPif present, otherwise it is estimated withradarx.retrieve.estimate_kdp().max_range (
float, optional) – Last range (m) of the output grid. Default: the farthest velocity gate.tolerance (
float, optional) – Largest difference (degrees) between a sweep’s fixed angle and the requested elevation. Default 0.25.
- Returns:
xarray.Dataset–DBZ,VEL,KDP,RHOHV,ZDR,WIDTHandrange_folded_mask(float32) on(azimuth, range, tilt): 720 rays at 0.25°, 0.75°, …, 359.75° and 250 m gates from 2125 m, the grid of the TorNet data. Gates without data are NaN (ZDR: -8 dB, as in the TorNet files); flag codes of NEXRAD data are removed. Coordinateselevation(per tilt),time(of the first tilt) and the radar site.- Raises:
ValueError – If a tilt is missing, or dealiasing is requested without a Nyquist velocity.
Notes
The layout (two tilts of 0.5° and 0.9°, six variables, range-folded mask, ZDR fill) is that of the TorNet samples of Veillette et al. (2025) [1] (sections 2d, 3b; arXiv preprint checked, see
radarx.retrieve. tornado); dealiasing of the velocities with the method of Veillette et al. (2023) [2] in TorNet is replaced here byradarx.retrieve.dealias_velocity(), and the Level III KDP of TorNet byradarx.retrieve.estimate_kdp()unlessKDPis present. The first gate at 2125 m and the 250 m gate spacing follow the TorNet code (min_range_mintornet/data/preprocess.py); 720 rays at 0.5° spacing and thetoleranceof 0.25° for the tilt angles are radarx choices. The ZDR fill of -8 dB (the lowest coded ZDR) is how the released TorNet files were read, not a statement in the paper.Dask. This function computes the dask array: the result combines the gates of all sweeps of the volume. The input is loaded into memory and the result is held in memory.
References