pysteps.visualization.utils.reproject_geodata#
- pysteps.visualization.utils.reproject_geodata(geodata, t_proj4str, return_grid=None)#
Reproject geodata and optionally create a grid in a new projection.
- Parameters:
geodata (dictionary) – Dictionary containing geographical information about the field. It must contain the attributes projection, x1, x2, y1, y2, xpixelsize, ypixelsize, as defined in the documentation of pysteps.io.importers.
t_proj4str (str) – The target PROJ.4-compatible projection string (fallback).
return_grid ({None, 'coords', 'quadmesh'}, optional) – Whether to return the coordinates of the projected grid. The default return_grid=None does not compute the grid, return_grid=’coords’ returns the centers of projected grid points, return_grid=’quadmesh’ returns the coordinates of the quadrilaterals (e.g. to be used by pcolormesh).
- Returns:
geodata – Dictionary containing the reprojected geographical information and optionally the required X_grid and Y_grid.
It also includes a fixed boolean attribute regular_grid=False to indicate that the reprojected grid has no regular spacing.
- Return type:
dictionary