2

According to the properties, my output raster is in a different projection than the input after running GRASS r.reclass through QGIS. Does anyone know if this is just a fluke and I can simply select a different CRS through the properties, or do I have to "Save as" to reproject the output raster in the correct CRS?

Using QGIS 2.14.3

1
  • Still having problems with this. Both the project CRS and the input raster CRS are the same (ESPG 31370), double checked that. But the CRS of output raster coming from r.rclass is not 31370 as expected from the answer above, but unknown. For one raster it's ok setting its CRS manually, but for many.... no. My code: input = 'input.tif' output = 'output.tif' p_rule='3=1' result=processing.run("grass7:r.reclass", { 'input':input, 'rules':'', 'txtrules':p_rule, 'output':output, 'GRASS_REGION_PARAMETER':None, 'GRASS_REGION_CELLSIZE_PARAMETER':0, 'GRASS_RASTER_FORMAT_OPT':'', 'GRASS_RASTER_FORMAT_ME Sep 10 at 13:57
1

Before you run GRASS, make sure that the project CRS is set to the CRS of the layer you are working on. Then output and input layer CRS should be the same.

Save As is not useful for reprojecting rasters (it only works for vector data). Instead, use Raster -> Projections -> Warp to a different filename and CRS, or Set Layer CRS ONLY if the raster is misplaced.

2
  • perfect! I did not know that the Save As: only works for vector data. Thanks AndreJ.
    – Scolopax
    Jun 15 '16 at 18:51
  • @Scolopax Save As works for rasters too, but only the filename part.
    – AndreJ
    Jun 16 '16 at 4:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.