|
47 | 47 | "import pyart\n",
|
48 | 48 | "import hvplot.xarray\n",
|
49 | 49 | "import holoviews as hv\n",
|
| 50 | + "from open_radar_data import DATASETS\n", |
50 | 51 | "import panel as pn\n",
|
51 | 52 | "\n",
|
52 | 53 | "hv.extension(\"bokeh\")"
|
|
82 | 83 | "Here, we use data from the Japanese weather radar, using sample data [from here](https://github.com/openradar/asean2024-pyrad-course/tree/main/data/JMA)."
|
83 | 84 | ]
|
84 | 85 | },
|
85 |
| - { |
86 |
| - "cell_type": "code", |
87 |
| - "execution_count": null, |
88 |
| - "id": "27133c8d-ddd2-4557-acda-1b78dd8e3064", |
89 |
| - "metadata": {}, |
90 |
| - "outputs": [], |
91 |
| - "source": [ |
92 |
| - "!wget -nc https://github.com/openradar/asean2024-pyrad-course/raw/main/data/JMA/Z__C_RJTD_20230801200000_RDR_JMAGPV_RS47937_Gar0p250km0p35deg_PRref_N11_ANAL_cfrad.nc\n", |
93 |
| - "!wget -nc https://github.com/openradar/asean2024-pyrad-course/raw/main/data/JMA/Z__C_RJTD_20230801200000_RDR_JMAGPV_RS47937_Gar0p250km0p35deg_PRzdr_N11_ANAL_cfrad.nc\n", |
94 |
| - "!wget -nc https://github.com/openradar/asean2024-pyrad-course/raw/main/data/JMA/Z__C_RJTD_20230801200000_RDR_JMAGPV_RS47937_Gar0p250km0p35deg_PRkdp_N11_ANAL_cfrad.nc" |
95 |
| - ] |
96 |
| - }, |
97 | 86 | {
|
98 | 87 | "cell_type": "markdown",
|
99 | 88 | "id": "c1615d14-50a8-4786-adb8-7c6e80f0ce94",
|
|
111 | 100 | },
|
112 | 101 | "outputs": [],
|
113 | 102 | "source": [
|
114 |
| - "files = glob.glob('./Z__C_RJTD_20230801200000_RDR_JMAGPV_RS47937_*')\n", |
115 |
| - "files" |
| 103 | + "reflectivity_file = DATASETS.fetch(\"Z__C_RJTD_20230801200000_RDR_JMAGPV_RS47937_Gar0p250km0p35deg_PRref_N11_ANAL_cfrad.nc\")\n", |
| 104 | + "zdr_file = DATASETS.fetch(\"Z__C_RJTD_20230801200000_RDR_JMAGPV_RS47937_Gar0p250km0p35deg_PRzdr_N11_ANAL_cfrad.nc\")\n", |
| 105 | + "kdp_file = DATASETS.fetch(\"Z__C_RJTD_20230801200000_RDR_JMAGPV_RS47937_Gar0p250km0p35deg_PRkdp_N11_ANAL_cfrad.nc\")" |
116 | 106 | ]
|
117 | 107 | },
|
118 | 108 | {
|
|
133 | 123 | },
|
134 | 124 | "outputs": [],
|
135 | 125 | "source": [
|
136 |
| - "radar = xd.io.open_cfradial1_datatree(files[0]).xradar.georeference()\n", |
| 126 | + "radar = xd.io.open_cfradial1_datatree(reflectivity_file).xradar.georeference()\n", |
137 | 127 | "radar"
|
138 | 128 | ]
|
139 | 129 | },
|
|
146 | 136 | },
|
147 | 137 | "outputs": [],
|
148 | 138 | "source": [
|
149 |
| - "radar_zdr = xd.io.open_cfradial1_datatree(files[1]).xradar.georeference()\n", |
| 139 | + "radar_zdr = xd.io.open_cfradial1_datatree(zdr_file).xradar.georeference()\n", |
150 | 140 | "radar_zdr"
|
151 | 141 | ]
|
152 | 142 | },
|
|
159 | 149 | },
|
160 | 150 | "outputs": [],
|
161 | 151 | "source": [
|
162 |
| - "radar_kdp = xd.io.open_cfradial1_datatree(files[2]).xradar.georeference()\n", |
| 152 | + "radar_kdp = xd.io.open_cfradial1_datatree(kdp_file).xradar.georeference()\n", |
163 | 153 | "radar_kdp"
|
164 | 154 | ]
|
165 | 155 | },
|
|
211 | 201 | " y='y',\n",
|
212 | 202 | " cmap='pyart_ChaseSpectral',\n",
|
213 | 203 | " clabel='Horizontal Reflectivity (dBZ)',\n",
|
214 |
| - " title=f'Horizontal Reflectivity \\n {radar.attrs[\"site_name\"]} Radar',\n", |
| 204 | + " title=f'Horizontal Reflectivity \\n JMA {radar.attrs[\"site_name\"]} Radar',\n", |
215 | 205 | " clim=(-20, 60),\n",
|
216 | 206 | " height=400,\n",
|
217 | 207 | " rasterize=True,\n",
|
218 |
| - " width=500,)\n", |
219 |
| - "\n", |
220 |
| - "#ref" |
| 208 | + " width=500,)" |
221 | 209 | ]
|
222 | 210 | },
|
223 | 211 | {
|
|
233 | 221 | " y='y',\n",
|
234 | 222 | " cmap='pyart_ChaseSpectral',\n",
|
235 | 223 | " clabel='Differential Reflectivity (dB)',\n",
|
236 |
| - " title=f'Differential Reflectivity \\n {radar.attrs[\"site_name\"]} Radar',\n", |
| 224 | + " title=f'Differential Reflectivity \\n JMA {radar.attrs[\"site_name\"]} Radar',\n", |
237 | 225 | " clim=(-1, 6),\n",
|
238 | 226 | " height=400,\n",
|
239 | 227 | " rasterize=True,\n",
|
240 |
| - " width=500,)\n", |
241 |
| - "#zdr" |
| 228 | + " width=500,)" |
242 | 229 | ]
|
243 | 230 | },
|
244 | 231 | {
|
|
254 | 241 | " y='y',\n",
|
255 | 242 | " cmap='pyart_ChaseSpectral',\n",
|
256 | 243 | " clabel='Specific differential phase (degree/km)',\n",
|
257 |
| - " title=f'Specific differential phase \\n {radar.attrs[\"site_name\"]} Radar',\n", |
| 244 | + " title=f'Specific differential phase \\n JMA {radar.attrs[\"site_name\"]} Radar',\n", |
258 | 245 | " clim=(-1, 6),\n",
|
259 | 246 | " height=400,\n",
|
260 | 247 | " rasterize=True,\n",
|
261 |
| - " width=500,)\n", |
262 |
| - "#kdp" |
| 248 | + " width=500,)" |
263 | 249 | ]
|
264 | 250 | },
|
265 | 251 | {
|
|
280 | 266 | },
|
281 | 267 | "outputs": [],
|
282 | 268 | "source": [
|
283 |
| - "(ref + zdr + kdp).cols(3)" |
| 269 | + "(ref + zdr + kdp).cols(1)" |
284 | 270 | ]
|
285 | 271 | },
|
286 |
| - { |
287 |
| - "cell_type": "code", |
288 |
| - "execution_count": null, |
289 |
| - "id": "e916fa08-fd62-4c5a-9e12-2c9b46b1f74d", |
290 |
| - "metadata": {}, |
291 |
| - "outputs": [], |
292 |
| - "source": [] |
293 |
| - }, |
294 | 272 | {
|
295 | 273 | "cell_type": "markdown",
|
296 | 274 | "id": "65594dca-31c6-4b80-b5d7-92c101e07c97",
|
|
475 | 453 | ],
|
476 | 454 | "metadata": {
|
477 | 455 | "kernelspec": {
|
478 |
| - "display_name": "radar-cookbook-dev", |
| 456 | + "display_name": "Python 3 (ipykernel)", |
479 | 457 | "language": "python",
|
480 |
| - "name": "radar-cookbook-dev" |
| 458 | + "name": "python3" |
481 | 459 | },
|
482 | 460 | "language_info": {
|
483 | 461 | "codemirror_mode": {
|
|
0 commit comments