[gdal-dev] problem: gdal_grid, output ers raster file

Ron Palmer ron.palmer at pgcgroup.com.au
Tue Feb 16 22:55:17 PST 2021


I am having issues with outputting ers raster file from gdal_grid. I 
import a csv as shape, then grid it and output as ers. The Y coords are 
all negative as it is in fact a section I simply grid as a 2D raster. 
Although the shape file plots as I expect it, the ers is flipped 
upside-down, and hung at the lowest Y value. Please note, if I use GS7BG 
it works fine.

How do I get an ERS output that matches the shape file/data points?

I have created a simple example... however, I am new to GDAL, and this 
is my first post, so please let me know if there is anything else I 
should provide.

Thanks

Ron


These are the commands:

   711  ogr2ogr -f "ESRI Shapefile" xc_zc.shp new.csv -oo 
X_POSSIBLE_NAMES=xc -oo Y_POSSIBLE_NAMES=zc
   712  gdal_grid -zfield Value -a linear:radius=5 xc_zc.shp -of ERS 
xc_zc.ers

here is the content of the data

xc,zc,Value
1.25,-0.625,5
3.75,-0.625,5
6.25,-0.625,5
8.75,-0.625,5
11.25,-0.625,5
1.25,-1.938,4
3.75,-1.938,4
6.25,-1.938,4
8.75,-1.938,4
11.25,-1.938,4
1.25,-3.381,3
3.75,-3.381,3
6.25,-3.381,3
8.75,-3.381,3
11.25,-3.381,3
1.25,-4.969,2
3.75,-4.969,2
6.25,-4.969,2
8.75,-4.969,2
11.25,-4.969,2
1.25,-6.716,1
3.75,-6.716,1
6.25,-6.716,1
8.75,-6.716,1
11.25,-6.716,1

I have attached a jpg of my output (not sure whether the mailing list 
allows attachments...)




-- 
This email has been checked for viruses by AVG.
https://www.avg.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20210217/beafdbd1/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: examplePlot.jpg
Type: image/jpeg
Size: 71798 bytes
Desc: not available
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20210217/beafdbd1/attachment-0001.jpg>


More information about the gdal-dev mailing list