Intensity transformations
Mithun kumar kar
Department of Electrical Engineering
BALASORE COLLEGE OF ENGINEERING AND TECHNOLOGY, BALASORE
August 23, 2020
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 1 / 21
Intensity Transformations
All the intensity transformations are done in spatial domain.
The intensity transformations or spatial domain processes can be
denoted by the expression
g(x, y) = T[f (x, y)]
where f (x, y) is the input image and g(x, y) is the output image
T is an operator on f defined over a neighbor of point (x, y).
Intensity transformations are made for image enhancement and for
different applications. Let the value of pixels before transformation is
r and after transformation is s and the transformation is given by
s = T(r)
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 2 / 21
Image Negatives
The negative of an image with intensity levels in the range [0, L − 1]
is obtained by using the negative transformation, given by the
expression s = (L − 1) − r.
Figure : image negetive
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 3 / 21
Image Negatives
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 4 / 21
Splitting colour image in to R,G,B channels
Figure : colour image, red channel,green channel,blue channel
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 5 / 21
Image Negatives applications
Particularly suited for enhancing white or gray details embedded in
dark regions of an image when black images are dominant in size.
Used in digital mammogram to analyze cancer tissues.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 6 / 21
Log Transformations
The general form of log transformation is given by
s = c log(1 + r)
This transformation maps a narrow range of low intensity values in
the input in to a wider range of output levels and vice-verse.
This type of transformation is used to expand the value of dark pixels
in an image, while compressing the higher level values.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 7 / 21
Log Transformations
The log function has the important characteristics that it compress
the dynamic range of the image with large variation in pixel values.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 8 / 21
power law (gamma)transformation
The general form of power law (gamma)transformation is given by
s = crγ
Like log transformation, power-law transformation with fractional
value of γ maps a narrow range of dark input values into a wider
range of output values, with opposite being true for higher values of
input levels.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 9 / 21
power law (gamma)transformation
Simply varying γ a family of possible transformation curves can be
obtained.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 10 / 21
Contrast stretching
Contrast stretching is a process that expands the range of intensity
levels in an image so that it spans the full intensity range of the
recording medium or display device.
The result of contrast stretching is obtained by setting
(r1, s1) = (rmin, 0)
and
(r2, s2) = (rmax, L − 1)
where rmin and rmaxdenote the minimum and maximum intensity
levels in the image respectively.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 11 / 21
Contrast stretching
Figure : Original image, Contrast image
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 12 / 21
Intensity level slicing
Intensity level slicing means highlighting a specific range of intensities
in an image.
one approach of implementing intensity slicing is to display in one
value to all the values in the range of interest and all other intensities
to another.
The second approach based on the transformation which brightens or
darkens the desired range of intensities while leaves all other intensity
levels unchanged.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 13 / 21
Intensity level slicing
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 14 / 21
Bit plane slicing
Bit plane slicing is a method of representing an image with one or
more bits of the byte used for each pixel.
As in digital image the gray level of each pixel is stored as one or
more bytes, we could highlight the contribution made to the total
image appearance by specific bits.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 15 / 21
Bit plane slicing
It highlights the contribution made by each bits or specific bits
An 8 bit image may be considered as being composed of eight 1 bit
planes, with plane-0 containing the lowest order bit of all pixels in the
image and the plane-7 all the higher order bits
Decomposing an image in to its bit planes is useful for analyzing the
relative importance of each bit in the image.
This type of decomposition is useful for image compression in which
fewer planes are used in reconstruction of an image.
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 16 / 21
Image rotation
Image rotation is a common image processing application where the
coordinates of the image is rotated with some angle θ.
The coordinates of a point (x1, y1) when rotated by an angle θ
around (x0, y0) become (x2, y2), as shown by the following equation
x2 = cos θ(x1 − x0) + sin θ(y1 − y0)
y2 = − sin θ(x1 − x0) + cos θ(y1 − y0)
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 17 / 21
Histogram processing
The histogram of a digital image with intensity levels in the range
[0,L-1] is a disctete function h(rk) = nk, where rk is the kth intensity
value and nk is the number of pixels in the image with intensity rk
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 18 / 21
Histogram processing
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 19 / 21
Histogram processing
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 20 / 21
Histogram Equalization
Histogram equalization is a process that attempts to spreadout the
gray levels in an image so that they are evenly distributed across their
range.
The transformation equation for histogram equalization is given by
Sk = T(rk) = (L − 1)
k
j=0
Pr (rj ) =
(L − 1)
MN
k
j=0
nj
Mithun kumar kar (BCET) Intensity transformations August 23, 2020 21 / 21
Histogram Equalization
Histogram equalization is a process that attempts to spreadout the
gray levels in an image so that they are evenly distributed across their
range.
The transformation equation for histogram equalization is given by
Sk = T(rk) = (L − 1)
k
j=0
Pr (rj ) =
(L − 1)
MN
k
j=0
nj
Figure : Original image, Histogram equalized imageMithun kumar kar (BCET) Intensity transformations August 23, 2020 22 / 21

Image transforms

  • 1.
    Intensity transformations Mithun kumarkar Department of Electrical Engineering BALASORE COLLEGE OF ENGINEERING AND TECHNOLOGY, BALASORE August 23, 2020 Mithun kumar kar (BCET) Intensity transformations August 23, 2020 1 / 21
  • 2.
    Intensity Transformations All theintensity transformations are done in spatial domain. The intensity transformations or spatial domain processes can be denoted by the expression g(x, y) = T[f (x, y)] where f (x, y) is the input image and g(x, y) is the output image T is an operator on f defined over a neighbor of point (x, y). Intensity transformations are made for image enhancement and for different applications. Let the value of pixels before transformation is r and after transformation is s and the transformation is given by s = T(r) Mithun kumar kar (BCET) Intensity transformations August 23, 2020 2 / 21
  • 3.
    Image Negatives The negativeof an image with intensity levels in the range [0, L − 1] is obtained by using the negative transformation, given by the expression s = (L − 1) − r. Figure : image negetive Mithun kumar kar (BCET) Intensity transformations August 23, 2020 3 / 21
  • 4.
    Image Negatives Mithun kumarkar (BCET) Intensity transformations August 23, 2020 4 / 21
  • 5.
    Splitting colour imagein to R,G,B channels Figure : colour image, red channel,green channel,blue channel Mithun kumar kar (BCET) Intensity transformations August 23, 2020 5 / 21
  • 6.
    Image Negatives applications Particularlysuited for enhancing white or gray details embedded in dark regions of an image when black images are dominant in size. Used in digital mammogram to analyze cancer tissues. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 6 / 21
  • 7.
    Log Transformations The generalform of log transformation is given by s = c log(1 + r) This transformation maps a narrow range of low intensity values in the input in to a wider range of output levels and vice-verse. This type of transformation is used to expand the value of dark pixels in an image, while compressing the higher level values. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 7 / 21
  • 8.
    Log Transformations The logfunction has the important characteristics that it compress the dynamic range of the image with large variation in pixel values. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 8 / 21
  • 9.
    power law (gamma)transformation Thegeneral form of power law (gamma)transformation is given by s = crγ Like log transformation, power-law transformation with fractional value of γ maps a narrow range of dark input values into a wider range of output values, with opposite being true for higher values of input levels. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 9 / 21
  • 10.
    power law (gamma)transformation Simplyvarying γ a family of possible transformation curves can be obtained. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 10 / 21
  • 11.
    Contrast stretching Contrast stretchingis a process that expands the range of intensity levels in an image so that it spans the full intensity range of the recording medium or display device. The result of contrast stretching is obtained by setting (r1, s1) = (rmin, 0) and (r2, s2) = (rmax, L − 1) where rmin and rmaxdenote the minimum and maximum intensity levels in the image respectively. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 11 / 21
  • 12.
    Contrast stretching Figure :Original image, Contrast image Mithun kumar kar (BCET) Intensity transformations August 23, 2020 12 / 21
  • 13.
    Intensity level slicing Intensitylevel slicing means highlighting a specific range of intensities in an image. one approach of implementing intensity slicing is to display in one value to all the values in the range of interest and all other intensities to another. The second approach based on the transformation which brightens or darkens the desired range of intensities while leaves all other intensity levels unchanged. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 13 / 21
  • 14.
    Intensity level slicing Mithunkumar kar (BCET) Intensity transformations August 23, 2020 14 / 21
  • 15.
    Bit plane slicing Bitplane slicing is a method of representing an image with one or more bits of the byte used for each pixel. As in digital image the gray level of each pixel is stored as one or more bytes, we could highlight the contribution made to the total image appearance by specific bits. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 15 / 21
  • 16.
    Bit plane slicing Ithighlights the contribution made by each bits or specific bits An 8 bit image may be considered as being composed of eight 1 bit planes, with plane-0 containing the lowest order bit of all pixels in the image and the plane-7 all the higher order bits Decomposing an image in to its bit planes is useful for analyzing the relative importance of each bit in the image. This type of decomposition is useful for image compression in which fewer planes are used in reconstruction of an image. Mithun kumar kar (BCET) Intensity transformations August 23, 2020 16 / 21
  • 17.
    Image rotation Image rotationis a common image processing application where the coordinates of the image is rotated with some angle θ. The coordinates of a point (x1, y1) when rotated by an angle θ around (x0, y0) become (x2, y2), as shown by the following equation x2 = cos θ(x1 − x0) + sin θ(y1 − y0) y2 = − sin θ(x1 − x0) + cos θ(y1 − y0) Mithun kumar kar (BCET) Intensity transformations August 23, 2020 17 / 21
  • 18.
    Histogram processing The histogramof a digital image with intensity levels in the range [0,L-1] is a disctete function h(rk) = nk, where rk is the kth intensity value and nk is the number of pixels in the image with intensity rk Mithun kumar kar (BCET) Intensity transformations August 23, 2020 18 / 21
  • 19.
    Histogram processing Mithun kumarkar (BCET) Intensity transformations August 23, 2020 19 / 21
  • 20.
    Histogram processing Mithun kumarkar (BCET) Intensity transformations August 23, 2020 20 / 21
  • 21.
    Histogram Equalization Histogram equalizationis a process that attempts to spreadout the gray levels in an image so that they are evenly distributed across their range. The transformation equation for histogram equalization is given by Sk = T(rk) = (L − 1) k j=0 Pr (rj ) = (L − 1) MN k j=0 nj Mithun kumar kar (BCET) Intensity transformations August 23, 2020 21 / 21
  • 22.
    Histogram Equalization Histogram equalizationis a process that attempts to spreadout the gray levels in an image so that they are evenly distributed across their range. The transformation equation for histogram equalization is given by Sk = T(rk) = (L − 1) k j=0 Pr (rj ) = (L − 1) MN k j=0 nj Figure : Original image, Histogram equalized imageMithun kumar kar (BCET) Intensity transformations August 23, 2020 22 / 21