AHI grid parameters

wbresky
Posts: 8
Joined: Tue Mar 22, 2022 2:14 pm

AHI grid parameters

Post by wbresky »

I would like to use polar2grid to remap VIIRS data to the H-8/AHI 2-km fixed grid. What grid parameters do I need for the config file? Thanks.
kathys
Posts: 487
Joined: Tue Jun 22, 2010 4:51 pm

Re: AHI grid parameters

Post by kathys »

We will provide an answer for you next week. Sorry for the delay. -Kathy
wbresky
Posts: 8
Joined: Tue Mar 22, 2022 2:14 pm

Re: AHI grid parameters

Post by wbresky »

Great. Thanks.
davidh
Posts: 116
Joined: Tue Jun 04, 2013 11:19 am

Re: AHI grid parameters

Post by davidh »

So here is my best guess at what this should be. I'll try to explain how I did this so you or Kathy can identify if I did anything wrong. The config line that should be put in a ".conf" grids file would look like:

Code: Select all

h8_fldk_2km, proj4, +proj=geos +lon_0=140.7 +h=35785863 +a=6378137 +rf=298.257024882273 +units=m +no_defs, 5500, 5500, 2000, -2000, -5498999.901174725, 5498999.901174725
The PROJ.4 string I got by loading B10 data with the satpy library and looking at the geolocation information. This part should be accurate.
The 5500/5500 rows and columns is also correct as that is just how many pixels there are in a 2km AHI Full Disk image.
The 2000/-2000 are the main question here. Technically by using the coordinates created from the file these pixel resolutions are on the scale of 1999.99996406, but it seemed easier to round them. I'm not as concerned about this rounding as I would be for ABI where 1km pixel sizes are actually 1002.008644 meters.
Lastly, the "origin" position was taken from Satpy by taking the upper-left extent (the outer edges of the pixel) and adding 1000 to each to get the center of the upper-left pixel.

Of course, if you have any problems with this let us know.

For my own future reference:

Code: Select all

from satpy import Scene; from glob import glob
scn = Scene(reader='ahi_hsd', filenames=glob("/data/satellite/ahi/hsd/1830/HS_H08_20181112_1830_B10_FLDK_R20_S*"))
scn.load(["B10"])

scn["B10"].attrs["area"].crs.to_proj4()
# '+proj=geos +lon_0=140.7 +h=35785863 +x_0=0 +y_0=0 +a=6378137 +rf=298.257024882273 +units=m +no_defs +type=crs'

# num rows, columns
scn["B10"].shape

# pixel size x
(area_def.area_extent[2] - area_def.area_extent[0]) / 5500
# 1999.9999640635365

wbresky
Posts: 8
Joined: Tue Mar 22, 2022 2:14 pm

Re: AHI grid parameters

Post by wbresky »

Thanks, David. This is exactly what I needed. I will post again if I have issues. Wayne
wbresky
Posts: 8
Joined: Tue Mar 22, 2022 2:14 pm

Re: AHI grid parameters

Post by wbresky »

This forum helped me out last time when I wanted to know the polar2grid configuration parameters for the AHI 2-km grid. Now I would like to remap some VIIRS I01 data to the AHI 0.5 km grid. What parameters should I use? Thanks.
davidh
Posts: 116
Joined: Tue Jun 04, 2013 11:19 am

Re: AHI grid parameters

Post by davidh »

I'm not sure if I ever asked, but what version of Polar2Grid are you using? In version 3.0 this type of work is much easier as you can specify the outer of the grid (the "extent") and change the number of columns/rows as needed (the YAML grid configuration files). Anyway, we can take the size of the pixels (2000 versus 500) and do some math with the numbers I gave you last time and we get:

Code: Select all

h8_fldk_500m, proj4, +proj=geos +lon_0=140.7 +h=35785863 +a=6378137 +rf=298.257024882273 +units=m +no_defs, 22000, 22000, 500, -500, -5499499.901174725, 5499499.901174725
I think this should work. Let me know how it goes.
wbresky
Posts: 8
Joined: Tue Mar 22, 2022 2:14 pm

Re: AHI grid parameters

Post by wbresky »

Thanks, David. I have version 2.3 installed. Sounds like I should upgrade.
davidh
Posts: 116
Joined: Tue Jun 04, 2013 11:19 am

Re: AHI grid parameters

Post by davidh »

Sorry, I realized I got the numbers wrong. This should be more accurate:

Code: Select all

h8_fldk_500m, proj4, +proj=geos +lon_0=140.7 +h=35785863 +a=6378137 +rf=298.257024882273 +units=m +no_defs, 22000, 22000, 500, -500, -5499749.901174725, 5499749.901174725
For my own reference: my last comment I moved the pixels in 500m, but I should have done half a pixel so 250m.
wbresky
Posts: 8
Joined: Tue Mar 22, 2022 2:14 pm

Re: AHI grid parameters

Post by wbresky »

No problem. Thanks for the update. How are those last 2 columns computed? Those are the only values I didn't know.
Post Reply