Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I was hoping gdalwarp could merge and crop MODIS tiff images such that the original cell size and alignment is maintained. I tried the command below, but cell size is off slightly and cell alignment is offset from 10 to 100 meters.

gdalwarp -cutline basins.shp -crop_to_cutline input1.tif input2.tif input3.tif outputmergeclip.tif

I tried setting -tr to the source cell size, -te to the extent of the shapefile snapped to the source grid cell alignment and -tap, but these didn't make any change in the result. Am I interpreting the options incorrectly? Am I on the wrong track with gdalwarp?

I'm scripting this in Python and relatively new to both python(2.7) and gdal(1.9.2).

share|improve this question

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.