Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [gdalwarp]

A Geospatial Data Abstraction Library (GDAL) image mosaicing, reprojection, and warping utility.

0
votes
0answers
9 views

How to set correct geo information on pleiades images with RPC model?

Now I have pleiades raster (img.tif) and a RPC model (rpc.XML). In the rpc.XML, there are the following lines which can be used to reset geo information. <RFM_Validity> <...
1
vote
1answer
33 views

Using GDAL to strip nodata in border regions only?

I am trying to create a script that given a tiff file with islands of data (which can be disjoint) and black pixels of nodata, can generate polygons (or new tiffs) that only wrap around the islands of ...
0
votes
0answers
19 views

Gdalwarp producing odd results around 0 degree longitude

I am warping ECMWF grib data (full globe, 0.25 degree resolution) to match the SEVIRI geostationary satellite projection. I use this command: gdalwarp -overwrite -ot Float32 -t_srs "+proj=geos +a=...
2
votes
1answer
26 views

Python Fiona affecting external GDAL binaries?

Curious if anyone else has encountered this before and may have an explanation: In my Python workflow, I'm importing fiona (1.8.4) to manipulate shapefiles, and then later downstream I'm shelling out ...
1
vote
1answer
36 views

GDALWARP cuts off right edge of image?

I'm reprojecting GFS GRIB files to EPSG:3857 using gdalwarp. Resulting file get little bit shorter to the right so when I zoom in from zoom level 5 and higher, I can see vertical line with missing ...
1
vote
1answer
27 views

GDAL crop ECW file with coordinates

I am looking to crop an ECW image based on latitude and longitude. I have the following code to do that but it doesn't work. <gdalwarp -t_srs EPSG:27700 -te 51.50386 51.50391 -0.4333941 -0.4333865 ...
1
vote
2answers
52 views

Reproject MODIS data using R (results in NAs or no spatial extent)

I am using GLASS albedo data stored here for pre-2000 (AVHRR) data and here for post-2000 data (MODIS). My end goal is to create a raster stack of each month that contains white sky albedo data from ...
0
votes
0answers
76 views

Clip to mask layer not adhering to expected width and height following CRM and resolution changes

I am attempting to take a simple opentopo heightmap and carry out the following in QGIS 3.4.1 - Reproject to UTM 31N - Set cell size resolution to 5mtr - Clip to a shapefile polygon feature exactly ...
1
vote
0answers
36 views

GeoTIFF to KMZ using gdal_translate produce imagery with bad colors

I have a TIFF file which is georeferenced in UTM coordinates. So as a first step, I convert the UTM TIFF into a WGS84 TIFF using gdalwarp. On the next step, I used gdal_translate to convert a TIFF ...
3
votes
1answer
30 views

gdal.Warp() returns different results on 2.1.0 and 2.3.2

I upgraded GDAL version from 2.1.0 to 2.3.2. Both versions I built from source with Python bindings. PROJ version - 5.2.0. Expected behavior gdal.Warp() returns the same result as in 2.1.0 Actual ...
1
vote
0answers
18 views

Setting both spatial extent and resolution when using gdalwarp?

I would like to overlay two tiff image that orginally have different projections. One is MODIS sinusoidal and the other one is WGS84. I use gdalwarp to re-project the latter into the same projection ...
-1
votes
0answers
20 views

GDAL API - Reproject GRIB2 file without writing intermediate file to disk

I'm trying to reproject grib2 file and as seen in this post it is possible with gdalwarp/gdal_translate command-line tools. I was hoping that with GDAL API I would be able to skip step of writing ...
0
votes
0answers
14 views

Batch Script for Reprojecting Raster Images with World File

Can someone help me to create a routine for converting a batch of folders and their contents? They are ortho aerial rasters, in TIFF format. With TFW files. Tiled and single. I'd like to be able to ...
0
votes
1answer
23 views

gdal.Warp cutline creates empty file when run on the server, but works perfectly fine through Python command line

