gdal.clip_raster_by_vector

Clip a raster to a vector boundary.

  • Kind: standard
  • Network: no
  • Wraps: gdalwarp -cutline

Inputs🔗

NameTypeDescription
sourcefile (GeoTIFF)Raster to clip.
boundaryfile (GeoJSON)Vector boundary defining the clip region.
crop_to_cutlinebooleanShrink the output extent to the cutline bounding box. Default true.
all_touchedbooleanInclude pixels touched by the cutline rather than centroid coverage. Default false.

Outputs🔗

NameTypeDescription
rasterfile (GeoTIFF)Clipped raster.