[Proj] Performance impact of switch of utm to etmerc

Even Rouault even.rouault at spatialys.com
Mon May 23 17:49:43 EST 2016


Hi,

I've given a try with proj master with GDAL, and wanted to assess the 
performance impact of utm now using etmerc instead of tmerc.

Given a in.tif raster of 5000x5000 pixels in EPSG:3857, I did :

$ time gdalwarp in.tif out.tif  -t_srs EPSG:32611 -overwrite -et 0 -q

This runs in 18.1 s. With proj 4.9.2, the same runs in 13.6 s

EPSG:32611 is resolved by GDAL as "+proj=utm +zone=11 +ellps=WGS84 +units=m 
+no_defs"

I added explicitly -et 0 so that the exact transformer of GDAL is used, 
meaning that 5042x5019 inverse projections will be done (number of pixels of 
output dataset). By default GDAL would use an approximate linear interpolation 
transformer leading to very few transformations, and the time spent in proj is 
then almost neglectable. But with -et 0, reprojection work becomes really 
significant. It should be noted that -et 0 is the default if doing RPC 
transformation with a DEM since GDAL 2.1.0 (since DEM have no nice regularity, 
an approximate interpolator can do really bad guesses in mountain areas), and 
this will probably the use case mostly affected by this.

To come back to previous performance, I've added in GDAL the possibility to 
define the OSR_USE_ETMERC=NO configuration option/environment variable so that 
"+proj=utm" is expanded to the appropriate "+proj=tmerc ...."

Best regards,

Even

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


More information about the Proj mailing list