[postgis-devel] [PostGIS] #1872: [raster] ST_ApproxSummaryStat fails under some condition

PostGIS trac at osgeo.org
Sat Jun 16 20:17:04 PDT 2012


#1872: [raster] ST_ApproxSummaryStat fails under some condition
---------------------+------------------------------------------------------
 Reporter:  pracine  |       Owner:  pracine      
     Type:  defect   |      Status:  new          
 Priority:  medium   |   Milestone:  PostGIS 2.0.2
Component:  raster   |     Version:  2.0.x        
 Keywords:           |  
---------------------+------------------------------------------------------
 This works:

 {{{
 SELECT ST_ApproxSummaryStats(ST_AddBand(ST_MakeEmptyRaster(10, 10, 0, 0,
 1, 1, 0, 0, 4326), '16BSI'::text, 0, 0));
 }}}

 but if I clip the raster:

 {{{
 SELECT ST_ApproxSummaryStats(ST_Clip(ST_AddBand(ST_MakeEmptyRaster(10, 10,
 0, 0, 1, 1, 0, 0, 4326), '16BSI'::text, 0, 0), ST_MakeEnvelope(0, 0, 10,
 5, 4326)), 1, true, 0.1);
 }}}

 it fails with this message:


 ERROR:  floating-point exception
 DETAIL:  An invalid floating-point operation was signaled. This probably
 means an out-of-range result or an invalid operation, such as division by
 zero.
 CONTEXT:  SQL function "st_approxsummarystats" statement 1

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/1872>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-devel mailing list