parameters: (reference, others, kwargs)
docstring: Take two or more rasters and modify them so that they have the same pixel size
docstring_summary: Take two or more rasters and modify them so that they have the same pixel size
docstring_tokens: Take two or more rasters and modify them so that they have the same pixel size
function: def match_pixel_size(reference, others, kwargs):
      """Take two or more rasters and modify them so that they have the same pixel size"""
      rasters = [reference] + others
      max_xres = max([raster.xres for raster in rasters])
      max_yres = max([raster.yres for raster in rasters])
  
      if 'resolution' in kwargs:
          max_xres = max(max_xres, kwargs['resolution'])
          max_yres = max(max_yres, kwargs['resolution'])
  
      reference.match_pixel_size(max_xres, max_yres)
      for other in others:
          other.match_pixel_size(max_xres, max_yres)
function_tokens: def match_pixel_size ( reference , others , kwargs ) : rasters = [ reference ] + others max_xres = max ( [ raster . xres for raster in rasters ] ) max_yres = max ( [ raster . yres for raster in rasters ] ) if 'resolution' in kwargs : max_xres = max ( max_xres , kwargs [ 'resolution' ] ) max_yres = max ( max_yres , kwargs [ 'resolution' ] ) reference . match_pixel_size ( max_xres , max_yres ) for other in others : other . match_pixel_size ( max_xres , max_yres )