Questions tagged [gdal-merge]

A utility used to merge small image tiles to create a bigger image

37 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
5
votes
0answers
290 views

When should I use gdal_merge.py?

When building a single georeferenced image from a collection of tiles, gdalbuildvrt followed by gdal_translate is much faster than gdal_merge.py. In my own measurements of gdal_merge.py \ --...
3
votes
0answers
47 views

gdal_merge runs indefinitely, crashes system, BSOD

I have two small rasters. Same resolution, SRID, type, format. When I use gdal_merge, the console keeps running the command ad infinitum. import time, os ot = "UInt16" of = "GTiff" nodata = "255" ...
3
votes
0answers
680 views

Gdal_merge doesn't work

I have gdal installed and (I though) working fine. I use a lot rasterio and sometimes gdal directly, but today I wanted to do a mosaic and I wanted to try gdal_merge.py, but when I try to launch the ...
3
votes
2answers
2k views

gdal_merge.py not found

I'm newbie with Linux and QGIS. I'm using Ubuntu 18.04 LTS and QGIS 3.0 Girona and I can't do mosaic from a raster pile because the following log error message returns: Processing algorithm… ...
2
votes
1answer
132 views

Merging DEMs in QGIS?

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 ...
2
votes
0answers
299 views

GDAL merge of DEM data resulting in large black tiles, elevation min/max problem?

I am new to QGIS (former Arc user) and having trouble with the raster merge tool. I am merging 7 tiles of SRTM arc 1 data to cover a province in eastern Ecuador. Data is resulting in large areas of ...
2
votes
0answers
74 views

GDAL merge; Why add 0.1?

In the implementation of gdal_merge: https://svn.osgeo.org/gdal/trunk/gdal/swig/python/scripts/gdal_merge.py a value of 0.1 is added to the conversion from geo-referenced coordinates to pixel ...
2
votes
1answer
697 views

gdal_merge.py cannot import gdal in Windows 7 Anaconda GDAL Installation

I have an installation of GDAL through Anaconda that is mostly working, but it throws an ImportError whenever I run gdal_merge.py: Traceback (most recent call last): File "C:\Users\xxx\AppData\...
1
vote
0answers
21 views

Merging two pyramid tile sets (directory)?

I was searching on the Internet about the merging of GeoTIFF tiles (pyramid tiles) generated by gdal2tiles. Below are the steps I performed Downloaded tif-files. Converted tif to vrt (below command) ...
1
vote
0answers
54 views

GDAL merge problem in Python code

