ssec / polar2grid

Tools for reading, remapping, and writing satellite instrument data.
http://www.ssec.wisc.edu/software/polar2grid/
GNU General Public License v3.0
72 stars 34 forks source link

grid_shapes.conf can be removed and calculated on the fly #50

Closed djhoese closed 11 years ago

djhoese commented 11 years ago

Currently there are 2 configuration files for adding grids to polar2grid, grids.conf and grid_shapes.conf. The grid_shapes.conf file lists the bounding box of a grid and the percentage of data coverage required to be considered useful to be mapped to when grid determination is used (no -g flag for some glue scripts).

This file is a separate file mainly because I knew that this behavior wasn't really needed and that I could calculate the bounding box on the fly with very little computation. This is really easy with PROJ.4 grid since there is a python library that lets me use them. The GPD files are more difficult, but with my recent experiments with reproducing GPD files with PROJ.4 grids I think I might be getting closer to completely replacing the GPD files (first we need to resolve the navigation shift that occurs with the AWIPS grids when viewed in AWIPS).

It would be nice to completely get rid of grid_shapes.conf since it's just another thing that needs to be changed when adding grids to polar2grid. The smart thing to do to implement this would be to only calculate these corners in the grid determination step if that grid is used. Probably a bbox attribute in the grid_info that is a tuple of 4 elements (north/south lat, west/east lon).

djhoese commented 11 years ago

Fixed by e157780efff84d260f09c0529d5d78c19df17a83