【Python】用Py-ART实现速度退模糊

0 介绍

        Py-ART 被 大气辐射测量 (ARM) 气候研究机构用于处理来自许多降水和云雷达的数据,但其设计目的是让雷达和大气界的其他人可以使用它来检查、处理和分析来自多种天气雷达的数据。

        下面为使用Py-ART提供的两种速度退模糊的方法(dealias_region_based和dealias_fourdd)的实施个例。

1 实现

# First import needed modules.
import cartopy.crs as ccrs
import matplotlib.pyplot as plt
import numpy as np
import pyart

# Read the radar data.
radar = pyart.io.read('xxx')


fig = plt.figure(figsize=[8,16])
ax = plt.subplot(2,1,1,projection=ccrs.PlateCarree())
display = pyart.graph.RadarMapDisplay(radar)
display.plot_ppi_map('reflectivity', sweep=2, resolution='50m',
                     vmin=0, vmax=60,cmap='gist_ncar',
                     projection=ccrs.PlateCarree())

ax2 = plt.subplot(2,1,2,projection=ccrs.PlateCarree())
display = pyart.graph.RadarMapDisplay(radar)
display.plot_ppi_map('velocity', sweep=2, resolution='50m',
                     vmin=-15, vmax=15,
                     projection=ccrs.PlateCarree(), cmap='bwr')
# plt.show()
plt.savefig('region_plot_ppi_map.jpg')
原始雷达的反射率和径向速度
原始雷达的反射率和径向速度

1.1 dealias_region_based

radar.instrument_parameters['nyquist_velocity']['data']
vel_texture = pyart.retrieve.calculate_velocity_texture(radar, vel_field='velocity', wind_size=3, nyq=16.524973)
radar.add_field('velocity_texture', vel_texture, replace_existing=True)

# Set up the gatefilter to be based on the velocity texture.
gatefilter = pyart.filters.GateFilter(radar)
gatefilter.exclude_above('velocity_texture', 3)


nyq = radar.instrument_parameters['nyquist_velocity']['data'][0]
velocity_dealiased = pyart.correct.dealias_region_based(radar, vel_field='velocity', nyquist_vel=nyq,
                                                        centered=True, gatefilter=gatefilter)
radar.add_field('corrected_velocity', velocity_dealiased, replace_existing=True)


# Plot the new velocities, which now look much more realistic.
fig = plt.figure(figsize=[8, 8])
display = pyart.graph.RadarMapDisplay(radar)
display.plot_ppi_map('corrected_velocity', sweep=2, resolution='50m',
                     vmin=-30, vmax=30,
                     projection=ccrs.PlateCarree(), cmap='bwr',
                     gatefilter=gatefilter)
# plt.show()
plt.savefig('region_plot_ppi_map_corrected_velocity.jpg')


dealias_region_based结果
dealias_region_based结果

1.2 dealias_fourdd

原理:利用径向速度在空间和时间四维的连续性来实现速度退模糊。详情见参考4。

radar.instrument_parameters['nyquist_velocity']['data']

vel_texture = pyart.retrieve.calculate_velocity_texture(radar, vel_field='velocity', wind_size=3, nyq=16.524973)
radar.add_field('velocity_texture', vel_texture, replace_existing=True)

sond_name = "xxx"
dt,profile = pyart.io.read_arm_sonde_vap(sond_name,radar=radar)

gatefilter = pyart.filters.GateFilter(radar)
gatefilter.exclude_transition()
gatefilter.exclude_invalid('velocity')
gatefilter.exclude_invalid('reflectivity')
gatefilter.exclude_outside('reflectivity',0,80)
gatefilter.exclude_above('velocity_texture', 3)

velocity_dealiased = pyart.correct.dealias_fourdd(radar, vel_field='velocity',
                            sonde_profile=profile,gatefilter=gatefilter)
radar.add_field('corrected_velocity', velocity_dealiased, replace_existing=True)


# Plot the new velocities, which now look much more realistic.
fig = plt.figure(figsize=[8, 8])
display = pyart.graph.RadarMapDisplay(radar)
display.plot_ppi_map('corrected_velocity', sweep=2, resolution='50m',
                     vmin=-41, vmax=41,cmap='bwr',
                     projection=ccrs.PlateCarree(),
                     gatefilter=gatefilter)
# plt.show()
plt.savefig('fourdd_plot_ppi_map_corrected_velocity.jpg')


dealias_fourdd结果
dealias_fourdd结果

参考

1、 The Python ARM Radar Toolkit - Py-ART — Py-ART 1.11.7.dev+60158b2 documentation

2、 pyart.correct.dealias_fourdd — Py-ART 1.11.7.dev+60158b2 documentation

3、Dealiasing Velocity — Py-ART 1.11.7.dev+60158b2 documentation

4、A Real-Time Four-Dimensional Doppler Dealiasing Scheme in: Journal of Atmospheric and Oceanic Technology Volume 18 Issue 10 (2001)

  • 3
    点赞
  • 9
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值