I am getting the error while I am trying to stack individual raster bands into one image. ValueError: expected array of dim 2 import os from osgeo import gdal import numpy as np os.chdir(r'C:\...
1
vote
0answers
31 views

Merge raster tiles with different resolution and keep original resolution using Python

Problem I have two raster images with different size and resolution, which are overlapping and which I'd like to merge. The smaller image has a higher resolution which I want to merge into the larger ...
1
vote
0answers
43 views

Overlaying and exporting rasters in QGIS?

I have in QGIS a higher quality GeoTIFF overlayed on a larger, lower quality GeoTIFF. I reprojected one raster into the coordinate system of the other. How can I export these to a single GeoTIFF ...
1
vote
0answers
177 views

Error in Raster/Merge tool

I am completely new to QGIS. I am on a Mac using OS 10.13.6. I have installed QGIS 3.6, and installed Python 3.6.8 per install instructions. I opened a terminal window to check python install: ...
1
vote
0answers
31 views

gdal_merge novalue

I managed to run gdal_merge for multiple geotiles (jpeg). I am using the following options: command = "gdal_merge.py -init 0 -a_nodata 0 -co COMPRESS=LZW -co BIGTIFF=YES -o "+out_bez+" -of gtiff " +...
1
vote
0answers
778 views

Error while creating large TIFF with gdal_merge

I need to merge two TIFFs into one, but the output is larger than 4 GB. So, it needs to be a BigTIFF. But the "BIGTIFF=YES" creation option seems to be ignored. Here's the error: $ gdal_merge.py -...
1
vote
0answers
287 views

gdal_merge.py not executing

When I type gdal_merge.py into Terminal, the output is -bash: gdal_merge.py: command not found. I installed 3.4.0 Madeira [from this link] for macOS 10.13 (https://www.qgis.org/en/site/forusers/...
1
vote
0answers
195 views

Keeping band names with gdal_merge.py?

I am using gdal_merge.py to merge different mosaic rasters each contains 20 bands with different names. However, when using gdal_merge.py the bands are renamed as band1, band2, ..., band20. How can I ...
1
vote
1answer
425 views

Georeferencing metadata in GeoTIFF files

I am generating maps as TIFFs using the raster package (writeRaster) in R to generate small tiles, then as a final step, combining the tiles via the GDAL script gdal_merge.py. I thought the resulting ...
1
vote
0answers
326 views

gdal_merge: ERROR 1: Attempt to create 590x-369 dataset is illegal,sizes must be larger than zero

I am attempting to merge 600+ .tif files using gdal_merge.py (GDAL 2.2.2, released 2017/09/15) but I'm getting this error: ERROR 1: Attempt to create 590x-369 dataset is illegal,sizes must be ...
1
vote
0answers
636 views

Patch processing of multiple HDF5 files using Python and Gdal (gdalwarp)

I am trying to extend this process http://geoinformaticstutorial.blogspot.com/2014/06/reading-and-map-projecting-amsr-2-data.html wherein a set of raster data with separate geolocation arrays are ...
1
vote
0answers
204 views

Multiple HDF5 files in single GDAL virtual raster

Does anyone know how to generate a single GDAL virtual raster linking multiple HDF5 files to each other? Each file represents different swaths of the globe with different lat/lon coordinates and data ...
1
vote
0answers
392 views

gdal_merge.py is not working with NODATA values

I am trying to merge a couple of GeoTiff files with gdal_merge.py. Example input: In the input data the nodata value is -32678. Hence I tried: gdal_merge.py -n -32678 -o DEM.tif -of GTiff na_DEM....
1
vote
0answers
151 views

gdal_merge was unexpected at this time

I am using gdal_merge to create an raster from around 250 files (rasters). when I run the command i got gdal_merge was unexpected at this time The command is correct as if I split the files it works ...
1
vote
0answers
394 views

gdal_merge shifts rasters after processing, layer stack is slightly off

I have experienced that gdal shifts rasters. The outputs of gdal_warp are often skewed, have different pixel sizes and so forth. A known error which has also been discussed here. But now, I had to ...
1
vote
0answers
268 views

Serving GeoTIFFs of different resolutions as single layer

I'm trying to serve a 30 arc second DEM with global coverage combined with high resolution 1/3 arc second DEM for a very small area. I believed at first I could combine them into a single file, ...
1
vote
0answers
428 views

Using gdal_merge to merge a large amount of files (in pairs)

I'm new to python and how it can be applied to gis. I have a large amount of MODIS files to go through and I've already extracted, reprojected and converted to GTiff the bands that I need from each ...
1
vote
1answer
542 views

gdal_merge tries to create image with negative dimensions

I am trying to use gdal_merge.py to create a mosaic from a set of geotiffs, however the command fails with the error message: "ERROR 1: Attempt to create -3510x1817 dataset is illegal,sizes must be ...
1
vote
0answers
423 views

Unexpected gdal_merge result

What I'm trying to do is to merge to geotif files with gdal_merge, but the result is not what I expected. Here are the files I'm trying to merge. gdal_merge.py -n 0 -a_nodata 0 -o result.tif file1....
0
votes
0answers
16 views

Trying to merge TIFF raster layers results in invalid layer error

I've created these rasters in Python with numpy arrays and georeferenced them using .points files, no clue why. The error is shown in the screenshot. Edit: All standard settings were used. ...
0
votes
0answers
8 views

Merged rasters result in extended extent

I'm trying to merge some DEMs using the gdal_merge but the result is not what I think it should be. This is the lower limit of one of my original rasters: And the result after merging is: None of ...
0
votes
0answers
11 views

Reducing the number of mosaic elements using gdal_merge

I have 4 thousand mosaic elements. So i would like to reduce their count. (for example to 1 thousand, merge every 4 elements) How can i do this? gdal_merge give me one big raster
0
votes
0answers
13 views

Merging 2 non- touching DTM's using QGIS

Is there a way to merge 2 non- overlapping DTM's without using any form of interpolation? I would like the surface to run straight from one edge to the other without QGIS/GDAL attempting to ...
0
votes
0answers
74 views

Joining file pair for batch gdal_merge.py

I am new to Python and I have been going through past questions and searching trying to determine best way to batch mosaic files. I have a list of .tifs that have been converted from .hdf files I am ...
0
votes
0answers
34 views

Odd Color Shift after Merging Rasters in QGIS

I have a large number of raster orthophotos that I'm trying to merge into a single image using QGIS. The merge completes but the color is significantly off afterwards, as shown here: This seems like ...
0
votes
0answers
159 views

osgeo4mac QGIS 3.4.4 issues with gdal's merge

I'm trying to run the gdal mosaic tool from QGIS3 homebrew osgeo4mac, but when I run it I get this error: 2019-02-11T18:25:17 INFO gdal_merge.py -ot Float32 -of GTiff -o /private/var/folders/...
0
votes
2answers
1k views

How to fix positive North-South Pixel size in GeoTIFF with GDAL

I have issues with some GeoTIFF raster files with positive NS resolution (North-South) gdalinfo gave me this: Pixel Size = (1.000000000000000,1.000000000000000) I run into all kind of problem with ...
0
votes
0answers
198 views

gdal_merge.py aligns incorrectly at the seam of two GeoTiffs

I am trying to merge four GeoTiffs from the National Elevation Dataset (EPSG: 4269) into a 2x2 DEM using gdal_merge.py. For some reason, when it merges the upper two NED rasters, gdal produces a seam ...