Skip to main content

Questions tagged [gdal-merge]

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

Filter by
Sorted by
Tagged with
1 vote
0 answers
56 views

Creating Orthomosaic with GDAL

Platform: Windows 11 1. Aim trying to achieve: I have some very high quality multispectral data (drone multispectral imagery), from which I am trying to create an orthomosaic. My multispectral data ...
DevM's user avatar
  • 11
1 vote
1 answer
32 views

Gdalwarp assigning zero values outside input raster extents

I'm attempting to combine several GeoTIFF files into a single mosaic raster using gdalwarp: import os os.environ['AWS_NO_SIGN_REQUEST'] = 'YES' file1 = "https://dea-public-data-dev.s3-ap-...
Robbi Bishop-Taylor's user avatar
0 votes
0 answers
97 views

How to merge several Sentinel-2 images using the median for the overlapping areas?

I'm having a little bit of trouble coming with the best way to do this. I have several rasters that contain each 12 Sentinel-2 bands, not all from the same tile that I want to do some preprocessing ...
rrwork___'s user avatar
1 vote
0 answers
51 views

Setting the nodata value

I have three Sentinel 2 rasters for band 4 (named tile1_B04, tile2_B04, tile3_B04) and my area of interest is clipped by merging these 3 rasters. 2 out of 3 rasters have 0 pixels in certain portions. ...
rekha's user avatar
  • 11
0 votes
0 answers
38 views

Result of merge in QGIS is image that doesn't contains all the merged raster

I'm trying to merge ~10 rasters that I have on qgis. Each raster has 2 bands.The rasters overlap each other, and their no-data value is -9999. This is how all the rasters look like before merging (the ...
ReutKeller's user avatar
  • 2,169
0 votes
0 answers
292 views

Merging overlapping rasters - retaining maximum value using gdal

I have multiple overlapping tiffs(having 3 bands) which i want to merge using gdal/pyqgis but want to retain the maximum pixel values for the overlapping part. I tried using gdal_merge.py but it only ...
Moez's user avatar
  • 13
1 vote
1 answer
155 views

QGIS 3 greyscale on TIFF after merge raster is all washed out

I am merging 3 separate raster DEM's in BIL format. The result of the merge is a black field with a very washed out TIFF. The data is valid because I can probe it with the Identify tool and see the ...
kelleysislander's user avatar
4 votes
2 answers
716 views

Merging multiple GeoTIFF's with gdal_merge creates a solid gray GeoTIFF

I have these two GeoTIFF's: https://terrafrost.com/gdal/1.tif https://terrafrost.com/gdal/2.tif I'm trying to merge them by doing gdal_merge -o result.tif 1-dark.tif 2-dark.tif but when I do the ...
neubert's user avatar
  • 370
0 votes
0 answers
162 views

gdal_translate from .vrt doesn't reproject tiles, but .vrt has right projection

Translation of a big .vrt (tiles are .bil in EPSG:4326, .vrt has ESRI:102027) file results in a wrong raster with EPSG:4326 projection. Command here is gdal_translate -of GTiff -ot Float32 $INPATH/...
Nikolay Yasinskiy's user avatar
0 votes
0 answers
41 views

How to stack/merge geom_stars items/plots in one - in R

If I have plotted the Relative Error Maps for the Silt soil attribute for the following 4 different soil types: Cambisols, calcisols, leptosols and fluvisols that form my study case area: ggplot() + ...
Dimitris K's user avatar
0 votes
0 answers
210 views

ERROR 1: Attempt to create 5259x-3397 dataset is illegal,sizes must be larger than zero

I am attempting to merge two .tiff files using gdal_merge.py (GDAL 3.4.3, released 2022/04/22), but I'm getting the following error: ERROR 1: Attempt to create 5259x-3397 dataset is illegal,sizes ...
ametya's user avatar
  • 1
1 vote
1 answer
732 views

Merging two overlapping NetCDF files

