In the past two decades, the technique of image processing has made its way into every aspect of today’s tech-savvy society. Its applications encompass a wide variety of specialized disciplines including medical imaging, machine vision, remote sensing and astronomy. Personal images captured by various digital cameras can easily be manipulated by a variety of dedicated image processing algorithms. Image restoration can be described as an important part of image processing technique. The basic objective is to enhance the quality of an image by removing defects and make it look pleasing. The method used to carry out the project was MATLAB software. Mathematical algorithms were programmed and tested for the result to find the necessary output. In this project mathematical analysis was the basic core. Generally the spatial and frequency domain methods were both important and applicable in different technologies. This project has tried to show the comparison between spatial and frequency domain approaches and their advantages and disadvantages. This project also suggested that more research have to be done in many other image processing applications to show the importance of those methods.
Image segmentation is based on three principal concepts
Detection of discontinuities.
Thresholding
Region Processing
Morphological Watershed Image Segmentation embodies many of the concepts of above three approaches
Image segmentation is based on three principal concepts
Detection of discontinuities.
Thresholding
Region Processing
Morphological Watershed Image Segmentation embodies many of the concepts of above three approaches
its very useful for students.
Sharpening process in spatial domain
Direct Manipulation of image Pixels.
The objective of Sharpening is to highlight transitions in intensity
The image blurring is accomplished by pixel averaging in a neighborhood.
Since averaging is analogous to integration.
Prepared by
M. Sahaya Pretha
Department of Computer Science and Engineering,
MS University, Tirunelveli Dist, Tamilnadu.
Basic Introduction about Image Restoration (Order Statistics Filters)
Median Filter
Max and Min Filter
MidPoint Filter
Alpha-trimmed Mean filter.
and Brief Introduction to Periodic Noise
Any Question contact kalyan.acharjya@gmail.com
This presentation describes briefly about the image enhancement in spatial domain, basic gray level transformation, histogram processing, enhancement using arithmetic/ logical operation, basics of spatial filtering and local enhancements.
Advance in Image and Audio Restoration and their Assessments: A ReviewIJCSES Journal
Image restoration is the process of restoring the original image from a degraded one. Images can be affected by various types of noise, such as Gaussian noise, impulse noise, and affected by blurring, which is happened during image recordings like motion blur, Out-of-Focus Blur, and others. Image restoration techniques are used to reverse the effect of noise and blurring. Restoration of distorted images can be done using some information about noise and the blurring nature or without any knowledge about the image degradation process. Researchers have proposed many algorithms in this regard; in this paper, different noise and degradation models and restoration methods will be discussed and review some researches in this field.
its very useful for students.
Sharpening process in spatial domain
Direct Manipulation of image Pixels.
The objective of Sharpening is to highlight transitions in intensity
The image blurring is accomplished by pixel averaging in a neighborhood.
Since averaging is analogous to integration.
Prepared by
M. Sahaya Pretha
Department of Computer Science and Engineering,
MS University, Tirunelveli Dist, Tamilnadu.
Basic Introduction about Image Restoration (Order Statistics Filters)
Median Filter
Max and Min Filter
MidPoint Filter
Alpha-trimmed Mean filter.
and Brief Introduction to Periodic Noise
Any Question contact kalyan.acharjya@gmail.com
This presentation describes briefly about the image enhancement in spatial domain, basic gray level transformation, histogram processing, enhancement using arithmetic/ logical operation, basics of spatial filtering and local enhancements.
Advance in Image and Audio Restoration and their Assessments: A ReviewIJCSES Journal
Image restoration is the process of restoring the original image from a degraded one. Images can be affected by various types of noise, such as Gaussian noise, impulse noise, and affected by blurring, which is happened during image recordings like motion blur, Out-of-Focus Blur, and others. Image restoration techniques are used to reverse the effect of noise and blurring. Restoration of distorted images can be done using some information about noise and the blurring nature or without any knowledge about the image degradation process. Researchers have proposed many algorithms in this regard; in this paper, different noise and degradation models and restoration methods will be discussed and review some researches in this field.
IJRET : International Journal of Research in Engineering and Technology is an international peer reviewed, online journal published by eSAT Publishing House for the enhancement of research in various disciplines of Engineering and Technology. The aim and scope of the journal is to provide an academic medium and an important reference for the advancement and dissemination of research results that support high-level learning, teaching and research in the fields of Engineering and Technology. We bring together Scientists, Academician, Field Engineers, Scholars and Students of related fields of Engineering and Technology
An Efficient Image Denoising Approach for the Recovery of Impulse NoisejournalBEEI
Image noise is one of the key issues in image processing applications today. The noise will affect the quality of the image and thus degrades the actual information of the image. Visual quality is the prerequisite for many imagery applications such as remote sensing. In recent years, the significance of noise assessment and the recovery of noisy images are increasing. The impulse noise is characterized by replacing a portion of an image’s pixel values with random values Such noise can be introduced due to transmission errors. Accordingly, this paper focuses on the effect of visual quality of the image due to impulse noise during the transmission of images. In this paper, a hybrid statistical noise suppression technique has been developed for improving the quality of the impulse noisy color images. We further proved the performance of the proposed image enhancement scheme using the advanced performance metrics.
Visual Quality for both Images and Display of Systems by Visual Enhancement u...IJMER
International Journal of Modern Engineering Research (IJMER) is Peer reviewed, online Journal. It serves as an international archival forum of scholarly research related to engineering and science education.
International Journal of Modern Engineering Research (IJMER) covers all the fields of engineering and science: Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Computer Engineering, Agricultural Engineering, Aerospace Engineering, Thermodynamics, Structural Engineering, Control Engineering, Robotics, Mechatronics, Fluid Mechanics, Nanotechnology, Simulators, Web-based Learning, Remote Laboratories, Engineering Design Methods, Education Research, Students' Satisfaction and Motivation, Global Projects, and Assessment…. And many more.
Survey Paper on Image Denoising Using Spatial Statistic son PixelIJERA Editor
The classical non-local means image denoising approach, the value of a pixel is determined based on the weighted average of other pixels, where the weights are determined based on a fixed isotropic ally weighted similarity function between the local neighbourhoods. It is demonstrate that noticeably improved perceptual quality can be achieved through the use of adaptive anisotropic ally weighted similarity functions between local neighbourhoods. This is accomplished by adapting the similarity weighing function in an anisotropic manner based on the perceptual characteristics of the underlying image content derived efficiently based on the Mexican Hat wavelet. Experimental results show that the it can be used to provide improved perceptual quality in the denoised image both quantitatively and qualitatively when compared to existing methods.
Filter for Removal of Impulse Noise By Using Fuzzy LogicCSCJournals
Digital image processing is a subset of the electronic domain wherein the image is converted to an array of small integers, called pixels, representing a physical quantity such as scene radiance, stored in a digital memory, and processed by computer or other digital hardware. Fuzzy logic represents a good mathematical framework to deal with uncertainty of information. Fuzzy image processing [4] is the collection of all approaches that understand, represent and process the images, their segments and features as fuzzy sets. The representation and processing depend on the selected fuzzy technique and on the problem to be solved. This paper combines the features of Image Enhancement and fuzzy logic. This research problem deals with Fuzzy inference system (FIS) which help to take the decision about the pixels of the image under consideration. This paper focuses on the removal of the impulse noise with the preservation of edge sharpness and image details along with improving the contrast of the images which is considered as the one of the most difficult tasks in image processing.
This paper presents a frequency domain degraded
image restoration practical method. We call it practical wiener
filter. Using this filter, the value for K parameter of wiener
filter is determined experimentally that is so difficult and
time consuming. Furthermore, there is no any absolute remark
to claim that the obtained images by restoration process are
the best could be possible. In order to find a solution for this
problem, we use genetic algorithm to obtain the best value for
K. Therefore, this paper presents an image restoration method
which employs a Computer Aided Design (CAD) to image
restoration where there is no need to original safe image. It
means that, degraded image is as input and restored one is as
output of CAD. Simulation results confirm that this method
is successful and has executive ability in most applications.
Pattern Approximation Based Generalized Image Noise Reduction Using Adaptive ...IJECEIAES
The problem of noise interference with the image always occurs irrespective of whatever precaution is taken. Challenging issues with noise reduction are diversity of characteristics involved with source of noise and in result; it is difficult to develop a universal solution. This paper has proposed neural network based generalize solution of noise reduction by mapping the problem as pattern approximation. Considering the statistical relationship among local region pixels in the noise free image as normal patterns, feedforward neural network is applied to acquire the knowledge available within such patterns. Adaptiveness is applied in the slope of transfer function to improve the learning process. Acquired normal patterns knowledge is utilized to reduce the level of different type of noise available within an image by recorrection of noisy patterns through pattern approximation. The proposed restoration method does not need any estimation of noise model characteristics available in the image not only that it can reduce the mixer of different types of noise efficiently. The proposed method has high processing speed along with simplicity in design. Restoration of gray scale image as well as color image has done, which has suffered from different types of noise like, Gaussian noise, salt &peper, speckle noise and mixer of it.
Removal of Gaussian noise on the image edges using the Prewitt operator and t...IOSR Journals
Abstract: Image edge detection algorithm is applied on images to remove Gaussian noise that is present in the
image during capturing or transmission using a method which combines Prewitt operator and threshold
function technique to do edge detection on the image. This method is better than a method which combines
Prewitt operator and mean filtering. In this paper, firstly use mean filtering to remove initially Gaussian noise,
then use Prewitt operator to do edge detection on the image, and finally applied a threshold function technique
with Prewitt operator.
Keywords: Gaussian noise, Prewitt operator, edge detection, threshold function
A Novel Adaptive Denoising Method for Removal of Impulse Noise in Images usin...iosrjce
IOSR Journal of Computer Engineering (IOSR-JCE) is a double blind peer reviewed International Journal that provides rapid publication (within a month) of articles in all areas of computer engineering and its applications. The journal welcomes publications of high quality papers on theoretical developments and practical applications in computer technology. Original research papers, state-of-the-art reviews, and high quality technical notes are invited for publications.
A Decision tree and Conditional Median Filter Based Denoising for impulse noi...IJERA Editor
Impulse noise is often introduced into images during acquisition and transmission. Even though so many denoising techniques are existing for the removal of impulse noise in images, most of them are high complexity methods and have only low image quality. Here a low cost, low complexity VLSI architecture for the removal of random valued impulse noise in highly corrupted images is introduced. In this technique a decision- tree- based impulse noise detector is used to detect the noisy pixels and an efficient conditional median filter is used to reconstruct the intensity values of noisy pixels. The proposed technique can improve the signal to noise ratio than any other technique.
CFD Simulation of By-pass Flow in a HRSG module by R&R Consult.pptxR&R Consult
CFD analysis is incredibly effective at solving mysteries and improving the performance of complex systems!
Here's a great example: At a large natural gas-fired power plant, where they use waste heat to generate steam and energy, they were puzzled that their boiler wasn't producing as much steam as expected.
R&R and Tetra Engineering Group Inc. were asked to solve the issue with reduced steam production.
An inspection had shown that a significant amount of hot flue gas was bypassing the boiler tubes, where the heat was supposed to be transferred.
R&R Consult conducted a CFD analysis, which revealed that 6.3% of the flue gas was bypassing the boiler tubes without transferring heat. The analysis also showed that the flue gas was instead being directed along the sides of the boiler and between the modules that were supposed to capture the heat. This was the cause of the reduced performance.
Based on our results, Tetra Engineering installed covering plates to reduce the bypass flow. This improved the boiler's performance and increased electricity production.
It is always satisfying when we can help solve complex challenges like this. Do your systems also need a check-up or optimization? Give us a call!
Work done in cooperation with James Malloy and David Moelling from Tetra Engineering.
More examples of our work https://www.r-r-consult.dk/en/cases-en/
Welcome to WIPAC Monthly the magazine brought to you by the LinkedIn Group Water Industry Process Automation & Control.
In this month's edition, along with this month's industry news to celebrate the 13 years since the group was created we have articles including
A case study of the used of Advanced Process Control at the Wastewater Treatment works at Lleida in Spain
A look back on an article on smart wastewater networks in order to see how the industry has measured up in the interim around the adoption of Digital Transformation in the Water Industry.
Hierarchical Digital Twin of a Naval Power SystemKerry Sado
A hierarchical digital twin of a Naval DC power system has been developed and experimentally verified. Similar to other state-of-the-art digital twins, this technology creates a digital replica of the physical system executed in real-time or faster, which can modify hardware controls. However, its advantage stems from distributing computational efforts by utilizing a hierarchical structure composed of lower-level digital twin blocks and a higher-level system digital twin. Each digital twin block is associated with a physical subsystem of the hardware and communicates with a singular system digital twin, which creates a system-level response. By extracting information from each level of the hierarchy, power system controls of the hardware were reconfigured autonomously. This hierarchical digital twin development offers several advantages over other digital twins, particularly in the field of naval power systems. The hierarchical structure allows for greater computational efficiency and scalability while the ability to autonomously reconfigure hardware controls offers increased flexibility and responsiveness. The hierarchical decomposition and models utilized were well aligned with the physical twin, as indicated by the maximum deviations between the developed digital twin hierarchy and the hardware.
Student information management system project report ii.pdfKamal Acharya
Our project explains about the student management. This project mainly explains the various actions related to student details. This project shows some ease in adding, editing and deleting the student details. It also provides a less time consuming process for viewing, adding, editing and deleting the marks of the students.
Final project report on grocery store management system..pdfKamal Acharya
In today’s fast-changing business environment, it’s extremely important to be able to respond to client needs in the most effective and timely manner. If your customers wish to see your business online and have instant access to your products or services.
Online Grocery Store is an e-commerce website, which retails various grocery products. This project allows viewing various products available enables registered users to purchase desired products instantly using Paytm, UPI payment processor (Instant Pay) and also can place order by using Cash on Delivery (Pay Later) option. This project provides an easy access to Administrators and Managers to view orders placed using Pay Later and Instant Pay options.
In order to develop an e-commerce website, a number of Technologies must be studied and understood. These include multi-tiered architecture, server and client-side scripting techniques, implementation technologies, programming language (such as PHP, HTML, CSS, JavaScript) and MySQL relational databases. This is a project with the objective to develop a basic website where a consumer is provided with a shopping cart website and also to know about the technologies used to develop such a website.
This document will discuss each of the underlying technologies to create and implement an e- commerce website.
1. 1 | P a g e
(天津职业技术师范大学)
DEPARTMENT: ELECTRONICS ENGINEERING
SUBJECT: DIGITAL IMAGE PROCESSING
STUDENT NAME: MWIGHUSA (唐德宁)
SUPERVISOR: DR. DING XUEWEN (丁学文) - PhD
PROJECT TITLE: IMAGE RESTORATION
DATE: 24TH
NOVEMBER
2. 2 | P a g e
Overview:
In the past two decades, the technique of image processing has made its way into every aspect of
today’s tech-savvy society. Its applications encompass a wide variety of specialized disciplines
including medical imaging, machine vision, remote sensing and astronomy. Personal images
captured by various digital cameras can easily be manipulated by a variety of dedicated image
processing algorithms. Image restoration can be described as an important part of image processing
technique. The basic objective is to enhance the quality of an image by removing defects and make
it look pleasing. The method used to carry out the project was MATLAB software. Mathematical
algorithms were programmed and tested for the result to find the necessary output. In this project
mathematical analysis was the basic core. Generally the spatial and frequency domain methods
were both important and applicable in different technologies. This project has tried to show the
comparison between spatial and frequency domain approaches and their advantages and
disadvantages. This project also suggested that more research have to be done in many other image
processing applications to show the importance of those methods.
Acknowledgements:
The author remains thankful to Dr. Ding Xuewen (Dr. & Lecturer, Dept. of Electronics &
Electrical Engineering, Tianjin University of Technology & Education, Tianjin, China P.R) for his
useful discussions and suggestions during the preparations of this project.
3. 3 | P a g e
Contents
Introduction………………………………………………………………………………………..1
Image Noise Model………………………………………………………………………………..2
Noise Types……………………………………………………………………………….3
Filters……………………………………………………………………………………………...6
Filtering Techniques………………………………………………………………………7
Noise Filtering in Spatial and Frequency Domain………………………………………………...8
Filtering to remove noise………………………………………………………………….8
Order statistic filters……………………………………………………………………...11
Adaptive Filters…………………………………………………………………………………..15
Adaptive Filters Example………………………………………………………………..17
Periodic Noise……………………………………………………………………………………17
Band Reject Filters……………………………………………………………………………….17
Band Reject Filters Example…………………………………………………………….18
Advantage and Disadvantage of Spatial and Frequency Domain Methods……………………...19
Conclusion……………………………………………………………………………………….19
Reference………………………………………………………………………………………...20
4. 4 | P a g e
IMAGE RESTORATION
Introduction
Image Restoration is the process of obtaining the original image from the degraded image given
the knowledge of the degrading factors. Digital image restoration is a field of engineering that
studies methods used to recover original scene from the degraded images and observations.
Techniques used for image restoration are oriented towards modeling the degradations, usually
blur and noise and applying various filters to obtain an approximation of the original scene. There
are a variety of reasons that could cause degradation of an image and image restoration is one of
the key fields in today's Digital Image Processing due to its wide area of applications. Commonly
occurring degradations include blurring, motion and noise. Blurring can be caused when object in
the image is outside the camera’s depth of field sometime during the exposure, whereas motion
blur can be caused when an object moves relative to the camera during an exposure.
Fig. Image Restoration example
The purpose of image restoration is to "compensate for" or "undo" defects which degrade an image.
Degradation comes in many forms such as motion blur, noise, and camera misfocus. In cases like
motion blur, it is possible to come up with a very good estimate of the actual blurring function and
"undo" the blur to restore the original image. In cases where the image is corrupted by noise, the
best we may hope to do is to compensate for the degradation it caused. In this project, we will
introduce and implement several of the methods used in the image processing world to restore
images. The field of image restoration (sometimes referred to as image de-blurring or image de-
convolution) is concerned with the reconstruction or estimation of the uncorrupted image from a
blurred and noisy one. Essentially, it tries to perform an operation on the image that is the inverse
of the imperfections in the image formation system. In the use of image restoration methods, the
characteristics of the degrading system and the noise are assumed to be known a priori. In practical
situations, however, one may not be able to obtain this information directly from the image
formation process. The goal of blur identification is to estimate the attributes of the imperfect
imaging system from the observed degraded image itself prior to the restoration process. The
combination of image restoration and blur identification is often referred to as blind image de-
convolution. Image restoration algorithms distinguish themselves from image enhancement
methods in that they are based on models for the degrading process and for the ideal image. For
5. 5 | P a g e
those cases where a fairly accurate blur model is available, powerful restoration algorithms can be
arrived at. Unfortunately, in numerous practical cases of interest, the modeling of the blur is
unfeasible, rendering restoration impossible. The limited validity of blur models is often a factor
of disappointment, but one should realize that if none of the blur models described in this chapter
are applicable, the corrupted image may well be beyond restoration. Therefore, no matter how
powerful blur identification and restoration algorithms are, the objective when capturing an image
undeniably is to avoid the need for restoring the image.
In restoration process, degradation is taken to be a linear spatially invariant operator –
Figure. Processing of Image Restoration
𝑔(𝑥, 𝑦) = ℎ(𝑥, 𝑦) ∗ 𝑓(𝑥, 𝑦) + 𝜂(𝑥, 𝑦)
where, if g(x, y) is noise free, restoration can be done by using the inverse transfer function of h(u,
v) as the restoration filter and η(x, y) is the noise. The restoration techniques use various types of
filters for achieving best performance, like inverse filter, wiener filter, constrained least square
filter, Histogram Adaptive Fuzzy filter, Min-max Detector Based filter and Centre Weighted Mean
filter etc.
Image Noise Model
The sources of noise in digital images arise during image acquisition (digitization) and
transmission.
• Imaging sensors can be affected by ambient conditions
• Interference can be added to an image during transmission
We can consider a noisy image to be modelled as follows:
𝑔(𝑥, 𝑦) = ℎ(𝑥, 𝑦) ∗ 𝑓(𝑥, 𝑦) + 𝜂(𝑥, 𝑦)
where f(x, y) is the original image pixel, η(x, y) is the noise term and g(x, y) is the resulting noisy
pixel. If we can estimate the model of the noise in an image, it will help us to figure out how to
restore the image.
6. 6 | P a g e
Noise Types
For an image to be restored it is important to know the features of the noises that caused its
degradation. They have different features but the most important in this project are the spatial and
frequency properties.
Spatial properties mean dealing with the statistical behaviors of the noise component, while in
frequency properties deal with the frequency contents of the noise in Fourier form. There are
many noise patterns in image processing and some of them include:
a) Gaussian noise – is a noise type initiated by a Gaussian amplitude distribution. The Gaussian
probability distribution has a a probability density function of
𝑃(𝑥) =
1
𝜎√2𝜋
𝑒−(𝑥−𝜇)2 2𝜎2⁄
where 𝑥 is the gray level 𝜇 is the mean, 𝜎 is the standard deviation and 𝜎2
is the variance.
b) Erlang (Gamma) noise – is a noise having a probability distribution function of
𝑃(𝑧) = {
𝑎 𝑏 𝑧 𝑏−1
(𝑏−1)!
𝑒−𝑎𝑧
𝑓𝑜𝑟 𝑧 ≥ 0
0 𝑓𝑜𝑟 𝑧 < 0
where the mean is a 𝜇 =
𝑏
𝑎
and variance 𝜎2
=
𝑏
𝑎2
. The parameters a and b are positive integers
and “ ! ” is factorial.
c) Exponential noise – is a noise with exponential probability density function of
𝑃(𝑧) = {
𝑎𝑒−𝑎𝑧
𝑓𝑜𝑟 𝑧 ≥ 0
0 𝑓𝑜𝑟 𝑧 < 0
where the mean 𝜇 =
1
𝑎
and 𝜎2
=
1
𝑎2
for a > 0.
d) Uniform noise – is the noise with the probability density function of
𝑃(𝑧) = {
1
𝑏−𝑎
𝑖𝑓 𝑎 ≤ 𝑧 ≤ 𝑏
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
where the mean 𝜇 =
𝑎+𝑏
2
is and σ2
=
(𝑏−𝑎)2
12
is variance.
e) Impulse noise(Salt-and-pepper) – is a noise type with a probability density function of
𝑃(𝑧) = {
𝑃𝑎 𝑓𝑜𝑟 𝑧 = 𝑎
𝑃𝑏 𝑓𝑜𝑟 𝑧 = 𝑏
0 𝑜𝑡ℎ𝑒𝑟𝑤𝑖𝑠𝑒
7. 7 | P a g e
Noise Example
The test pattern to the right is ideal for demonstrating the addition of noise, The following
images will show the result of adding noise based on various models to the original image.
9. 9 | P a g e
Filters
Elimination of noise is one of the major works to be done in computer vision and image processing,
as noise leads to the error in the image. Presence of noise is manifested by undesirable information,
which is not at all related to the image under study, but in turn disturbs the information present in
the image. It is translated into values, which are getting added or subtracted to the true gray level
values on a gray level pixel. These unwanted noise information can be introduced because of so
many reasons like: acquisition process due to cameras quality and restoration, acquisition
condition, such as illumination level, calibration and positioning or it can be a function of the scene
environment. Noise elimination is a main concern in computer vision and image processing. A
digital filter is used to remove noise from the degraded image. As any noise in the image can be
result in serious errors. Noise is an unwanted signal, which is manifested by undesirable
information. Thus the image, which gets contaminated by the noise, is the degraded image and
using different filters can filter this noise. Thus filter is an important subsystem of any signal
processing system. Thus filters are used for image enhancement, as it removes undesirable signal
components from the signal of interest. Filters are of different type i.e. linear filters or nonlinear
filters. In early times, as the signals handled were analog, filters used are of analog. Gradually
digital filters were took over the analog systems because of their flexibility, low cost,
programmability, reliability, etc. for these reasons digital filters are designed which works with
digital signals.
10. 10 | P a g e
The design-of digital filters involves three basic steps:
(i) the specification of the desired properties of the system,
(ii) the approximation of these specifications using a causal discrete time system, and
(iii) the realization of the system using finite precision arithmetic.
Filtering Techniques
Filtering is a technique for enhancing the image. Linear filter is the filtering in which the value of
an output pixel is a linear combination of neighborhood values, which can produce blur in the
image. Thus a variety of smoothing techniques have been developed that are non linear.
Median Filtering
Median filter (MF) is the one of the most popular non-linear filter. Median filtering is one of the
spatial domain filter methods and as its name suggests that the median of the neighborhood pixel
value is taken and replaced with the neighborhood pixel values. The median of the pixels are taken
in such a way that the values are listed in the order from small value until big ones. Then the value
or values at the center of the list is or are taken as the median of the pixel values. In the case of
where two numbers becoming the median, it is important to take the average of the two values.
Median filtering is a very important and widely used technique of filtering and best known for its
excellent noise reduction ability. During filtering it keeps the edges while removing the noise. This
makes the image not to blur as other smoothening methods.
Spatial Filtering
In spatial filtering a certain filter mask is used in all points in an image. The filter mask is made of
m x n size where the m and n are the matrix sizes. In each case the image points should have the
same matrix size as of the filter mask with size M x N. There are two kinds of filtering, linear and
non-linear spatial filtering. In low-pass filter the attenuation of high frequencies from frequency
domains causes in the blurring of an image. While in high-pass filter the removal of low
frequencies cause in the sharpening of edges. Band-pass filtering is used for image restoration
while removing frequencies between high and low frequencies. There are many filters that are
used for blurring/smoothing, sharpening and edge detection in an image. These different effects
can be achieved by different coefficients in the mask.
Smoothing Spatial Filter
Smoothening filters can be obtained by averaging of pixels in the neighborhood of a filter mask.
It results in the blurring of an image. During noise removal or noise reduction sharp edges are
removed from the image. There are two kinds of filtering, linear and non-linear spatial filtering. In
low-pass filter the attenuation of high frequencies from frequency domains causes in the blurring
of an image.
Inverse Filtering
If we know of or can create a good model of the blurring function that corrupted an image, the
quickest and easiest way to restore that is by inverse filtering. Unfortunately, since the inverse
filter is a form of high pass filer, inverse filtering responds very badly to any noise that is present
11. 11 | P a g e
in the image because noise tends to be high frequency. In this section, we explore two methods of
inverse filtering - a thresholding method and an iterative method.
Wiener Filtering
The inverse filtering is a restoration technique for deconvolution, i.e., when the image is blurred
by a known low pass filter, it is possible to recover the image by inverse filtering or generalized
inverse filtering. However, inverse filtering is very sensitive to additive noise. The approach of
reducing one degradation at a time allows us to develop a restoration algorithm for each type of
degradation and simply combine them. The Wiener filtering executes an optimal tradeoff between
inverse filtering and noise smoothing. It removes the additive noise and inverts the blurring
simultaneously. The Wiener filtering is optimal in terms of the mean square error. In other words,
it minimizes the overall mean square error in the process of inverse filtering and noise smoothing.
The Wiener filtering is a linear estimation of the original image. The approach is based on a
stochastic framework. The orthogonality principle implies that the Wiener filter in Fourier domain
can be expressed as follows:
where are respectively power spectra of the original image and the additive
noise, and is the blurring filter. It is easy to see that the Wiener filter has two separate part,
an inverse filtering part and a noise smoothing part. It not only performs the deconvolution by
inverse filtering (high pass filtering) but also removes the noise with a compression operation (low
pass filtering).
Noise Filtering in Spatial and Frequency Domain
Noise filtering techniques were discussed in the above sections. Here I discuss only new methods
for filtering in the spatial and frequency. A salt-and-pepper noise applied to the image has resulted
in an image in shown above. Using the median filtering technique caused the noise to be removed.
Analysis of Spatial and Frequency Methods and Results
In the above sections I tried to explain the methods used to filter noise for a digital image. Noise
filtering is carried out by spatial and frequency low-pass filtering, Contrast enhancement is carried
out with spatial domain histogram stretching and sharpening of an image uses the spatial and
frequency domain high-pass filtering. The results of the methodologies will be discussed here.
Filtering to Remove Noise
We can use spatial filters of different kinds to remove different kinds of noise, The arithmetic
mean filter is a very simple one and is calculated as follows:
xySts
tsg
mn
yxf
),(
),(
1
),(ˆ
12. 12 | P a g e
This is implemented as the simple smoothing filter. Blurs the image to remove noise.
There are different kinds of mean filters all of which exhibit slightly different behaviour:
(i) Geometric Mean
(ii) Harmonic Mean
(iii) Contraharmonic Mean
There are other variants on the mean which can give different performance
Geometric Mean:
Achieves similar smoothing to the arithmetic mean, but tends to lose less image detail
Harmonic Mean:
The Harmonic Mean works well for salt noise, but fails for pepper noise, Also does well for
other kinds of noise such as Gaussian noise
m n
Sts xy
tsgyxf
1
),(
),(),(ˆ
x ySts tsg
mn
yxf
),( ),(
1
),(ˆ
13. 13 | P a g e
Contraharmonic Mean:
Q is the order of the filter and adjusting its value changes the filter’s behaviour, Positive values
of Q eliminate pepper noise, Negative values of Q eliminate salt noise
Noise Removal Examples:
Original image Image corrupted By Gaussian Noise
After a 3*3 arithmetic mean filter After a 3*3 geometric mean filter
xy
xy
Sts
Q
Sts
Q
tsg
tsg
yxf
),(
),(
1
),(
),(
),(ˆ
14. 14 | P a g e
Choosing the wrong value for Q when using the contraharmonic filter can have drastic results
Order Statistics Filters
Spatial filters that are based on ordering the pixel values that make up the neighbourhood operated
on by the filter, Useful spatial filters include:
(i) Median filter
(ii) Max and min filter
15. 15 | P a g e
(iii)Midpoint filter
(iv)Alpha trimmed mean filter
Median Filter:
Excellent at noise removal, without the smoothing effects that can occur with other smoothing
filters, Particularly good when salt and pepper noise is present
Max Filter:
Min Filter:
Max filter is good for pepper noise and min is good for salt noise
Midpoint Filter:
Good for random Gaussian and uniform noise
Alpha-Trimmed Mean Filter:
We can delete the d/2 lowest and d/2 highest grey levels, So gr(s, t) represents the remaining mn
– d pixels
)},({),(ˆ
),(
tsgmedianyxf
xySts
)},({max),(ˆ
),(
tsgyxf
xySts
)},({min),(ˆ
),(
tsgyxf
xySts
)},({min)},({max
2
1
),(ˆ
),(),(
tsgtsgyxf
xyxy StsSts
xySts
r tsg
dmn
yxf
),(
),(
1
),(ˆ
16. 16 | P a g e
Noise Removal Examples
Image
Corrupted
By Salt And
Pepper Noise
Result of 1
Pass With A
3*3 Median
Filter
Result of 2
Passes With
A 3*3 Median
Filter
Result of 3
Passes With
A 3*3 Median
Filter
17. 17 | P a g e
Image
Corrupted
By Pepper
Noise
Image
Corrupted
By Salt
Noise
Result Of
Filtering
Above
With A 3*3
Max Filter
Result Of
Filtering
Above
With A 3*3
Min Filter
18. 18 | P a g e
Adaptive Filters
The filters discussed so far are applied to an entire image without any regard for how image
characteristics vary from one point to another, The behaviour of adaptive filters changes
depending on the characteristics of the image inside the filter region, We will take a look at the
adaptive median filter
Adaptive Median Filtering
The median filter performs relatively well on impulse noise as long as the spatial density of the
impulse noise is not large, The adaptive median filter can handle much more spatially dense
impulse noise, and also performs some smoothing for non-impulse noise, The key insight in the
adaptive median filter is that the filter size changes depending on the characteristics of the image
Remember that filtering looks at each original pixel image in turn and generates a new filtered
pixel.
Image
Further
Corrupted
By Salt and
Pepper
Noise
Image
Corrupted
By Uniform
Noise
Filtered By
5*5
Arithmetic
Mean Filter
Filtered By
5*5
Geometric
Mean Filter
Filtered By
5*5 Median
Filter
Filtered By
5*5 Alpha-
Trimmed
Mean Filter
19. 19 | P a g e
First examine the following notation:
- zmin = minimum grey level in Sxy
- zmax = maximum grey level in Sxy
- zmed = median of grey levels in Sxy
- zxy = grey level at coordinates (x, y)
- Smax =maximum allowed size of Sxy
- Level A: A1 = zmed – zmin
- A2 = zmed – zmax
- If A1 > 0 and A2 < 0, Go to level B
- Else increase the window size
- If window size ≤ Smax repeat level A
- Else output zmed
- Level B: B1 = zxy – zmin
- B2 = zxy – zmax
- If B1 > 0 and B2 < 0, output zxy
- Else output zmed
The key to understanding the algorithm is to remember that the adaptive median filter has three
purposes:
(i) Remove impulse noise
(ii) Provide smoothing of other noise
(iii)Reduce distortion
20. 20 | P a g e
Adaptive Filtering Example
Periodic Noise
Typically arises due to electrical or electromagnetic interference, Gives rise to regular noise
patterns in an image, here Frequency domain techniques in the Fourier domain are most effective
at removing periodic noise
Band Reject Filters
Removing periodic noise form an image involves removing a particular range of frequencies from
that image, Band reject filters can be used for this purpose, An ideal band reject filter is given as
follows:
Image corrupted by salt and
pepper noise with probabilities
P
a
= P
b
=0.25
Result of filtering with a 7 * 7
median filter
Result of adaptive median
filtering with i = 7
21. 21 | P a g e
The ideal band reject filter is shown below, along with Butterworth and Gaussian versions of the
filter
Band Reject Filter Example
2
),(1
2
),(
2
0
2
),(1
),(
0
00
0
W
DvuDif
W
DvuD
W
Dif
W
DvuDif
vuH
Ideal Band
Reject Filter
Butterworth
Band Reject
Filter (of order 1)
Gaussian
Band Reject
Filter
Image corrupted by sinusoidal noise Fourier spectrum of corrupted image
Filtered imageButterworth band reject filter
22. 22 | P a g e
Table1. Advantages and Disadvantages of Spatial and Frequency domain methods
Spatial domain method Frequency domain method
Advantages -Direct manipulation of pixels
- Very good method for
contrast enhancement
- It is also a good method
for image sharpening
-Manipulation of frequency
-Best method for periodic
noise reduction
- Best method for image
sharpening
Disadvantages -Sometimes it shifts image
boundaries during sharpening
-Only manipulates the pixel
- Not a good method for
contrast enhancement
-Only manipulates the
frequency
Table 1 suggested that both methods are important depending on the target needed. Spatial domain
method is advantageous in contrast enhancement, while frequency domain method in periodic
noise reduction and image sharpening.
Conclusion
Image restoration is an important field that is used in different scientific researches and technology
developments. In this paper different filtering techniques were discussed, we have also looked at
image restoration for noise removal, Restoration is slightly more objective than enhancement .
Spatial domain techniques are particularly useful for removing random noise, while Frequency
domain techniques are particularly useful for removing periodic noise. The differences among the
domains and their different methodologies were briefly explained. Generally the methods are both
important and applicable in different technologies. In this paper I tried to show a comparison
between both approaches and tried to show their advantages and disadvantages. This paper
suggests that more researches is needed on many other image processing applications to show the
importance of those methods.
23. 23 | P a g e
References
1. Digital Image Processing by R. C. Gonzales and R. E. Woods, Addison-Wesley Publishing
Company, 1992.
2. Two-Dimensional Signal and Image Processing by J. S. Lim, Prentice Hall, 1990.
3. 'Digital Image Restoration', by M.R. Banham and A.K. Katsaggelos, IEEE Signal Processing
Magazine, pp. 27-41, March 1997.
4. http://www.sersc.org/journals/IJAST/vol39/5.pdf
5. http://www.jatit.org/volumes/research-papers/Vol14No2/1Vol14No2.pdf
6. http://www.owlnet.rice.edu/~elec539/Projects99/BACH/proj2/refs.html
7. https://publications.theseus.fi/bitstream/handle/10024/29065/thesis_final7.pdf?sequence=1
8. KADIR, T., BRADY, M. 2001. Saliency, Scale and Image Description. International Journal
of Computer Vision, Volume 45, Number 2.
9. R. Plemmonsa, M. Horvatha, E. Leonhardta, P. Paucaa, S. Prasadb, “Computational Imaging
Systems
10. Class Presentation notes provided by Dr Xuewen Ding, Lecturer of Digital Image Processing,
Electrical and Electronics Engineering Dept, Tianjin University of Technology and
Education
Appendices
Appendix 1
Spatial domain Algorithms
%-----contrast intensity manipulation using histogram equalization and certain %other ----------%
load image1
whos %shows the size and parameters
figure(1)
imshow(X,map) %show the image1 image
I = ind2gray(X,map); %creating intensity of an image
figure(2)
imshow(I) %show intensity
A=I.^4; %high contrast created
A = 0.2*I; %low contrast created
figure(3)
subplot(2,1,1)
imshow(A) %show contrast image
subplot(2,1,2)
imhist(A)
grid
C=(A+.085)*3; %histogram stretching
figure(5)
subplot(2,1,1)
24. 24 | P a g e
imshow(C) %show histogram
subplot(2,1,2)
hist(A(:),50)
imhist(C)
grid 62
25. 25 | P a g e
%-----------------------pixel manipulation with high pass filter mask--------------%
load images
whos
figure(1)
imshow(X,map) % Indexed image
I=ind2gray(X,map); % Converting indexed image to intensity image
figure(2)
imshow(I) % Intensity image
%My=ones(3,3)/9; %averaging mask
My=zeros(3,3);
My(1,1)=-1;
My(1,2)=-1;
My(1,3)=-1 ;
My(2,1)=-1;
My(2,2)=8;
My(2,3)=-1 ;
My(3,1)=-1;
My(3,2)=-1;
My(3,3)=-1;
M=My; %the mask „My‟ can be changed depending on the result needed
FI=I; % Intiating the output matrix
for i=2:257
for j=2:349
FI(i,j)=sum(sum(I(i-1:i+1,j-1:j+1).*M)); %filtering with the mask
end
end
figure(4)
imshow(FI) 63
26. 26 | P a g e
% --------------Implementing pixel group operation (mask operation, nearest %neighbour method,
filtering method)------------%
load images
figure(1)
imshow(X,map) % Indexed image
I=ind2gray(X,map); % Converting indexed image to intensity image
imshow(I) % Intensity image
SP=imnoise(I,'salt & pepper',0.4); % Corrupted image
figure(2)
imshow(SP)
%------------------------Median Filtering--------------------------------%
F2=SP;
for i=1+par:175 %258-par
for j=1+par:225 %350-par
AKE=SP(i-par:i+par,j-par:j+par); %ordering of pixels
F2(i,j)=median(AKE(:));
end
end
figure(4)
imshow(F2) 64
Appendix 2
Frequency domain Algorithms
%-------- Analysing an intensity image by Fourier-analysis techniques---------%
load images
I=ind2gray(X,map); % Sample set
figure(1)
imshow(I)
%------------------------Fourier Analysis--------------------------------%
FI=fft2(I); % Complex amplitudes
SFI=fftshift(FI); % Origin in the middle of the matrix
SFI(130,176) is C0 in SFI
Ck=abs(SFI); % Amplitudes
AKE=log10(Ck+1);
figure(2)
imshow(Ck) % Amplitudes with the origin in the middle of the matrix
title('Amplitudes')
a=min(AKE(:));
b=max(AKE(:));
sAKE=(AKE-a)/(b-a); % Linearly scaled logarithms
figure(3)
imshow(sAKE)
title('Scaled amplitudes') % giving titles on the image
%--------------------Simulating Noise in an Image-------------------------% 65
27. 27 | P a g e
MAT=SFI;
MAT(74,100)=800*MAT(74,100); %noise at the given coordinates
MAT(186,252)=800*MAT(186,252); %noise at the given coordinates
Ck=abs(MAT); % Amplitudes
AKE=log10(Ck+1);
a=min(AKE(:))
b=max(AKE(:))
sAKE=(AKE-a)/(b-a); % Linearly scaled logarithms
figure(4)
imshow(sAKE)
title('Scaled amplitudes')
IMG=ifft2(MAT);
figure(5)
imshow(abs(IMG))
%---------------------Ideal Low Pass Filter-------------------------------%
[m,n]=size(I);
M=zeros(m,n); % Initiating the low pass mask
M(130-par:130+par,176-par:176+par)=1;
fMAT=MAT.*M; % Filtering MAT
IMG2=ifft2(fMAT);
figure(6)
imshow(abs(IMG2))
%--------------Mask as an Amplitude Spectrum of an Image----------------%
figure(7) % Amplitude spectrum in frequency domain
subplot(2,1,1)
imshow(M)
subplot(2,1,2)
plot(M(130,:))
grid 66
28. 28 | P a g e
IMG3=fftshift(ifft2(M));
figure(8)
aIMG3=abs(IMG3);
a3=min(aIMG3(:));
b3=max(aIMG3(:));
sIMG3=(aIMG3-a3)/(b3-a3); % enhancing the image with max. and min.values % while
removing the rest of the frequency values
%----------------------Butterworth Low Pass Filter---------------------------%
[V,U]=meshgrid(-175:174,-129:128);
D=sqrt(U.^2+V.^2);
H=1./(1+(D/D0).^(2*N)); % Butterworth Low Pass Filter
figure(9) % Amplitude spectrum in frequency domain
subplot(2,1,1)
imshow(H)
subplot(2,1,2)
plot(H(130,:))
grid
%------------------------------Notch Filter----------------------------------%
D1=sqrt((U+56).^2+(V+76).^2);
D2=sqrt((U-56).^2+(V-76).^2);
H1=1./(1+(D1/D0).^(2*N)); %implementing the notch filter formula
H2=1./(1+(D2/D0).^(2*N)); %implementing the notch filter formula
figure(9)
imshow(D2/max(D2(:)))
Hlow=H1+H2; % Local low pass filter in pole positions
High=1-Hlow;
figure(10)
imshow(High)
Inverse filter code
N=256;
n=.2;
f=freadbin('lenna.256',N,N);
figure(1)
imagesc(f)
colormap(gray)
b=ones(4,4)/4^2;
F=fft2(f);
B=fft2(b,N,N);
G=F.*B;
g=ifft2(G)+10*randn(N,N);
G=fft2(g);
figure(2)
imagesc(abs(ifft2(G)))
29. 29 | P a g e
colormap(gray)
BF=find(abs(B)<n);
%B(BF)=max(max(B))/1.5;
B(BF)=n;
H=ones(N,N)./B;
I=G.*H;
im=abs(ifft2(I));
figure(3)
imagesc(im)
colormap(gray)
Iterative method code
N=256;
lambda=0.1;
f=freadbin('lenna.256',N,N);
figure(1)
imagesc(f)
colormap(gray)
F=fft2(f);
b=ones(4,4)/16;
B=fft2(b,N,N);
G=F.*B;
%g=ifft2(G)+10*randn(N,N);
%G=fft2(g);
figure(2)
imagesc(abs(ifft2(G)))
colormap(gray)
K=lambda*G;
for l=1:1500,
if mod(l,25)==0
lambda=lambda/5;
end
A=G-K.*B;
K=K+lambda*A;
if mod(l,50)==0
l
sum(sum(A))
figure(3)
imagesc(abs(ifft2(K)))
colormap(gray)
pause
end
end