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

1
vote
1answer
411 views

Import shp to Postgis using Python and ogr

I just export a Postgis Table to shp using this tips but I'm not able to import a shp to Postgis using the same library(ogr). Any idea? Thanks a lot f.
1
vote
2answers
55 views

Remove unneeded columns from geographic data file?

I have some GML data that has some unneeded columns in it. I'd like to remove these columns in order to reduce the file size. (To clarify: I mean that the file has many points in it, and each of these ...
1
vote
0answers
27 views

ogr2ogr giving “ERROR 1: Failed connect to 192.168.4.18:8181; Operation timed out” error?

This is my command, which was working OK yesterday: ogr2ogr -f "GeoJSON" ../geojson/myfile.geojson ../data/gml/myfile.gml -s_srs EPSG:27700 -t_srs EPSG:4326 The output is this: ERROR 1: Failed ...
0
votes
0answers
73 views

Fantasy map, how do i slice large png and georefrence it the right way?

Im and IOS developer working on a map based ios game, and new to GIS stuff. I've read a lot of info and i started to get a hint about what i need to do in order to meet my goals. I have a png map i ...
0
votes
1answer
74 views

why is map tiling computationally intensive?

I recently starting using gdal2tiles.py (and its parallel implementation) to generate tiled images from raster datasets for kml interpretation and I'm shocked by how computationally intensive the ...
0
votes
0answers
88 views

Adding vector layers on top of gdal rasterized image

I used gdal2tile.py on a big image (actually its screenshots of image map) and now I have a nice openlayers-powered map I can pan and zoom around. But now I want to add a vector layer on top so I can ...
0
votes
1answer
638 views

AttributeError: 'module' object has no attribute 'Open'

Hy, I am running the following code which I found on: GDAL - Perform Simple Least Cost Path Analysis which I adapted to my case, but I get the following error when running the code in the python ...
0
votes
0answers
62 views