I'm not an expert on this kind of stuff. Basically I'd like to merge two .nc files, one from GOES-R G16 and the other from GOES-R G17. The files contain the same variables and refer to the same time; ...
persson's user avatar
  • 63
0 votes
1 answer
129 views

Unable to merge TIFFs in one file using Warp and QGIS

I have three TIFFs are below which is belongs to Alaska HI Chart: First https://drive.google.com/file/d/1KllacOdKNw866doqjMcounsvofpXBgFh/view?usp=sharing Second https://drive.google.com/file/d/...
nivesh shastri's user avatar
2 votes
0 answers
528 views

for loop for merging multiple *.gpkg files in OSGeo4W Shell

I´d like to merge multiple files (geopackages) saved in a Windows folder to one *.gpkg using OSGeo4W Shell: for %f in (\*.gpkg) do (ogr2ogr 'gpkg' -update -append merged.gpkg %f -nln merged.gpkg) ...
Mapos's user avatar
  • 565
3 votes
1 answer
308 views

GDAL merge within a QGIS model designer

I am attempting to include GDAL's merge but having difficulty with the "Additional creation options" field. I would like to include both COMPRESS=LZW and TILED=YES however I cannot seem to ...
Pictory's user avatar
  • 194
0 votes
1 answer
133 views

QGIS creates BOX with no data when merged

I have 2 rasters. The first one is a lidar which is clipped by a masked layer. (30.53mb, pixel size=1m,float32) The other is a local survey GEOTIFF. (75kb, pixel size=1m,float32) When I merge them, ...
KMG's user avatar
  • 33
1 vote
1 answer
83 views

gdal_merge - what use does the -"init" option have?

Looking at the gdal documenation for gdal_merge the "-init" option pre-initializes output bands with values. I assume this means that the whole band is assigned a certain value before the ...
Robert Buckley's user avatar
1 vote
0 answers
415 views

Using GDAL translate with VRT - merge error in overlap creates black 📦

I have a series of hi resolution multispectral images from Maxar's WV2 in .NTF form. I am trying to stitch tiles together to create a single image, and I've been having a lot of trouble. I initially ...
bashful_creature's user avatar
0 votes
0 answers
158 views

using gdal to merge Sentinel 5p projected tiff files without the overlapping at borders?

I have used gdalwarp for extracting Sentinel 5p L2__AER_AI data product to 14 tiff files in EPSG:4326 CRS. These projected tiff files can be gotten from https://drive.google.com/drive/folders/1AHuH6n-...
Bằng Rikimaru's user avatar
0 votes
0 answers
102 views

Gdalwarp for terrain correction in SAR image

I am new to the gdal utility. Using DEM data of the Moon, I am trying to perform terrain correction on SAR images. Here is gdal commandline code ``` !gdalwarp -multi -wo NUM_THREADS=ALL_CPUS -co ...
Nidhi Verma's user avatar
0 votes
0 answers
194 views

Polar StereoGraphic projection

I have two files with the projection information Image 1 'GEOGCS["Moon Spheroid",DATUM["Moon_Spheroid",SPHEROID["Moon Spheroid",1737400,833.3333]],PRIMEM["Greenwich&...
Nidhi Verma's user avatar
1 vote
1 answer
456 views

Automating gdal_merge [closed]

I would like to call gdal_merge via batch-file, so far this looks like this: python "C:\Program Files\GDAL\gdal_merge.py" -ot Float32 -of GTiff -co COMPRESS=DEFLATE -co PREDICTOR=2 -co ...
PDistl's user avatar
  • 95
0 votes
0 answers
250 views

Identify real world elevation for digital elevation (DEM) GeoTIFF

This seems like it should be simple, but I have been struggling to figure out the best way to identify the real world minimum and maximum elevations from a GeoTIFF I downloaded from the National Map. ...
Jon's user avatar
  • 23
0 votes
0 answers
125 views

GDAL_Merge not included in OSGEO4W window

I download QGIS Desktop 3.18.3 which came with OSGEO4W I ran o-help on the OSGEO4W window and noticed gdal_merge etc werent included as available commands. Yet if I go to apps/python37/scripts folder ...
guest07823's user avatar
1 vote
0 answers
128 views

QGIS Raster Merge, Projection Error

I am trying to merge a collection of NED10m tiles using QGIS and the GDAL>Raster miscellaneous>Merge command. The command executes but my output raster has a projections issue. Below are two ...
Mikey Johnson's user avatar
1 vote
0 answers
3k views

How to merge all raster files in a folder using gdal_merge?

I have DEMs in a folder like this If I run gdal_merge -o out.tif *.hgt, it says ERROR 4: `/*.hgt' does not exist in the file system, and is not recognized as a supported dataset name. A similar ...
BallpenMan's user avatar
  • 1,217
4 votes
1 answer
3k views

Fastest Possible Use of GDAL to Merge, Reproject & Convert

I have a ~10GB, Australia-wide, single band dataset consisting of 3,351 GeoTIFFs across 8 projections (Map Grid of Australia [MGA], zones 49 to 56). The data has a 2m resolution but only covers urban ...
minus34's user avatar
  • 767
2 votes
1 answer
1k views

Merging rasters with alpha channel using GDAL

I need to merge 13 GeoTIFFs with (RGB+alpha channel) into one, some of them touch each other. For tests I used only two of them. I was trying to use gdalbuildvrt tool and gdal_translate afterwards, ...
Agata's user avatar
  • 31
1 vote
1 answer
1k views

gdal_merge: Ignore NoData value only if present in all bands of multiband image

I have a number of RGB images with NoData areas around them, where each band then has the value 0. To merge them, I can of course use gdal_merge like this: python gdal_merge.py -n 0 -o output.tif ...
s6hebern's user avatar
  • 1,236
0 votes
0 answers
245 views

Merge raster layer error, illegal size

I have an issue with merging several tiles. I am loading the original XYZ files into QGIS (works fine) and try to merge them afterwards yia Raster/miscellaneous/merge . If I only merge 2 tiles this ...
jonen's user avatar
  • 1
0 votes
0 answers
446 views

Balancing/equalizing color of geotiffs before creating mosaic

I have multiple geotiffs and I want to balance/equalize the color between them, so when I create the final mosaic there will not be any "too obvious" artefacts. GDAL helps to create the ...
Gery's user avatar
  • 2,135
0 votes
0 answers
325 views

Returned non-zero exit status 2 gdal_merge.py in QGIS plugin

I'm trying to merge several files within a QGIS plugin via gdal_merge.py. In Anaconda distribution exactly the same code works as it is like that. I suppose Python in QGIS can't find gdal_merge.py. ...
Jonas Apelt's user avatar
2 votes
3 answers
1k views

Merging TIFFs while retaining details in GDAL

I am currently trying to merge overlapping raster TIFFs into one single, continuous image. Just using Merge results in a raster with borders, and it is unsatisfactory : However, using a pixel ...
Aayush Panda's user avatar
2 votes
1 answer
1k views

Limit RAM usage by gdal_merge

When trying to use gdal_merge.py (from alpine-normal-3.2.1) to actually merge 4 large raster files (roughly 6 GB each) this way: gdal_merge.py -o merged.tif -of GTiff input_*.tif my computer memory ...
swiss_knight's user avatar
  • 10.5k
1 vote
0 answers
310 views

Artefacts when merging different resolution DEM

I am trying to merge a 10m DEM with a 30m DEM (10m DEM is a sub area of the 30m DEM). Both DEMs have the same projection and nodata value. I create a .vrt file: gdalbuildvrt test.vrt *.tif -resolution ...
Andreas's user avatar
  • 83
1 vote
2 answers
2k views

What is the raster merge criteria algorithm on rasterio.merge?

I'm creating a mosaic from many sentinel images with a bunch of overlapping areas, although I'm trying to understand what is criteria. For example: This is a small piece totally clear of clouds And ...
eduardosteps's user avatar
2 votes
1 answer
347 views

Why is gdal_merge resulting in massive output file?

When using gdal merge to merge two geotiff files about 20 and 60 MB in size, the output files end up on the order of tens of GB. I have tried a variety of compression types, but they either fail or ...
Matt Brauer's user avatar
1 vote
0 answers
118 views

Fixing white portion of a merged TIFF

I am trying to add a merge layer to my project. I noticed that my merged layer has a region that is way too white, I am trying to fix that white space by adjusting the interval value from 0-255 to 0-...
clint southwood's user avatar
1 vote
0 answers
634 views

ImportError: No module named osgeo

I'm running a .bat script (included) in the cmd prompt. I get the error "ImportError: No module named osgeo" when it tries to call the gdal_merge.py command. I think this has something to do ...
gpatkinson's user avatar
4 votes
1 answer
810 views

Forming a single TIFF image of a Sentinel 2 tile [closed]

I downloaded the data using the following command from Amazon S3 bucket : aws s3 cp s3://sentinel-s2-l2a/tiles/51/H/VC/2020/10/19/0/ aus1 --recursive --request-payer. Then translated the 13 bands ...
user2777's user avatar
2 votes
0 answers
68 views

Altimetric image with blank space when merging

I have downloaded some tiff images that has altimetric data from the Brazilian SRTM website: where i am using raster layers to apply merging. However, i have some problems with my merged images, a ...
clint southwood's user avatar
0 votes
1 answer
2k views

Using Python GDAL Merge (gdal_merge.py)

I am having a Merging issue with the GDAL python library. I am using gdal_merge.pylink My issue is when I merge two rasters NoData value of one raster overlaps the other data resulting in not a proper ...
terraCoder's user avatar
0 votes
0 answers
322 views

Gdal Merge of Raster Fails

I´m trying to merge several partially overlapping rasters using Gdal Merge in QGIS 3.14.15-Pi. The merge process runs without throwing any errors but the output is incorrect. The output has no defined ...
Approachable's user avatar
2 votes
1 answer
654 views

QGIS gdal merge not working

I'm getting this error when trying to merge 5 different files: 2020-08-25T15:52:53 WARNING Traceback (most recent call last): File "C:/Users/.../AppData/Roaming/QGIS/QGIS3\profiles\default/...
T-RexMan's user avatar
0 votes
1 answer
39 views

QGIS: Exported layer values differ from the underlying raster layer they were exported from

I´m trying to merge multiple raster layers (partial overlap) and then export them into a single layer for my required area of interest (AOI). When i use the raster merge (gdal_merge) option it merges ...
Approachable's user avatar
0 votes
0 answers
187 views

Custom function for mosaic seams in Python GDAL

I was wondering if there is a way to implement a custom function for creating seams between the rasters that create a mosaic. More specifically, if I create a mosaic with gdal_merge or gdalwarp, the ...
Karol Wojtulewicz's user avatar
0 votes
2 answers
2k views

Exporting large rasters in Google Earth Engine

When exporting large raster data in Google Earth Engine to your Google Drive, is there a function that prevents the export from automatically tiling into smaller files, or even decreases the number of ...
rachell's user avatar
  • 107
4 votes
1 answer
801 views

PyQGIS standalone script error message for gdal_merge: "Incorrect parameter value for INPUT"

In my standalone PyQGIS script I would like to merge two raster layer. "zero" and "raster". Both variables are definitly QgsRasterLayer objects. This is the function: def merge(self): zero = self....
DGIS's user avatar
  • 2,547
1 vote
0 answers
90 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) ...
H.Singh's user avatar
  • 11
0 votes
0 answers
45 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
korsarqa's user avatar