[gdal-dev] python: set CacheMax to percent, MB, GB?
even.rouault at spatialys.com
Thu Jun 17 10:49:11 PDT 2021
Le 17/06/2021 à 19:44, Matt.Wilkie at yukon.ca a écrit :
> you could also call gdal.SetConfigOption('GDAL_CACHEMAX', string), but
> you need to do that *before* reading any raster in the process (or any
> call to gdal.SetCacheMax/GetCacheMax), otherwise it will be ignored.
> Thanks! …/Later/: How to use it? It doesn’t seem to work for me:
That's exacly what I wrote :-) you can't use
gdal.SetConfigOption('GDAL_CACHEMAX', string) after calling
gdal.SetCacheMax/GetCacheMax. You need to use gdal.SetCacheMax() after.
That's not to annoy users, but we just don't want to pay the cost of
reading an environment variable each time GDALGetCacheMax() is used
internally, potentially in time critical code paths, so it is read just
My software is free, but my time generally not.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the gdal-dev