How to use ogr2ogr to remove features from a shapefile using sql statements (Unable to open datasource `action/North' with the following drivers.)

OK, I've spent the obligatory 15-25 minutes on this and haven't gotten anywhere so, here's the command I'm trying to get to work right now: ogr2ogr -f "ESRI Shapefile" -where "area > 4000" ...
3
votes
1answer
584 views

Georeferencing an image with GDAL, based on QGIS Georeferencer Plugin

I would like to georeference an image with GDAL. The image already has a spatial reference set (EPSG:31276). For the georeferencing, I have a list of 4 ground control points (also in EPSG:31276). ...
6
votes
1answer
166 views

GDAL equivalent of ArcGIS Mosaic

The word 'mosaic' is often used for quite different things within the worlds of ArcGIS and GDAL. With GDAL and it's downstream applications like Qgis it is common to see mosaic used in the context ...
2
votes
1answer
74 views

File size inflation normal with gdalwarp?

After using gdalwarp to project and align-to-grid (via -tap) a number of rasters I noticed that the output rasters were significantly larger than the original rasters. A fairly thorough web search ...
1
vote
0answers
83 views

How can I draw features on GeoTIFF in Python?

I have a set of data (coords + value) and want to turn it into a heatmap in GeoTIFF. Should I calculate pixels and set them as array, or there are shortcuts? This is what I do now: driver = ...
0
votes
0answers
15 views

save a WMS image on disk and apply a classitem (gdal commands?)

I need to save an image on disk trough WMS coloring the pixels applying a CLASSITEM (e.g. Mapserver CLASSITEM). Is it possible using gdal, if so, how? Thanks in advance, D
1
vote
1answer
91 views

Set a RANGE of values as nodata in a .vrt?

Is it possible to set a range of values to nodata in a vrt file? How? I have some elevation models with incorrect values, down in the -15,000s. I could just clip the rasters along that edge, or apply ...
1
vote
0answers
29 views

Problem defining the tiling starting point

We are tiling a image datasets. However, we want to specifically define custom windows. To do this, we are using -te option during warping. The warped output is then tiled. The problem though is that ...
0
votes
1answer
33 views

Missing Layer in OpenLayers

When I try to include the "fwp layer" from geoserver 2.4 (Ubuntu 12.4 VServer) into my code it doesn't show up. But the geoserver layer preview (OL) shows the right image. The GeoExplorer preview ...
3
votes
3answers
384 views

Per-pixel (statistical) calculations on a raster stack using GDAL

In R, it's relatively trivial to perform per pixel calculations based on a raster stack (e.g., get std.dev for each pixel on a 12 layer GeoTIFF). Unfortunately, the speed is less than desirable when ...
0
votes
1answer
106 views

gdal's polygonize function (via qgis) is not turning monochrome rasters into readable shapefiles regardless of inversion of color scale

I've tried polygonizing this monochrome bitmap as this: and this: and either way it ends up looking like this when (zoomed in) after gdal's polygonize operation: Is there any way I can tell ...
2
votes
2answers
416 views

GDAL Conversion of US Topo GeoPDFs

I've used GDAL_translate with "--config GDAL_PDF_LAYERS" option to convert US Topo GeoPDFs to GeoTIFF and it works great for creating collarless topos based on the new format. However, I can't get it ...
3
votes
1answer
303 views

ArcGIS Raster Mosaic Dataset and GDAL VRT, when to use?

ArcGIS has a the Raster Mosaic Dataset, QGIS and friends have Virtual Raster Tables. A skim of the documentation reveals much similarity. They both create or enable an alternate representation of ...
0
votes
0answers
161 views

ECW files to geoserver 2.4

I'm trying to add .ecw files (20 orthophotos) to geoserver 2.4. Geoserver is running on an ubuntu 12.4. Vserver. I'v already installed the GDAL plugin. Is this the right format for the ...
0
votes
1answer
203 views

How can I correct a .pgw file for a PNG image?

I have a PNG file and I need its .pgw file to be set with NAD 83 as the projection. I have created a .pgw file: 799 0 0 -799 -122.562 37.1946 However when I open the PNG in QGIS or ArcMap 10.2 it ...
2
votes
0answers
34 views

GeospatialPDF javascript access

Using javascript in GeospatialPDF, is it possible to zoom in to an extent, say when the document is opened the first time ? To what extent can I use javascript to access the geospatial data? pan, ...
0
votes
1answer
59 views

Is it possible to get all projections form OGR?

I'm working on a project where the user can give my program so GIS data which may or may not have which projection it is using. So is it possible to get a list of all the projections from OGR or ...
1
vote
1answer
116 views

gdal2tiles generates small picture inside 256x256 tile

I've used gdal2tiles for generating tiles in number of different polar projections and always experienced the same problem — strange small picture inside normal 256x256 png with the rest of space ...
0
votes
1answer
71 views

Cannot display Oracle raster images using QGis

I am dealing with QGIS 2.2 and the plug-in Oracle spatial georaster. Apparently the connection to the database can be made, as the raster images are listed once you press 'Connect', but when try to ...
1
vote
1answer
191 views

ogrinfo sql example

I'm having trouble learning how to query my shapefiles for certain features. I have a shapefile that looks something like this when I summarize it using the following command: ogrinfo -al -geom=OFF ...
1
vote
1answer
224 views

datum conversion with GDAL

I run gdaltransform like so: gdaltransform -s_srs nad27 -t_srs wgs84 -104.5 39.5 -104.5 39.5 0 gdaltransform -s_srs wgs84 -t_srs nad83 -104.5 39.5 -104.5 39.5 0 gdaltransform -s_srs nad27 ...
4
votes
2answers
491 views

How to access Shapefile metadata using OGR?

I'm trying to use ogrinfo to get some details on a shapefile I downloaded. Currently, the only way I know how to do this is to load it into QGIS and manually click around to find any information on ...
0
votes
0answers
13 views

UnIntersected part of gdal-geometry?

i have a rectangle and polygon geometries . polygon.Instersection(rectangle) gives me the polygon as it is inside the rectangle. But , what i want is the unintersected(non-intersecting) part of both ...
2
votes
2answers
201 views

How to batch “gdal_merge” on Win7 in one command line command?

I want to create a mosaic of all tif files in a directory on windows 7. How could I create a one-line command in the windows command line to loop through all tifs and merge them all together using ...
1
vote
2answers
268 views

I need to extract a specific layer from a Geospatial PDF using GDAL/OGR

I have GDAL/OGR 1.10 installed on a 64bit Windows 7 machine. I have some Geospatial PDFs that I want to crop to the outline of the map and convert to Rasters. However I cannot clip to the neatline. ...
2
votes
1answer
60 views

GDAL not accepting *.tif to list through files in directory

I am using gdal_merge.py to mosaic tif. If I explicitly write the file names it works, but if I use *.tif it fails with the following error. Traceback (most recent call last): File "C:\Program ...
1
vote
1answer
169 views

install gdal extention in GeoServer

I am trying to install the GDAL extension (I want to use ecw files in GeoServer). So here is what I did so far: 1) downloaded the GDAL extension and extracted to: C:\Program Files ...
0
votes
0answers
95 views

command line alternates for softwares like tilemill, maptiler

tilemill works just fine for my needs but , i want to do the whole process on command line . since new geotiff files are going to be added in my project, and i need to automate this whole process . ...
0
votes
0answers
63 views

gdal2tiles colorpallete error

merged few files using gdal_merge gdal_merge.py -pct -o 713.tif sa713.tif na713.tif wa713.tif ea713.tif When i try to make tiles it says gdal2tiles.py: error: Please convert this file to RGB/RGBA ...
0
votes
1answer
156 views

How to get the pixels from a geotiff file in gdal python for a given bbox?

I have a GeoTIFF file in WSG 84 Projection reference (it's a GeoTIFF of SRTM). I can use python & gdal to read the whole lot of data into an array (with ReadAsArray()), but I want to only have a ...
0
votes
1answer
119 views

Convert a KML ImageOverlay to World Files with GDAL

I have many raster outputs from an Open Source radio transmission topographic path tool called SPLAT, georeferenced in KML image overlay format. I have figured out an easy way to use tools to ...
2
votes
1answer
211 views

PostGIS Raster in MapServer

I'm having trouble getting a PostGIS raster to load and display in MapServer. I'm not sure, but suspect it's a version problem. My mapfile layer and the error message are shown below. LAYER ...
2
votes
2answers
1k views

How to convert a .tif with .tfw to a GeoTiff?

I have a tif image file, and a .tfw world file (created from OSM data with Mapertive). How can I (using linux command line) convert that to a GeoTIFF file? (i.e. I want to have one file, not 2). I'm ...
0
votes
1answer
182 views

Create Tiles for a raster(georeferenced) to use in leaflet

I have raster, with each pixel containing some data. What i want is to split a large image with each pixel's color is determined by its value, to show on leaflet layer.How to go about this ? raster ...
1
vote
0answers
71 views

Extra row and column in a raster after GDAL grid import

I'm exporting an ESRI grid to TIFF format and after that I'm reading this exported raster file into SAGA GIS. However when Saga reads this file in there appears to be an additional row and column in ...
0
votes
0answers
90 views

GEOS assertion failed

The following script fails, if I import the 'rasterstats' library. import rasterstats import ogr geom1 = ogr.CreateGeometryFromWkt('POLYGON ((415924.806155724043492 ...
2
votes
1answer
81 views

How to use GDAL to import lat/lon points from ESRI File Geodatabas into MySQL

I have a file geodatabase from here: ftp://ftp.csc.noaa.gov/temp/MarineCadastre/AIS.SampleData.zip Using ogrinfo, I can see that it contains a layer called "Broadcast_" that has lat/lon points: ...
3
votes
3answers
163 views

how to digitize areas of a raster and snap to the raster cells?

I need to digitize the extent of an ecw raster image where the RGB value is not black.(see attatchment)ie. not the envelope, just the area where the image is shown without the border areas. The black ...
1
vote
1answer
114 views

WKT for local mine grid

I have been trying to create a WKT entry to use in gdalwarp etc. I need an affine transform from coordinates in MGA94 Zone 54 to our local mine grid. All efforts have so far failed, including using ...
0
votes
0answers
38 views

How do i install liblas using OSGeoW4

I have downloaded and installed the OSGeo4W program on my system. I recently downloaded gdal file and liblas. When i try opening the osgeow4 shell, it keeps telling me the gdal file is missing. when i ...
0
votes
1answer
45 views

Missing Georeferencer

I installed Qgis Master 64 bits on win7 64 16gb of ram and I am unable to locate the georeferencer. All other Gdal application are there, Gdal is active, but no georeferencer. I tried yesterday, ...
1
vote
1answer
893 views

Clip raster layer with *raster* mask layer in QGIS

Given two input layers 1. The clip layer - an arbitrary layer (though in my case it's a float 1 band geotiff) 2. The mask layer - a paletted raster in which every pixel is either NO DATA or a single ...
2
votes
2answers
47 views

Comparing projections of two datasets when SRID not available

Similar to this question: How to test if two GDAL datasets are in the same projection? However, the above does not cover cases where an SRID is not available. It can often be the case that an SRID is ...