5

Not the first problem I've had with DEMs in QGIS 3.4. Trying to merge 6 DEM tiles together into one. Process for this is simple: go to Raster --> Miscellaneous --> Merge. Once in the menu, select which input files and then select a destination output folder. I get an error that reads like this:

Processing algorithm…
Algorithm 'Merge' starting…
Input parameters:
{ 'DATA_TYPE' : 1, 'INPUT' : ['/Users/nickreale/Documents/Micro Atlas/Chiang Mai/Mapping Data:Info/NorthernThailand/ThaiDEM300_0000240000_0012000000.asc','/Users/nickreale/Documents/Micro Atlas/Chiang Mai/Mapping Data:Info/NorthernThailand/ThaiDEM300_0000480000_0012240000.asc'], 'NODATA_INPUT' : None, 'NODATA_OUTPUT' : None, 'OPTIONS' : '', 'OUTPUT' : '/Users/nickreale/Documents/Micro Atlas/Chiang Mai/Mapping Data:Info/NorthernThailand/northai_1.tif', 'PCT' : False, 'SEPARATE' : False }

GDAL command:
gdal_merge.py -ot Int16 -of GTiff -o "/Users/nickreale/Documents/Micro Atlas/Chiang Mai/Mapping Data:Info/NorthernThailand/northai_1.tif" --optfile /var/folders/42/ld6ywf2d5dsb3g3khrd5j1840000gn/T/processing_69556a0719924167983e1a32cdfe7121/mergeInputFiles.txt
GDAL command output:
/bin/sh: gdal_merge.py: command not found

Execution completed in 0.08 seconds
Results:
{'OUTPUT': <QgsProcessingOutputLayerDefinition {'sink':/Users/nickreale/Documents/Micro Atlas/Chiang Mai/Mapping Data:Info/NorthernThailand/northai_1.tif, 'createOptions': {'fileEncoding': 'System'}}>}

Loading resulting layers
The following layers were not correctly generated.<ul><li>/Users/nickreale/Documents/Micro Atlas/Chiang Mai/Mapping Data:Info/NorthernThailand/northai_1.tif</li></ul>You can check the 'Log Messages Panel' in QGIS main window to find more information about the execution of the algorithm.

I've alternatively tried to do this with just two of the 6 DEMs from my folder, thinking that maybe 6 files together were too large.

How do I proceed?

2
  • The last line of the error message says "You can check the 'Log Messages Panel' in QGIS main window to find more information about the execution of the algorithm." Do that.
    – csk
    Sep 3, 2019 at 19:10
  • Could you confirm which operating system you are using and how you installed QGIS.
    – Ben W
    Sep 5, 2019 at 1:59

2 Answers 2

1

It’s possible you have change the system default python by installing another python distribution like Anaconda. It appear that QGIS cannot find the gdal merge.py program that should be in the QGIS program directory. Try to see if the file exists. You may have to reset you default python or QGIS paths.

Another way of doing that is to create a virtual raster. Then load that raster and simple save it a tiff.

0

It might be something with your python installation, since you are getting this message:

GDAL command output:
/bin/sh: gdal_merge.py: command not found 

Which means that one python utility from GDAL is not working properly. So you should check which OS you have and try to search with that error in mind.

Perhaps try to install QGIS with OSGeo4W: https://trac.osgeo.org/osgeo4w/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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