Have a look at

http://www.gina.alaska.edu/projects/gina-tools/

Best Regards,
Brent Fraser


On 9/7/2011 2:22 PM, David Shean wrote:
Forgive me if this is not the proper forum (no gdal-users list?) or if this 
question has been answered in the past - I've been using GDAL for a while now, 
but just joined the mailing list and I'm relatively new to python.

I have large (>2GB uncompressed) UInt16 geotiffs that I need to convert to 
8-bit geotiffs.  I'd like to use a percent range (e.g. 0.5-99.5%) to determine the 
new min/max for the linear stretch in gdal_translate.  I haven't found any simple 
way of doing this with the existing GDAL utilities, although it looks like 
gdalenhance was at least initially designed to do something along these lines.

If there is no simple way to do this with existing tools, is there any sample 
code floating around that might help?  If not, I know it will be possible with 
the histogram/stats functions in gdal, numpy, or PIL - I just want to make sure 
that I'm not reinventing a slower, clunkier wheel.

Thanks.
-David

---
David Shean
Polar Science Center
Applied Physics Lab
University of Washington


_______________________________________________
gdal-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/gdal-dev


_______________________________________________
gdal-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to