Questions tagged [gdal-merge]
A utility used to merge small image tiles to create a bigger image
155
questions
0
votes
0
answers
9
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. ...
0
votes
0
answers
24
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 ...
0
votes
0
answers
168
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 ...
1
vote
1
answer
97
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 ...
4
votes
2
answers
396
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 ...
0
votes
0
answers
102
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/...
0
votes
0
answers
38
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() +
...
0
votes
0
answers
132
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 ...
1
vote
1
answer
578
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; ...
0
votes
1
answer
106
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/...
2
votes
0
answers
397
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)
...
3
votes
1
answer
251
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 ...
0
votes
1
answer
116
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, ...
1
vote
1
answer
63
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 ...
1
vote
0
answers
360
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 ...
0
votes
0
answers
135
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-...
0
votes
0
answers
86
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 ...
0
votes
0
answers
169
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&...
1
vote
1
answer
403
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 ...
0
votes
0
answers
221
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. ...
0
votes
0
answers
85
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 ...
1
vote
0
answers
98
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 ...
1
vote
0
answers
2k
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 ...
3
votes
1
answer
2k
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 ...
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, ...
1
vote
1
answer
872
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 ...
0
votes
0
answers
226
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 ...
0
votes
0
answers
352
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 ...
0
votes
0
answers
290
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. ...
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 ...
2
votes
1
answer
947
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 ...
1
vote
0
answers
282
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 ...
1
vote
2
answers
1k
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 ...
2
votes
1
answer
280
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 ...
1
vote
0
answers
89
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-...
1
vote
0
answers
517
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 ...
4
votes
1
answer
721
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 ...
2
votes
0
answers
63
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 ...
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 ...
0
votes
0
answers
283
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 ...
2
votes
1
answer
578
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/...
0
votes
1
answer
31
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 ...
0
votes
0
answers
170
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 ...
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 ...
4
votes
1
answer
722
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....
1
vote
0
answers
82
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)
...
0
votes
0
answers
42
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
2
votes
2
answers
3k
views
'gdal_merge' is not recognized as an internal or external command, operable program or batch file in OSGeo4w Shell
I am trying to batch mosaic a set of rasters using gdal in OSGeo4w shell command line. When I try to use gdal_merge I am getting error as below.
run o-help for a list of available commands
...
3
votes
0
answers
154
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"...
0
votes
1
answer
772
views
Composite bands Sentinel-2
I'm working with Sentinel-2 satellite and i'm working with 2,3,4,8 bands. I have to make composite mergining bands. I download images from https://scihub.copernicus.eu/. I used gdal_merge in console ...