deeplycloudy / glmtools

GOES-R Geostationary Lightning Mapper Tools
BSD 3-Clause "New" or "Revised" License
63 stars 34 forks source link

Smaller `flash extent density` for lower resolution #88

Closed zxdawn closed 3 years ago

zxdawn commented 3 years ago

I checked the histogram and distribution of flash_extent_density with different target resolutions: 2km and 10km

Data processing

2 km:

python make_GLM_grids.py --fixed_grid --split_events --goes_position east --goes_sector conus --dx=2 --dy=2 --dt=300 ../../GLM_L2/OR_GLM-L2-LCFA_G16_s2020155000*

10 km:

python make_GLM_grids.py --fixed_grid --split_events --goes_position east --goes_sector conus --dx=10 --dy=10 --dt=300 ../../GLM_L2/OR_GLM-L2-LCFA_G16_s2020155000*

Read data

import xarray as xr
from glob import glob
import numpy as np
import matplotlib.pyplot as plt

dir_2km = '../data/GOES-16/GLM_L2_Grid/debug/2km/'
dir_10km = '../data/GOES-16/GLM_L2_Grid/debug/10km/'

ds_2km = xr.open_dataset(glob(dir_2km+'OR_GLM-L2-GLMC-M3_G16_s20201550000000_e20201550005000*')[0])
ds_10km = xr.open_dataset(glob(dir_10km+'OR_GLM-L2-GLMC-M3_G16_s20201550000000_e20201550005000*')[0])

Plot

fig, axs = plt.subplots(1, 2, figsize=(8, 6))
xlim=(0.005, 0.01)
ylim=(0.053, 0.058)
vmin = 0
vmax = 50

ds_2km['flash_extent_density'].plot(ax=axs[0], xlim=xlim, ylim=ylim, vmin=vmin, vmax=vmax)
ds_10km['flash_extent_density'].plot(ax=axs[1], xlim=xlim, ylim=ylim, vmin=vmin, vmax=vmax)

axs[0].set_title('2 km, 5 min')
axs[1].set_title('10 km, 5 min')

plt.subplots_adjust(wspace=2)

fig, axs = plt.subplots(1, 2, figsize=(8, 6))
ds_2km['flash_extent_density'].plot.hist(ax=axs[0], bins=np.arange(0, 15, 1))
ds_10km['flash_extent_density'].plot.hist(ax=axs[1], bins=np.arange(0, 15, 1))
axs[0].set_title('2 km, 5 min')
axs[1].set_title('10 km, 5 min')

Problems

As the pixel is larger for the 10 km option, the FED (flash count in each pixel during 5min) should be larger. But, it's smaller.

image

image

zxdawn commented 3 years ago

Here's the illustration (Fig.4 of @deeplycloudy 's paper):

image

FED is the summation of flashcount * grid_fraction. So, if the grid is large like 10 km, the grid_fraction is smaller and the flashcount may be not change. Then, it leads to the smaller FED.