wradlib.georef.raster.reproject_raster_dataset#
- wradlib.georef.raster.reproject_raster_dataset(src_ds, **kwargs)[source]#
Reproject/Resample given dataset according to keyword arguments
- Parameters
src_ds (
osgeo.gdal.Dataset
) – raster image with georeferencing (GeoTransform at least)- Keyword Arguments
spacing (
float
) – float or tuple of two floats pixel spacing of destination dataset, same unit as pixel coordinatessize (
int
) – tuple of two ints X/YRasterSize of destination datasetresample (
gdal:osgeo.gdalconst.ResampleAlg
) – defaults to GRA_Bilinear GRA_NearestNeighbour = 0, GRA_Bilinear = 1, GRA_Cubic = 2, GRA_CubicSpline = 3, GRA_Lanczos = 4, GRA_Average = 5, GRA_Mode = 6, GRA_Max = 8, GRA_Min = 9, GRA_Med = 10, GRA_Q1 = 11, GRA_Q3 = 12projection_source (
osgeo.osr.SpatialReference
) – source dataset projection, defaults to None (get projection from src_ds)projection_target (
osgeo.osr.SpatialReference
) – destination dataset projection, defaults to Nonealign (
bool
ortuple
) – If False, there is no destination grid aligment. If True, aligns the destination grid to the next integer multiple of destination grid. If tuple (upper-left x,y-coordinate), the destination grid is aligned to this point.
- Returns
dst_ds (
osgeo.gdal.Dataset
) – reprojected/resampled raster dataset