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

0
votes
0answers
29 views

gdal_merge.py import gdal error

normal Gdal utilities work. gdal utilities with .py extension do not. they had worked very recently, within the last two months. checked the path variable and python version called from the command ...
1
vote
2answers
32 views

gdal_calc : fails with value 0?

I working to invert values of a one-band tif files (download sample). If i use 254 it works: $ gdal_calc.py -A ./shadedrelief.tmp.tif --outfile=whited.tmp.tif --calc="254*(A>180)" 0 .. 10 .. ...
0
votes
1answer
24 views

How to pass value of a band to and other band and change its value?

Using gdaldem hillshade, I get a one-band hillshade (download here, 2MB) : gdaldem hillshade crop_xl.tmp.tif Shadedrelief.tmp.tif -s 111120 -z 5 -az 315 -alt 60 -compute_edges I currently can ...
1
vote
1answer
40 views

gdal_contour is missing lines below a certain elevation

I have a very strange problem with gdal_contour. I have a very large GeoTif of Europe and would like to generate contour-lines for that region. Everything worked fine when I had lines every 25m but ...
8
votes
2answers
262 views

Migrating from ArcGIS to gdal

I would like to collect a table of equivalent or close enough gdal based functions to replace ArcGIS functions (esp in spatial analyst). Are there functions available using gdal to perform the ...
17
votes
2answers
384 views

How to create transparent hillshade?

I get elegant transparent hillshades via a combination gdal and convert. Compare to grey-based hillshade commonly used, such transparent hillshades are very cool because they can be placed between the ...
3
votes
1answer
31 views

Reprojecting to same srs shifting the layer

I am using ogr2ogr to reproject a shapefile. Here is what I have done. I have a shapefile A.shp. I used the following command to create B.shp: ogr2ogr -t_srs EPSG:3857 B.shp A.shp Now I reprojected ...
0
votes
1answer
37 views

Merging SHP lines with attribute data combined?

I have one shapefile which contains hiking routes and another shapefile which has ski routes. Sometimes they follow the exact same path. In QGIS if the lines mentioned above are in the same SHP I ...
1
vote
2answers
72 views

Generate PNG/JPG maps from multiple ASCI/GeoTIFF in Python/GDAL

I need to generate maps (saved in PNG, JPG or PDF) from raster files (for each file - one map) which meets following criteria; * each map has exactly the same color pallette, so that it will be easy ...
0
votes
0answers
29 views

Creating geoTiff from MBTiles

I have mbtiles file with various zoom levels (8-14) and I want to create geotiff file from it. I think that this could be acomplished with gdal but I dont know how. Any suggestions on how to complete ...
0
votes
0answers
7 views

Missing importfromURN method in gdal java wrapper

The java wrapper of gdal doesn't have the method importFromURN, and I want to use the projection system which is specified in the URN string format. Is there a way in which I can do that? Maybe I can ...
0
votes
3answers
54 views

Using GDAL/C++ to calculate distance in meters

I'm using GDAL in C++, with WGS84. I want to calculate distance between two points in meters. The code snippet below tries to find the distance between 25N/75E and 25N/76E. The code, as is, returns ...
1
vote
0answers
39 views

Suppress verbose output when something goes wrong with ogr2ogr

