matplotlib/matplotlib — pull request #1780 by keflavich (2013-02-23 21:45:57+00:00)
Title: New colormap normalizations: sqrt, arcsinh

(this may be best to regard as a feature request with sample code included; I doubt my code conforms to mpl standards)

Related to #1355, #1204, and #632, I think there should be more default normalizations available in matplotlib. This pull request includes two that I've made use of: a sqrt/n'th root normalization and an arcsinh normalization. The former is good for emphasizing values near 1 (e.g., ratios of like values) and the latter is useful for high dynamic range images where the low scales are to be emphasized (e.g., images of stars with nebulosity around them); it largely serves the same purposes as SymLogNorm but with a different shape.

In part, I often want to reproduce figures made by ds9, which includes a wider range of default normalizations.

If there's an easier way to accomplish what I'm doing - e.g. just wrapping a function in some `Normalize` subclass - please let me know; I'm not up to date on new features of matplotlib unless they're thoroughly exampled in the gallery.