Trying to cut geotif with a shp file. When I open Python command line interpreter and run from osgeo import gdal gdal.Warp(outfile, infile,format='GTiff', cutlineDSName=shpfile, srcSRS='EPSG:4326',...
2
votes
0answers
60 views

Using max as resampling method with gdal_translate?

My Issue According to the docs it appears that gdalwarp has many more resampling methods than gdal_translate. Can anybody explain why the resampling methods can't be used with both functions? ...
3
votes
0answers
51 views

Why can't I transpose a raster across the pole with rasterio or gdal, and how could it be done?

I have a raster in e.g epsg:4326, it covers all world, from 180E to 180W, from 90S to 90N. I want to re-project a part of it to epsg:3031 and also change the grid size and resolution. Here is a ...
1
vote
1answer
129 views

Using gdalwarp with c# bindings?

I want to change projections for images using gdal bindings for c#. Gdal_translate seems like just renaming of projection (using a_srs parameter), but not reprojecting, so I used gdalwarp with s_srs ...
1
vote
1answer
25 views

Feeding gdalwarp with binary data instead of ascii, how to specify header information

I have a working pipeline where I download a tar.gz file which contains multiple binary files in the german RADOLAN format (Translate PNG obtained through RADOLAN from DWD's projection to EPSG:...
2
votes
3answers
279 views

Clipping GeoTIFF with shapefile?

I have a GeoTIFF file and a shapefile. I want to clip the GeoTIFF file using the polygons defined in the shapefile in such a way that it produces a separate output for each polygon (which is different ...
1
vote
1answer
111 views

Error using QGIS 3.2.2 Warp (Reproject) tool with custom coordinate system

I'm using the QGIS Warp (Reproject) tool to reproject a raster from WGS84 to a Lambert Conformal Conic custom projection in QGIS 3.2.2. The call to the GDAL/OGR console is the following: gdalwarp -...
0
votes
1answer
81 views

gdalinfo and other applications not running through Anaconda Prompt

I am using GDAL 2.0.3(installed through wheel) in Anaconda 4.2.0 with Python 3.5 installed. I am able to import GDAL in my code. But whenever I am trying to run gdalinfo and other applications(such ...
0
votes
1answer
44 views

GDAL - Unable to convert to Web Mercator using gdalwarp

I am making geoTIFs of weather data (for a Mapbox overlay) and I am converting them to web mercator for use on the map. The images were generated from the same source file and both images have the ...
1
vote
1answer
118 views

Efficient downsampling with GDAL?

I have a 350go GeoTIFF file with DEM data for the entire world. (a mix of SRTM, EUDEM, etc. ...) This TIFF file is tiled with a block size of 256*256. I would like to downsample this file to a lower ...
1
vote
0answers
71 views

reprojection and write grib files

I'm working on GRIB file, In input, I have the file with data from 0 to 360°. As gdalwarp does not write GRIB file (only gdal_translate), I use gdal warp to projct data from [0,360] & [-90;90] to ...
1
vote
1answer
40 views

Why doesn't QGIS georeferencer support gdal scripting for projective transformation?

I am georeferencing drone images with QGIS, and the transformation method that gives the best results is the projective one. As I have many images, I would like to write a gdal script to automate the ...
2
votes
1answer
38 views

GDAL processing of GRIB2 raster prints hundreds of unsuppressable warnings

I am processing some GRIB2 raster files from NCEP (weather model stuff). An example file would be: http://nomads.ncep.noaa.gov/pub/data/nccf/com/hiresw/prod/href.20180906/ensprod/href.t00z.conus.mean....
0
votes
0answers
77 views

GDAL interpolation ignores edges with nodata vals

I have a grib file with weather data in 0.25-degree resolution and I want to upsample its higher resolution. I used gdalwarp: gdalwarp -t_srs EPSG:3857 -of GTiff -wo SOURCE_EXTRA=1000 -wm 2000 --...
1
vote
1answer
28 views

gdalwarp: differentiate between empty-in-source and outside-of-cutline?

I'm using gdalwarp to clip a polygon out of a map layer using --crop_to_cutline. The original map layer has a lot of empty pixels (well, transparent / alpha=0, to be precise). As it stands, my output ...
1
vote
1answer
50 views

Very large VRT file generated by gdal after cutline

In Python, I generate a virtual raster using gdal warp with a cutline as per below gdal.Warp(warpedFilePath, ds, format = 'VRT', cutlineDSName = csvFilePath, srcNodata = 0, dstAlpha = True, ...
1
vote
0answers
23 views

Creating polar-stereographic projection of HDF data subset?

I have an HDF4 file. I would like to create a geotif file containing a polar-stereographic projection of one of the HDF4 data sets. I've tried using gdalwarp. This works for some projection types, ...
2
votes
1answer
69 views

GDAL reprojection 4326 to 3857 creates gap

I have an EPSG:4326 tif covering the world that I need to reproject to EPSG:3857 in order to use it with Mapnik to create a map. When displaying the original tif and leaving Mapnik doing the ...
0
votes
0answers
35 views

gdal.Warp workingType option default

I have been using gdal.Warp() in Python 3.6 for some time now and have just noticed the workingType option (see here for gdal.WarpOptions()). From its definition: workingType --- working type (...
0
votes
0answers
32 views

remove white outline artefacts after gdalwarp/gdal2tiles

I am struggling with the similar problem as described here but with some differences: every raster I project twice using GDALWarp - into their initial projection (raster + .tfw) and then to EPSG:3857 (...
0
votes
1answer
29 views

GDALReprojectImage (C++) quiet

I am using the GDALReprojectImage method from gdalwarper.h. Is there a way to suppress the output? The function has GDALWarpOptions * psOptions as an input but there in no quiet option. I have seen ...
0
votes
1answer
176 views

Extracted GeoJSON from TIFF

If there are a way to do call("gdal_contour -i 10 -f GeoJSON".split(' ') + [file1, file2]) as Python call method of some library? Not via command line call and intermediate file storing?
1
vote
1answer
63 views

gdal_translate and gdalwarp do not close when converting an ecw file to GeoTIFF

I'm trying to convert a portion of a fairly large ECW file to a GeoTIFF using either gdal_translate or gdalwarp. The problem I'm having is that the GeoTIFF is generated but gdal_translate and ...
1
vote
0answers
61 views

gdal: WMTS is working with 256x256 tiles, but not with @2x (512x512) tiles

I'm working on using imagery from a web map tile service which I've cached locally as a gdal dataset. I have both 256x256 tiles and 512x512 tiles; the latter are the "retina" versions of the former; i....
0
votes
0answers
25 views

rasterio.warp.reporject: works incorrectly on big regions?

I want to reproject a big region of territory to ortho projection. For example, I take a raster of whole Earth in longlat projection and reproject it to ortho (make a view of whole Earth in ortho ...
0
votes
1answer
72 views

Using gdalwarp to merge bands into a mosaic created by gdal_merge?

I have created a mosaic with gdal_merge.py using the following command: gdal_merge.py -createonly -separate -co PHOTOMETRIC=RGB -o merged.tif LE07_L1TP_046030_20180810_20180810_01_RT_b3.tif ...
2
votes
0answers
177 views

gdal_warp with huge tif: integer overflow

I retrieved the SRTM 1" data and merged it in one huge tif. Now I want to warp it. It's working fine for low resolution (eg 5000, 1000, 500), but it doesn't for 90m resolution. I'm using this command: ...
0
votes
2answers
41 views

gdalwarp not clipping to index grid

I am using the 4 corners of a grid to clip a raster to it with gdalwarp with the following code: pkdumpogr -i index.shp -n left1 -n bottom1 -n right1 -n top1| while read Block_ID left1 bottom1 right1 ...
0
votes
1answer
24 views

gdalwarp for clipping images using multiple polygon in a bash shell for loop

C:\OSGeo4W64\bin\gdalwarp.exe -dstnodata 0 -q -cutline D:\hillsborough_Images_work\split_Polygon\120-140k\Hillborough_FINAL_140000_region_IGD_120570003d29ed0dc.shp -crop_to_cutline -dstalpha -tr 0....
0
votes
0answers
64 views

gdal: apply orthorectification to ogr dataset

I'm trying to process Digital Globe L2A image with gdal utilities (e. g. this one: https://www.digitalglobe.com/resources/product-samples/washington-dc-usa) I am using SRTM digital elevation model to ...
0
votes
0answers
26 views

What transformation is used for EPSG 28409 in GDAL?

I used gdalwarp to convert a raster file in EPSG:4326 to one EPSG:28409 I believe that using this method doesn't apply a full transformation as there is no option to select between the numerous ...
0
votes
0answers
65 views

Output arrays from Rasterio masks of Sentinel-1 prodcuts from the same shapefile are not the same shape

I am masking Sentinel-1 data using rasterio.mask.mask. I had first reprojected all Sentinel-1 products I have downloaded using command line gdalwarp as Sentinel-1 data is georeferenced but no ...
0
votes
0answers
117 views

Raster color after crop image by mask with rasterio

I have stacked 4 bands of Sentinel which have 10 meter of spatial resution. I I did it with command above: command = 'gdal_translate SENTINEL2_L1C:{scene_file_name}.SAFE/' \ 'MTD_MSIL1C....
1
vote
0answers
73 views

Problems with S3 georeferencing using Python-GDAL [closed]

I have to work with many Sentinel 2 and 3 images, with two different algorithms. I have to treat both images separately but only with Python and GDAL. Concerning Sentinel-2 images, I download them on ...
0
votes
0answers
14 views

GDAL WARP where geotif goes from west to east hemisphere [duplicate]

I'm using gdalwarp to reproject an elevation geotif downloaded from http://srtm.csi.cgiar.org/SRT-ZIP/SRTM_V41/SRTM_Data_GeoTiff/srtm_70_22.zip Using the following command gdalwarp -s_srs EPSG:4326 ...
0
votes
1answer
49 views

GDAL-Georefrencing already Georefrenced single band Raster

I am trying to georeference already georeferenced single band raster data using GDAL with four GCP's. Input image is having Coordinate system GCS- WGS1984 (EPSG:4326). Following Command is run on ...
0
votes
1answer
133 views

FAILURE: No target filename specified

Each time I run gdalwarp -te 212051.9319179999874905 214051.9319179999874905 183962.2946890000021085 Quada.tif Clipped.tif I get the following error: FAILURE: No target filename specified. Any ...