skimage 0.17.2

NotesParametersReturnsBackRef
adjust_gamma(image, gamma=1, gain=1)

Also known as Power Law Transform. This function transforms the input image pixelwise according to the equation O = I**gamma after scaling each pixel to the range 0 to 1.

Notes

For gamma greater than 1, the histogram will shift towards left and the output image will be darker than the input image.

For gamma less than 1, the histogram will shift towards right and the output image will be brighter than the input image.

Parameters

image : ndarray

Input image.

gamma : float, optional

Non negative real number. Default value is 1.

gain : float, optional

The constant multiplier. Default value is 1.

Returns

out : ndarray

Gamma corrected output image.

Performs Gamma Correction on the input image.

See Also

adjust_log

Examples

This example is valid syntax, but we were not able to check execution
>>> from skimage import data, exposure, img_as_float
... image = img_as_float(data.moon())
... gamma_corrected = exposure.adjust_gamma(image, 2)
... # Output is darker for gamma > 1
... image.mean() > gamma_corrected.mean() True
See :

Back References

The following pages refer to to this document either explicitly or contain code examples using this.

skimage.exposure.exposure.adjust_log skimage.exposure.exposure.adjust_gamma skimage.exposure.exposure.adjust_sigmoid

Local connectivity graph

Hover to see nodes names; edges to Self not shown, Caped at 50 nodes.

Using a canvas is more power efficient and can get hundred of nodes ; but does not allow hyperlinks; , arrows or text (beyond on hover)

SVG is more flexible but power hungry; and does not scale well to 50 + nodes.

All aboves nodes referred to, (or are referred from) current nodes; Edges from Self to other have been omitted (or all nodes would be connected to the central node "self" which is not useful). Nodes are colored by the library they belong to, and scaled with the number of references pointing them


File: /skimage/exposure/exposure.py#439
type: <class 'function'>
Commit: