[gdal-dev] GDAL_GRID Linear: Segmentation Fault

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

[gdal-dev] GDAL_GRID Linear: Segmentation Fault

Ian Reese
Hi Gdal,

I am trying to do a linear interpolation using gdal_grid and I am getting a segmentation fault with output grid cell sizes smaller than 8m. 

gdal_grid -zfield "depth" -a linear:nodata=-32768 -outsize 526 754 -of GTiff -l inshape inshape.shp outtif.tif --config GDAL_NUM_THREADS ALL_CPUS
Grid data type is "Float64"
Grid size = (526 754).
Corner coordinates = (1671133.229795 5329097.839821)-(1675355.467899 5323053.902837).
Grid cell size = (8.011837 8.005215).
Source point count = 8363817.
Algorithm name: "linear".
Options are "radius=-1.000000:nodata=-32768.000000"

0...10...20...30...40...50...60...70...80..Segmentation fault (core dumped)

If I change the number of input points (use a much smaller area) things seem to work out OK.

Grid cell size = (6.282705 6.842535).
Source point count = 749329

So, I suspect there is a limitation to the number of points I can use for gdal_grid linear interpolation.  Is there a way I can increase the number of input points?  Or should I break up the region, interpolate smaller areas, and merge them back together in the end.  I have a large area with a large number of dense points (8 million points at 1m resolution).  I am trying to avoid breaking it into as few smaller regions as possible to avoid artifacts at the edges when stitching it back together.

I'd really like to use the linear interpolation if possible since it has nice smooth results and is much faster than IDW with smoothing.

Cheers,

Ian



This message contains information, which may be in confidence and may be subject to legal privilege. If you are not the intended recipient, you must not peruse, use, disseminate, distribute or copy this message. If you have received this message in error, please notify us immediately (Phone 0800 665 463 or [hidden email]) and destroy the original message. LINZ accepts no responsibility for changes to this email, or for any attachments, after its transmission from LINZ. Thank You.

_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: GDAL_GRID Linear: Segmentation Fault

Even Rouault-2
Ian,

which GDAL version is it ? There has been a bug fix in that area in 2.2.3  :
https://trac.osgeo.org/gdal/ticket/7101

Even

--
Spatialys - Geospatial professional services
http://www.spatialys.com
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: GDAL_GRID Linear: Segmentation Fault

Ian Reese
Hi Evan,

Thanks for the heads up. I am running GDAL 2.2.2.  I'll upgrade and let you know how it works out.

Cheers,

Ian
________________________________________
From: Even Rouault [[hidden email]]
Sent: Friday, 15 June 2018 9:55 p.m.
To: [hidden email]
Cc: Ian Reese; Jeremy Palmer
Subject: Re: [gdal-dev] GDAL_GRID Linear: Segmentation Fault

Ian,

which GDAL version is it ? There has been a bug fix in that area in 2.2.3  :
https://trac.osgeo.org/gdal/ticket/7101

Even

--
Spatialys - Geospatial professional services
http://www.spatialys.com

________________________________

This message contains information, which may be in confidence and may be subject to legal privilege. If you are not the intended recipient, you must not peruse, use, disseminate, distribute or copy this message. If you have received this message in error, please notify us immediately (Phone 0800 665 463 or [hidden email]) and destroy the original message. LINZ accepts no responsibility for changes to this email, or for any attachments, after its transmission from LINZ. Thank You.
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev
Reply | Threaded
Open this post in threaded view
|

Re: GDAL_GRID Linear: Segmentation Fault

paolino86
Hi Ian,

did you finally solved your problem upgrading to the newer version ? I am
interested because I have a similar bug.

Thanks,
Paolo



--
Sent from: http://osgeo-org.1560.x6.nabble.com/GDAL-Dev-f3742093.html
_______________________________________________
gdal-dev mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/gdal-dev