Whenever ogr2ogr is not able to read a file, it seems to produce pages of output: Unable to open datasource `file.geojson' with the following drivers. -> ESRI Shapefile -> MapInfo File ...
0
votes
1answer
35 views

How to setup GDAL setting for python using OSGEO4W?

I have installed OSGEO4W installer. In that I have installed Express Desktop install option. QGIS GDAL uDig and GRASS GIS were installed in C:/OSGEO4W64. I have added 'C:/OSGEO4W64/bin' in the path. ...
1
vote
1answer
60 views

How Does Ogr2Ogr Simplify Work?

Can someone explain how the ogr2ogr simplify works? I am trying to use raster data which has a spectral resolution of 30m. The vector file that I am trying to import into Google Fusion is large in ...
0
votes
0answers
7 views

Error in using gdal java binding

I am using the java binding of gdal to project a set of coordinate points from UTM to lat/log using the CoordinateTransformation Class of gdal. I have written the code as follows: ...
0
votes
2answers
19 views

gdalwarp changing value in nodata pixels

I'm using gdalwarp to convert MODIS NDVI mosaics from Sinusoidal to epsg:4326. To save space I'm using VRT files until I reach the final product. Here is my workflow. Mosaic NDVI Modis tiles using ...
0
votes
0answers
12 views

Different KML size from ArcGIS and Ogr2Ogr

I have been converting shapefiles to KML. It seems that using ArcGIS to make a KML (by converting shapefile to feature layer and then using feature layer to kml tool) results in a much larger sized ...
1
vote
1answer
24 views

Most efficient way to retrieve pixel distributions inside many polygones (custom zonal stats)

I want to get the distribution of pixels from a 1 band raster that fall in each polygon of a shapefile to proceed to some statistics. I guess a zonal statistics does it in some kind of way but I need ...
3
votes
1answer
23 views

How do I call ogr2ogr from a C# application?

I have an ogr2ogr (GDAL) command that I run to export points from a database to an XML file. ogr2ogr-f GPX c:\temp\points.gpx PG:"host=localhost port=5432 dbname=SpatialPlayground schemas=public ...
0
votes
1answer
57 views

OSGeo4W and GDAL - gdal2tiles.py error

Wondering why gdal2tiles is throwing errors, I've added the gdaldata and gdalplugins environmental variables and my python is at Python27/ArcGIS10.3/, and am wondering if that is messing with the ...
0
votes
0answers
19 views

Cutting a shape from a VRT file with gdal warp

I have a couple of overlapping tif files which I want first to merge and then to clip a shape file from the result tif. The problem is that the tifs are pretty big and when the tiffs are overlapping ...
2
votes
2answers
81 views

Can't connect to foreign SQL Server table from PosgreSQL using OGR_FDW

I'm using Windows 7, with PostgreSQL 9.3.6 installed and PostGIS 2.1.5. While I wish I could get everything into PostgreSQL, I can't and need to connect to another server running SQL Server. I need to ...
0
votes
2answers
75 views

Convert a tiff Float32 image to 8bit tif (or jpeg) image using GDAL and Python

I need to convert a Float32 tiff image to 8bit format in order to display the image in a web page. In order to do that I need a jpg image but this conversion is not correctly done with GDAL because ...
1
vote
2answers
99 views

How to read ESRI File Geodatabase (FileGDB) with OGR?

I have a file ending with *.gdb. I don't know what it actually is. I also don't know what to expect inside the file. I am trying to access it with ogr. I tried with ogrinfo: ogrinfo test.gdb ERROR ...
0
votes
1answer
45 views

Facing a problem when re-projecting a file?

I am trying to re-project from Equi-rectangular (Projection=EQR) to the NASA global EASE grid (Equal Area Scalable Earth) grid 1383 586 with a ~25 km cylindrical projection (ESPG=3410). The file is ...
0
votes
1answer
21 views

converting grib to netcdf with time dimension

I'm trying to convert grib files to NetCDF. The grib files contains subdata sets which are time related. Using the netcdfAll Java library with the NetCDF-4 C library works fine. java -Xmx1g ...
1
vote
1answer
29 views

Is EPSG:3857 the correct projection for my PDF in Lambert Conformal Conic projection?

Given the following NEATLINE from the results of gdalinfo on my Geospatial PDF: NEATLINE=POLYGON ((-1340591.5297333347 -260482.28440259479,-1340591.0579001249 1878014.4171204455,3081498.0723039531 ...
1
vote
0answers
41 views

Problems coloring features of file geodatabase in QGIS

I managed to open a file geodatabase (.gdb) in QGIS. The extensions of my data are correctly shown and the attribute table shows all values correctly. However, when I double-click on the layer to ...
3
votes
1answer
83 views

Grass NVIZ has no output in QGIS 2.8.1 ubuntu 14.04

I am trying to use the Grass7 NVIZ algorithm from the QGIS 2.8.1 toolbox, on ubuntu 14.04. I have enabled Grass7 in the QGIS processing preferences. I have compiled Grass7 from source, and Grass ...
0
votes
0answers
24 views

HDF to Geotiff conversion

can anyone tell the program code or script for converting HDF files to geotiff using MRTSwath tool? I've downloaded MODIS Files for fog estimation but i couldn't find how to process them.
2
votes
0answers
41 views

Reverse parameters of a projection map

I'm user of a soaring simulator named "Condor Soaring". This simulator is at the center of a community of enthusiastic people who build sceneries (landscapes) which represents quite accurately real ...
0
votes
0answers
27 views

What driver should I use when trying to open a Geospatial PDF with OSGEO and Python?

My code is as follows: from osgeo import ogr from osgeo import gdal dso = ogr.Open('myfile.pdf') print dso dsg = gdal.Open('myfile.pdf') print dsg driverGeoPDFogr = ogr.GetDriverByName('PDF') ...
0
votes
0answers
21 views

Calculating a proper slopemap using GDAL

I have a DEM GeoTiff where I already calculated a hillshading and it looks perfect. Now I'd like to create a slopemap so that I can mark parts of a mountain that are very steep. The problem is that ...
0
votes
0answers
18 views

QGIS Import Interlis name of attributs

Why if i import Interlis 1 files to QGIS 2.8.1 / 2.6.1 there is no identification of the attributs names in each tables? The interlis model is correct (I've also tested an ITF-file with the federal ...
0
votes
0answers
17 views

QGIS Import Interlis Points problem

When i'm importing a Interlis 1 file (*.itf and *.ili) to QGIS 2.8.1 (or 2.6.1) the polygones are visualized correctly but all the tables containing POINTS (LFP1, Grenzpunkt,...) couldn't be ...
1
vote
0answers
54 views

How to avoid “Unable to compute a transformation between pixel/line”?

I am trying to re-project from Equi-rectangular to the NASA global EASE grid (Equal Area Scalable Earth) grid 1383 586 with a ~25 km cylindrical projection (ESPG=3410). The file is provided as HDF5. ...
1
vote
1answer
57 views

creating a random gdal raster with random predefined values

So far I have developed the below code but for some reason it only works for say one class of landuse instead of two. Would you please tell me where I have gone wrong? Thanks so much import os, ...
0
votes
0answers
44 views

Get min/max value of each band from landsat image?

I am trying to get min/max value of each band from Landsat image with the following code. from osgeo import gdal raster = "raster.tif" # load raster gdalData = gdal.Open(raster) # get number of ...
1
vote
1answer
9 views

Is there a URL I can post to my geoserver that confirms that I properly installed the GDAL plugin?

I'm running geoserver in Tomcat and went through the process of installing the plugin for GDAL formats. I specifically need NITF. Is there a URL I can post to my geoserver that confirms that I ...
1
vote
1answer
31 views

Set up GDAL for C++ in RHEL

I've got GDAL installed from the latest 1.11.2 source, but when I try to make by C++ executable I get undefined references to "GDALAllRegister" and basically all the GDAL functions I call. The same ...
1
vote
0answers
79 views

GeoDjango: AttributeError: function 'GDALAllRegister' not found [closed]

Im trying to get started with GeoDjango. I am using this https://docs.djangoproject.com/en/1.8/ref/contrib/gis/tutorial/ tutorial. When I run "python manage.py migrate" This error occur: ...
2
votes
0answers
35 views

How to re-grid a raster using area-overlap weighted averaging?

I have two rasters r and r2 with different resolutions. I want to re-sample (re-grid) r2 to be the same as r using area-overlap weighted averaging:If an r grid cell is covered by more than 1 ...
1
vote
1answer
19 views

hdf-eos5 file format import in grass

I want to import AURA-OMI ozone level3 data which is available from http://giovanni.gsfc.nasa.gov/giovanni/ .The data is in hdf5 format. The extension is .he5. Do anyone know how to import in grass. ...
1
vote
2answers
45 views

Best way to copy GDAL metadata from one JP2 image to another

I have a separate question going regarding the poor performance of GDAL CreateCopy() on a large (4096x4096) jp2 file, so here's a look at a different angle: I have a C++ openCV program that takes a ...
1
vote
1answer
45 views

Python/GDAL hyperspectral Image wavelengths

I can open and read a hyperspectral image using GDAL according to the instructions brought by Max König here: So after reading the data like this : data = gdal.Open( filename ) then I can see ...
0
votes
1answer
34 views

creating a random raster image using gdal

I want to create a random image containing say three classes with predefind percentages of each of the classes using gdal in python.Any sample code would be very appreciated.
0
votes
1answer
27 views

Can GDAL with “Kml Super Overlay” output a georeferenced geoTiff from a kmz?

I've got a kmz containing an unrefrenced jpg and a boundary box in kml. ogrinfo is happy to report (filenames redacted): INFO: Open of `Sim[...].kmz' using driver `LIBKML' successful. 1: Sim[...] ...
2
votes
1answer
64 views

GDAL createCopy is really slow

I have a C++ program running some OpenCV processing on 4096x4096 JPEG2000 images that have geographical metadata. I don't want to modify the original, the results of my image manipulations are stored ...
0
votes
1answer
28 views

ogr2ogr KML to SHP generates invalid file names from layer names

I have a collection of very large KML files that I'm trying to convert to .shp. I'm iterating over 200+ KML files with an average size of around 20 MB. Each KML contains multiple layers, some of which ...