Skip to content

Commit

Permalink
add example test
Browse files Browse the repository at this point in the history
  • Loading branch information
YvZheng committed Nov 25, 2019
1 parent e124c31 commit 29fa91d
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions examples/test.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,21 @@
# -*- coding: utf-8 -*-
from NuistRadar.io.auto_io import radar_io
from NuistRadar.io.SCFile import SCBaseData
from NuistRadar.draw.VerticalSectionPlot import VerticalSection
import numpy as np
from NuistRadar.draw.SingleRadarPlotMap import RadarGraphMap
from NuistRadar.draw.SingleRadarPlot import RadarGraph
from NuistRadar.qc.attenuation import correct_attenuation_HB, correct_attenuation
import matplotlib.pyplot as plt

#file = r"E:\RadarBaseData\CINRAD-SA\温州\2015080816.59A"
file = r"C:\Users\zy\Desktop\Z_RADR_I_Z9831_20190427200200_O_DOR_SC_CAP.bin"
file = r"E:\RadarBaseData\CINRAD-SA\温州\2015080816.59A"
#file = r"E:\RadarBaseData\CINRAD-CC\2016070817.03V"
#radar = SCBaseData(file)
Radar = radar_io(file)
NRadar = Radar.ToNuistRadar()
PyartRadar = Radar.ToPyartRadar()

dbz = NRadar.fields[0]["dBZ"]
y = correct_attenuation_HB(dbz)
graph = RadarGraph(NRadar)
z = correct_attenuation(dbz, "X")
#graph.plot(0, "dBZ", continuously=False)
graph.simple_plot_ppi(dbz.range, dbz.azimuth, dbz.elevation, dbz, cmap="CN_ref")
plt.show()

0 comments on commit 29fa91d

Please sign in to comment.