Opened 12 years ago

Closed 12 years ago

Last modified 12 years ago

#2957 closed defect (fixed)

GeoTIFF Driver Coordinate System Lookup Slow

Reported by: warmerdam Owned by: warmerdam
Priority: normal Milestone: 1.7.0
Component: GDAL_Raster Version: unspecified
Severity: normal Keywords: GTiff
Cc: gaopeng

Description

Performance of coordinate system lookups via EPSG csv files is poor with the Geotiff driver. The problem is particularly severe when many geotiff files are being processed.

Change History (6)

comment:1 Changed 12 years ago by warmerdam

Status: newassigned

The preliminary proposal to deal with this was:

http://trac.osgeo.org/gdal/wiki/rfc25_fast_open

However, feedback has been negative, with suggestions to either accelerate EPSG lookups, or to just defer coordinate system lookups till after the coordinate system is requested.

The first change to reduce the cost of EPSG lookups was to avoid calling CSVDeaccess() at the end of GTIFGetDefn() (captured as part of r16819 - updating from libgeotiff trunk). For cases were the same coordinate system was being looked up many times for distinct file opens this helped the performance dramatically.

The second change (r16821), in cpl_csv.cpp, avoided probing for files in CSVFilename() when the file was already open/accessed via CSVAccess(). This reduced file probing substantially in common cases, though it was not clear how much of a performance difference it makes.

The core of the CSVDeaccess() fix has been backported into 1.6 branch (r16822).

The core changes were also upstreamed into libgeotiff (http://trac.osgeo.org/geotiff/changeset/1570).

comment:2 Changed 12 years ago by warmerdam

Cc: gaopeng added

The GeoTIFF driver in trunk (r16823) has been altered to defer fetching the coordinate system till it has been requested. This can reduce the cost of opening a small geotiff file by 50% even when the .csv files are already accessed and ingested.

This change is deemed as somewhat risky, and has not been ported into 1.6 branch.

comment:3 Changed 12 years ago by Even Rouault

Frank, buildbot seems to indicate that r16823 cause perl-test to fail.

comment:4 Changed 12 years ago by Even Rouault

Regression in perl-test fixed in r16828.

comment:5 Changed 12 years ago by warmerdam

Resolution: fixed
Status: assignedclosed

Ported into 1.6-esri branch (r17276).

comment:6 Changed 12 years ago by warmerdam

Milestone: 1.7.0
Note: See TracTickets for help on using tickets.