TransWikia.com

Aligning two rasters of same resolution perfectly on top of each other in QGIS

Geographic Information Systems Asked by Andrea Rey on January 2, 2021

I have two rasters, that I managed to make in the same resolution using the ‘Raster tools –> Resampling’ tool by SAGA. The pixel sizes are exactly the same, however the new resampled raster, in the image it is the red, does not fall perfectly on top of the target raster (in blue).

enter image description here

I have checked that both rasters have the same CRS projection system, PIXEL size, dimensions, file type, but the only thing I see different is the Data Type. The Red is ‘Byte’ and the blue is ‘Int32’. I have a feeling this difference is what is making my rasters not be aligned.

enter image description here

With the idea that this may be the issue, I have tried the following:

  1. Re-doing the the ‘Raster tools –> Resampling’ tool once again to see if there is any indication or option where I can specify that I want my original red raster to be resampled as the target blue raster, in Int32. I have deselected the first option "Preserve data type" to accomplish this. However, this doesn’t change much. (Also, choosing ‘Cells’ in the ‘Fit’ section instead of ‘Nodes’ only makes the pixels be further away from the raster I want to align with.)

enter image description here

  1. Use the ‘Align Raster’ tool but I have greatly failed at this since it asks to resample two layers when I only want to resample 1. My outcome is basically the two rasters with values very different from the original rasters. Whenever I change any setting on that, it gives me a warning message that it "Failed to align rasters".

enter image description here

I seek help with this. I know with ArcGIS its easier to do but I only have QGIS.

One Answer

I realized the 'Extent' was not exactly the same among my raster layers. I set the same Layer to give the exact coordinates for Extent and now they are aligned.

Answered by Andrea Rey on January 2, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP