GDAL (Geospatial Data Abstraction Library) is an open source translator library & set of command-line utilities for processing raster spatial data formats. As a library, it presents a single abstract data model to the calling application for all supported formats. It also comes with a variety of ...

learn more… | top users | synonyms

3
votes
1answer
335 views

Conflicts while installing postgresql9.3-postgis2.1,QGIS and gdal-bin

I want to use postgresql9.3-postgis2.1 and gdal-bin parallel . I have refer instruction here for installing postgresql-9.3 on ubuntu 12.04. I have install qgis from here While installing gdal-bin it ...
0
votes
0answers
10 views

gdal.RasterizeLayer: clip image by geometry

Stuck for few days. Trying to cut image by polygon. Have input geojson file that I convert from lat/lon coord to UTM and next need cut image by this polygon. I use 'MEMORY' to take layer in memory. ...
0
votes
1answer
50 views

How to burn geometry to raster without shapefile, just from list of coordinates?

I have a list of coordinates points(x,y) of some multipolygon like this: [[x1,y1][x2,y2][x3,y3] ... [xN,yN]] Also can convert between lat/lon and UTM coord systems. When we use gdal.Raesterize like ...
0
votes
0answers
12 views

Polylines to raster (Input: Coordinates end point of polylines) using Python [on hold]

I have coordinates of every corner of each polyline. I need to convert the polylines into a raster image using some python code. Polylines drawn can be seen in the attached figure.So, i need to create ...
6
votes
1answer
8k views

Python GDAL: Save array as raster with projection from other file

I have an array of data, and for each datapoint I know the latitude and longitude. I'd like to save it as a GTiff with the same projection as other rasters I have. This is what I've tried so far, but ...
2
votes
1answer
19 views

If keep resolution = False in gdalogr:cliprasterbymasklayer

What does it mean if i put keep_resolution = False in gdalogr:cliprasterbymasklayer? In the tool itself in QGIS I could choose then a resolution which I want to have for the output, but here via ...
0
votes
0answers
16 views

Choosing a source for elevation data (primarily US) [on hold]

I've found at least two sources for digital elevation data: The National Map and GMTED2010 Elevation Data. More sources are listed here. I was looking into building in support in my app for the JSON ...
0
votes
0answers
10 views

gdalwarp not clipping VRT to correct extent

I'm trying to clip a projected .vrt raster to an extent expressed in GCS coordinates and it's not doing what I would expect. Here is my command: gdalwarp -te -133.08813624 56.69042536 -132.69405069 ...
0
votes
0answers
13 views

Getting DEM data programmatically with libgdal?

I'm writing a specialized tool in C to work with DEM data (typically GeoTIFF files, but one of the reasons I'm using libgdal is to leverage its ability to read multiple formats). I'm able to open a ...
0
votes
0answers
8 views

Referencing DEM tif to MSL using GDAL?

I have a single band DEM tif representing elevation. How can I reference it to a datum and convert it to MSL altitudes? I'm using GDAL command line tool but don't know where to start. I looked at ...
3
votes
0answers
11 views

GDAL pre-allocates raster file

I am using GDAL 2.01 SWIG in C# to create an imagine file. When I call Create it pre-allocates the entire file, so if I am writing a 80GB file it I have to wait for it to allocate the 80GB file ...
1
vote
0answers
8 views

Return raster that intersects another raster in gdal

I'm trying to programmatically orthorectify a bunch of Rasters (.ntf format), however I need a DEM that covers each raster in order to do so. I have DEM rasters (.tif) as tiles that cover the entire ...
4
votes
1answer
444 views

GDAL minidriver and Tilecache

I'm trying to use GDAL minidriver to read tiles folders generated from Tilecache seeding. I have set this in my GDAL source <ServerUrl>http://myserver.com/test/${z}/${x}/${y}</ServerUrl>, ...
0
votes
1answer
241 views

Can't get the correct version of GDAL installed to use ReadAsArray without getting error in Python

Using the instructions here . . . https://pythongisandstuff.wordpress.com/2011/07/07/installing-gdal-and-ogr-for-python-on-windows/ I downloaded the following files: GDAL-1.11.1.win-amd64-py2.7.msi ...
1
vote
1answer
15 views

How to merge GDAL tiles and crop via a bounding box

I am using GDAL. Assume I have four adjacent GDAL tiles in the formation of a square. I have a bounding box with a corner in each tile so that the rectangle formed spans all four tiles. My goal is to ...
2
votes
0answers
14 views

Determining resolution of specific image in PDF document?

Can GDAL be used to determine the resolution of an image embedded inside a PDF? If not GDAL, is there another method? I'm using gdal_translate to convert TIF+TFW files into geospatial PDF. I know ...
1
vote
1answer
14 views

How to I replace pixel values in a single band DEM?

I have a single band DEM tif. And would like to replace values above or below a certain threshold with 0. Can I do that with GDAL?
3
votes
3answers
1k views

How to create a compressed GeoTIFF with the QGIS Clipper tool?

I have a geo-tiff created by Pix4D which is about 375 Mb in file size. I have clipped it to a smaller area using Qgis 2.8(using Raster ‣ Extraction ‣ Clipper), and the output file is about 900 MB in ...
5
votes
2answers
1k views

ESRI GDB Support in GDAL / ogr2ogr on Mac OS X 10.8

How do you incorporate support for ESRI's fgdb format into GDAL / ogr2ogr on Mac OS X 10.8?
3
votes
2answers
41 views

How to use gdal2tiles on a custom tiff image recieved from providers to generate tiles

I have been struggling a bit to generate tiles for a high-resolution image that we have. The current image we have is a very large (+20GB) image, saved as a GeoTiff file. I would like to generate ...
0
votes
1answer
66 views

Clipping GeoTIFF file by GeoJSON?

Input GeoJSON file: { "type": "Feature", "properties": { "id": 1 }, "geometry": { "type": "Multipolygon", "coordinates": [[[ [27.397511483867362, 44.161117466010516], [...
1
vote
1answer
42 views

Install GDAL python package in virtualenv on mac

I'm trying to instal the GDAL python package, preferably in a virtual environment, but when I try "pip install gdal", I get the following error: extensions/gdal_wrap.cpp:3085:10: fatal error: '...
1
vote
0answers
26 views

How to change which python GDAL is “connected” to?

I would like to use GDAL with Python 2.7 on Ubuntu 14.04. I have installed gdal-bin and python-gdal from UbuntuGIS following their instructions. However, importing GDAL (from osgeo import gdal) only ...
0
votes
0answers
13 views

Batch Process for GDAL Georeferencing in windows command line? [on hold]

I used Georeferencing using GDAL? for georeferencing images and the thing is i have lot of images in a folder and a csv file which has the image name in a column and x-min,x-max,y-min and y-max in a ...
10
votes
1answer
5k views

Georeferencing using GDAL?

I have a .tiff image that I am trying to overlay in google earth. For that I require to georeference it first. The image projection is UTM with NAD83 as datum. I know the lat/long of the four corners ...
3
votes
1answer
688 views

Uploading raster format(*.tif) to postgis through raster2pgsql

I'm new to postgis and raster file format. i currently working on netcdf files and i want to import it into postgis through curl command line tool but its failed for me.so i jump on to GDAL v1.9.2 ...
2
votes
1answer
209 views

NASA SRTM: precipitous contour lines in TileMill

I was trying to make a nice looking print map of Bali (Indonesia) in TileMill. After creating a terrain layer (using this walkthrough) I noticed that the island's coastline was precipitous. Is ...
0
votes
0answers
24 views

using gdal to convert from NAD83 to WGS84

I'm trying to use gdal in OSGEO4W to convert from NAD83 to WGS84. I'm very new to this so if you can, be as thorough as possible with your answers. The command I'm running is gdalwarp --config ...
0
votes
2answers
29 views

hdf files in GDAL throwing an error in R gdalinfo

I am having issues using some modis hdf files in R. Working on Windows 10. I had a previous question where gdal wasn't working but I think I have resolved that. I tested with existing tifs and they ...
1
vote
0answers
23 views

Segmentation fault in readasarray

I am running the following code and get: Segmentation fault (core dumped) I have no clue why, I have been using the functions many times before and now suddenly this happens. Sometimes it happens at ...
1
vote
1answer
32 views

Array written by GDAL with Python script has numbers read as “nan” by QGIS?

I would like to write an array to a geotiff with Python script using the GDAL module. When I try to do something simple like copying an existing GeoTiff via reading it to an array, then, writing to a ...
0
votes
0answers
10 views

How to integrate multiple tile outputs generated from gdal2tiles into a single google map

Todo Generated tiles from image1.tif - done Generated tiles from image2.tif - done Need to overlay these 2 sets of tiles on top of google maps - this is the problem gdal2tiles generated ready-made ...
0
votes
0answers
8 views

gdal_retile for big mosaic file

I have some big mosaic files (about 3GB, 50k x 50k) and use gdal_retile.py to generate the pyramid tiles for geoserver. It takes very long time to generate all tiles (about one day in my computer). ...
2
votes
1answer
317 views

Unsupervised raster classification using GDAL

Is there an equivalent in GDAL to the Arcpy ISO data unsupervised classification tool, or a series of methods using GDAL/python that can accomplish this?
2
votes
1answer
251 views

gdal_calc works but I get a Python error at the end of each process

I have a problem while using gdal_calc by a .bat file. Here is the code : call "C:\OSGeo4w64\bin\o4w_env.bat" gdal_calc -A"D:\tuilage_script_1\tuilage\ndvi\4_810000_6370000_820000_6360000_ndvi....
1
vote
2answers
538 views

Import error: no module named _gdal_array

I am using python 2.7 and have gdal installed. I want to read an entire .jpg image at once and so I used statement import gdal from gdalconst import * driver = gdal.GetDriverByName('JPEG') driver....
0
votes
0answers
28 views

Unable to generate tiles using gdal2tiles.py for a single band gray image

I am using and playing around with Cesium at the moment, and I am enjoying the functionality so far. I am trying to provide my own imagery to Cesium with the TMS imagery provider: imageryProvider: ...
2
votes
3answers
91 views

GDAL error in R path.expand(path): invalid 'path' argument

Using windows 10. I would like to stick to using R since that's where a lot of my pre-processing and analysis will take place for a bigger project. I have downloaded a number of MODIS files for the ...
1
vote
1answer
21 views

How do I convert WKT geometry from 3D to 2D

I'm working with kml files using Python gdal.ogr module. When I extract feature's geometry using feature.GetGeometryRef(), I get: POLYGON ((44.184069865521963 41.971859752507207 0,44.355248797385123 ...
1
vote
1answer
58 views

gdal/python WriteArray working for 8-bit but not 16-bit

I'm trying to use GDAL/python API to open a raster, do some math, then write the two resulting arrays as rastes. One is to be an 8-bit raster and the other 16-bit signed. However, only the 8-bit ...
3
votes
1answer
25 views

merge two tiles of Worldclim data with gdal_merge.py - Nodata

I am trying to merge two tiles of the worldclim data in geotiff format, which I want to subsequently work with in the raster package in R. When I use gdal's gdal_merge.py script: gdal_merge.py -v -o ...
0
votes
0answers
11 views

gdalwarp fails based on output filename? does it have to do with my using -t_srs?

I am so confused by what is going on with my gdal warp. From my terminal I can enter a command for it: $gdalwarp -t_srs '+proj=ortho +datum=WGS84' test_imagery/Maui/OBS_IMAG.nitf testout3.tif ...
1
vote
1answer
58 views

GDAL python cut geotiff image with geojson file

I wrote the function which cutting geotiff image by bounding box. First image is original. At second you can see result off my code. I don't use gdalwarp or any console utilities. But I have no idea ...
4
votes
1answer
210 views

Tabulate Area using GDAL and Numpy

How could I perform a Tabulate Area using GDAL and Numpy? I am trying to summarize how many pixels of each class in a Landcover raster are within each polygon of a Census Blocks shapefile. I've ...
2
votes
1answer
45 views

Clip raster with shapefile and set a value outside the mask

I want to clip a raster using a shape file with the command: gdalwarp -cutline INPUT.shp INPUT.tif OUTPUT.tif from this answer. However I want to set the pixels outside the mask to a particular ...
1
vote
0answers
42 views

Is there any difference between gdal_proximity.py and ArcGIS Euclidean Distance?

The gdal_proximity.py description says: The gdal_proximity.py script generates a raster proximity map indicating the distance from the center of each pixel to the center of the nearest pixel ...
1
vote
1answer
1k views

How do I add elevation data to a GeoJSON line from a GPX file?

I understand that elevation can be added as an optional third value in Coordinates (lat, long, elev) in a geojson file, but I can't find a way to actually do that from a gpx file. I've used ogr2ogr to ...
3
votes
1answer
103 views

GDAL Python cut geotiff image

I was stuck for 2 or 3 days. I have read many lectures from RS/GIS Laboratory of Utah State University. Also I read «Python Geospatial Development» book and many docs from gdal.org. So, my problem ...
1
vote
1answer
186 views

Accessing bands in .pix (PCIDSK) file in python/arcpy

I am trying to perform zonal statistics on a single band from a multi-band raster in .pix format. I have things working great with a tiff file. I am able to access the bands using this code: desc = ...
5
votes
2answers
2k views

how would one get the end points of a polyline?

I am attempting to write a script to get the end points of a series polylines, and then use those end points to create a polygon. I'm not sure which tools to begin to use on this project. I would ...