ICCCCT’10
An Adaptive Noise Cancellation Scheme Using Particle Swarm Optimization Algorithm Upal Mahbub, Celia Shahnaz, Member, IEEE and Shaikh Anowarul Fattah, Member, IEEE Department of Electrical and Electronic Engineering Bangladesh University of Engineering and Technology Dhaka, Bangladesh E-mail:
[email protected];
[email protected];
[email protected]
Abstract— This paper deals with the problem of noise cancellation of speech signals in an acoustic environment. In this regard, generally, different adaptive filter algorithms are employed, many of them may lack the flexibility of controlling the convergence rate, range of variation of filter coefficients, and consistency in error within tolerance limit. In order to achieve these desirable attributes as well as to cancel noise effectively, unlike conventional approaches, we formulate the task of noise cancellation as a coefficient optimization problem whereby we introduce and exploit the particle swarm optimization (PSO) algorithm. In this problem, the PSO is designed to perform the error minimization in frequency domain. The outcomes from extensive experimentations show that the proposed PSO based acoustic noise cancellation method provides high performance in terms of SNR improvements with a satisfactory convergence rate in comparison to that obtained by some of the state-of-the-art methods. Keywords— Noise cancellation, adaptive filter, particle swarm optimization algorithm.
I. INTRODUCTION The problem of noise cancellation has received considerable attention in recent years in many speech applications, such as speech recognition, speaker verification, and speech bandwidth compression [1]-[3]. For example, in automatic speech recognition from noise-corrupted speech, the noise cancellation schemes provide an improved quality of speech signal that helps in achieving a better recognition performance. In single channel noise cancellation techniques, generally, the noise power is first estimated from the observed noisy signal and then spectral subtraction-based algorithms are employed [2]. However, these techniques exhibit performance limitations under real operational scenarios, as they cause musical noise and signal distortion in the process. Moreover, their performance strongly depends on noise characteristics and a satisfactory performance is only expected when the observation noise can be assumed as stationary. It is to be noted that in real life applications, most of the cases, the properties of signal and noise are varying with time, such as noisy environments in cars, factories and cafeteria. In order to overcome such limitations of single channel noise cancellation techniques, the adaptive noise cancellation (ANC) algorithms are commonly used. In the ANC schemes, in addition to the primary channel capturing the noisy observations, a secondary estimated noise can be subtracted from the primary channel resulting in the desired signal. Because of the availability of the reference noise input, the ANC techniques offer the
978-1-4244-7770-8/10/$26.00 ©2010 IEEE 683
advantage of sensing the change in noise level and pattern promptly and easily. Different adaptive filter algorithms are used in the dual channel ANC techniques [4], [5]. Among them, the gradient based adaptive algorithms, such as least mean-squares (LMS) and normalized LMS (NLMS) are most commonly used. These algorithms are not suitable for multimodal error surface, as they are likely to stick in local optima. The objective of this paper is to formulate the ANC problem, unlike conventional adaptive filter algorithms, as an optimization task, so that the probability of encountering the global optimum is increased. In view of this, we employ an efficient optimization tool, the particle swarm optimization (PSO), which has received much attention in the areas of function optimization, pattern classification, and control system [6], [7]. In comparison to many other optimization algorithms, the PSO provides advantages of faster convergence rate, strong global search, simplicity of the algorithm, few adjustable parameters, and ease of implementation [8], [9]. One of the major concerns of the proposed ANC scheme lies in the idea of designing the PSO algorithm in frequency domain. II. PROBLEM FORMULATION A general block diagram for an adaptive noise cancellation (ANC) scheme is represented in Fig. 1. In this system, two distant microphones are employed to capture the nature of the noise and the speech sound simultaneously. One of the two microphones (Mic-1) captures the original noise-free speech s(n) along with the additive background noise u(n). The noise u(n) corrupting the speech is assumed to be a filtered version of the reference noise v(n) captured by a second microphone (Mic-2). It is to be mentioned that the transfer function F(z) of the filter operating on v(n) mainly depends on the environment surrounding the microphones. For example, in a conference room, filter transfer function is governed by the room response. The noise corrupted signal y(n) can be expressed as, (1) y ( n ) = s ( n) + u ( n )
ICCCCT’10 Mic 1
y(n)=s(n)+u(n)
s(n)
+
in severe noisy environments. Our objective is to develop an effective adaptive noise cancellation scheme by introducing and using an optimization algorithm in frequency domain, which can handle these problems.
e(n)
ũ(n)
u(n) Room Response F(z)
III. PROPOSED ADAPTIVE NOISE CANCELLATION SCHEME Mic 2 W(z)
v(n) Noise Source
Fig. 1. Illustration of two channel adaptive noise cancellation.
where, the z-domain representation of u(n) can be expressed as, (2) U ( z ) = F ( z )V ( z ) with V (z) symbolizing the z-domain representation of v(n). A correlation between u(n) and v(n) is necessary to adaptively cancel the noise from the noise-corrupted speech signal y(n). In Fig. 1, the signal v(n) received by the Mic-2 is fed to the adaptive filter block. The output of the adaptive filter W(z) is an estimate ũ(n) of u(n) given the reference input v(n). The purpose of an adaptive filtering algorithm is to identify the unknown parameters of the transfer function F(z) by minimizing the error e(n) between the output of the adaptive filter and the noisy speech signal. Here, the error e(n) can be expressed as
e( n) = y (n) − u% ( n) = s (n) + u ( n) − u% (n)
A. PSO Approach for ANC PSO is a population based search procedure in which the individuals, called particles, adjust their position to search through the solution space. Each particle pi has a position vector di = (di1, di2,..., dib, ...diK) and a velocity vector Ωi= (Ωi1, Ωi2, ..., ΩiK). At each iteration the particle learns from its own previous best position λib and the best position of all the other particles χib in the swarm, and updates its’ velocity and position. The update equation at (t + 1)-th iteration can be written as follows
Ωib (t + 1) = ∆(t )Ωib (t ) + c1r1i (t )(λib (t ) − d ib (t )) + c2 r2i (t )( χ ib (t ) − d ib (t )),
(3)
dib (t + 1) = dib (t ) + Ωib (t + 1)
It is clear from (3) that the error e(n) approaches to the noisefree speech signal s(n) when an accurate estimate ũ(n) of the noise u(n) is obtained. One of the conventional solutions of the problem as stated above, is to use least mean square (LMS) adaptive algorithm [1]. In the LMS algorithm, initial values of the filter coefficients are arbitrarily chosen, and they are updated with each sample using the following update equation,
w( n + 1) = w( n) + 2 µ e( n) x( n)
In the previous section, it is shown that, in order to solve the acoustic noise cancellation problem, adaptive filter algorithms are used. However, the task can also be modeled as an optimization problem, where an objective function is to be defined based on the error in (3). In this paper, unlike conventional approaches, we introduce the particle swarm optimization algorithm (PSO) and propose to optimize an objective function in frequency domain by using the PSO algorithm. In what follows, first a brief introduction to the PSO is given and then the new noise cancellation scheme using the PSO in frequency domain is presented.
(5)
(6)
where c1 and c2 are the cognitive and social scaling parameters respectively, and r1i and r2i are random numbers in the range of [0, 1]. In (6), the inertia weight ∆(t) at the t-th iteration is used to maintain the particles’ momentum. The update equation for the inertia weight at (t + 1)-th iteration can be expressed as
∆(t + 1) = ∆initial −
∆ initial − ∆ final I m ax
.I (t )
(7)
(4)
where w(n+1) is the array of updated filter coefficients, x(n) is the filter input and µ is the step size which determines the convergence rate. One popular variation of the LMS algorithm, namely the normalized LMS (NLMS) is also used in adaptive noise cancellation [10], [11]. However, these traditional adaptive filter algorithms may lack the flexibility of controlling the convergence rate, range of variation of filter coefficients, and consistency in error within tolerance limit. Also, their performance in terms of SNR improvement is not satisfactory
where Imax represents the maximum number of iterations, and I(t) is the number of iterations or generations already performed upto the t-th iteration. ∆initial and ∆final are the maximum and minimum values of the inertia weight, respectively. As there are few parameters to adjust for the PSO and its updating procedure has only simple arithmetic operations, it is a good choice for fast optimization [8]. The PSO algorithm provides a better control of the adaptation process. It allows the user to control the number of particles, particles’ maximum velocity, ranges of each coefficients, tolerance level, and stability.
684
ICCCCT’10 SNR improvement with number of particles SNR improvement (dB)
B. Proposed Frequency-domain ANC In the proposed frequency domain approach, the error is defined in the discrete frequency domain as ~ (8) E( f ) = Y ( f ) − U ( f ) here Y (f) is the discrete Fourier transform of the noisy signal and for any particle, we obtain Ũ(f) as noise reference signal. The objective function in the proposed frequency domain approach is thus defined as f = N −1
Eo( f ) =
~
∑ (Y ( f ) − U ( f ))
2
(9)
f =1
where N is the number of discrete frequency points. The PSO adaptive algorithm tries to minimize this error by varying the estimated filter coefficients. C. Employing the PSO in the Proposed Scheme In the proposed PSO based adaptive noise cancellation scheme, objective function defined in (10) is utilized to find out the optimum values of the parameters of the model adaptive filter W(z) as shown in Fig. 1. In this optimization procedure, the error function is minimized when the filter coefficients of W(z) are perfectly tuned with the room impulse response F(z). The speech is processed frame-by-frame using 25ms time window. For each window, the filter estimates the coefficients by minimizing the objective function. For a particular set of PSO parameters, different particles are assigned initial filter coefficients and after each iteration, these coefficient values, which correspond to the particles’ position in sample space, are updated. When processing the next window, the estimated filter coefficients of the previous frame is supplied to the adaptive algorithm as initial values, which, accelerates the convergence of the process and ensures better estimation. The searching procedure can be enhanced by narrowing the searching region. IV. SIMULATION RESULTS In order to investigate the performance of the proposed PSO-based scheme, extensive experimentations have been carried out and results are compared with those obtained by some of the state-of-the-art adaptive filer algorithms, namely the LMS and NLMS algorithms. For the purpose of simulating various acoustic environments, the room impulse response is modeled using the FIR filter with different number of unknown coefficients and several types of real-life additive noises are taken into consideration. In order to generate noisy speech observations, different standard speech and noise databases are used. In what follows, we have demonstrated the noise cancellation performance considering the “Noizeus” database [12]. The noisy speech is processed frame by frame with a frame-duration of 25 ms, where the frames are obtained
60
40
20
0 5
10
15
20
25
30
35
40
No. of particles
Fig. 2. SNR improvement with the variation in the number of PSO particles for a male voice under babble noise at SNR = 0 dB
by using hanning window with 50% overlapping. As a performance measurement criterion of the noise cancellation algorithms, the signal to noise ratio (SNR) in dB of the original noisy signal y(n) is compared with that of the noisereduced signal e(n) obtained after the noise cancellation operation. In the proposed PSO-based noise cancellation scheme, among the major PSO-parameters, the number of particles plays an important role on the noise cancellation performance. For a particular level of input noise, the effect of variation in number of particles on the SNR improvement obtained by the proposed noise cancellation scheme has been investigated. In Fig. 2, for an input SNR of 0 dB, the SNR improvement obtained at different values of number of particles in the presence of multi-talker Babble noise is shown. The sample speech used in this experiment is a male voice uttering the sentence, “We find joy in the simplest things” [12]. In our experimentation, the following PSO parameters are employed: tolerance between two consecutive global best values is 10-30, search range for coefficients is [0 1], c1 = 2, c2 = 2, initial number of iterations for frequency domain PSO is 4, ∆initial = 0.9, ∆final = 0.4, and the maximum particle velocity dmax is initially set at 0.5 and after two windows it is changed to 0.1. It is observed from Fig. 2 that the value of SNR improvement remains quite stable with the increase of number of particles. Even with a very small number of particles (say less then 20) a high degree of noise cancellation can be achieved. It is to be noted that the increase in number of particles causes an increase in the computational burden of the PSO technique. Hence, an attractive feature of the proposed method lies in the fact that even to achieve an excellent performance, the use of a very large number of particles is not necessarily required. Next, we investigate the effect of change in input noise level on the overall SNR improvement. In Fig. 3, SNR improvements obtained by different methods in the presence of multi-talker Babble noise are shown for female and male speakers. The first sample speech is a female voice uttering the sentence, “He wrote down a long list of items” while the second one is the male speech used in Fig. 2 [12]. In this experiment, the initial number of PSO particles is set to 10 and after two iterations it is changed to 6. It is observed from these figures that the SNR improvements obtained by the proposed methods remain higher at all levels of input SNR. It
685
ICCCCT’10 SNR improvement with varying number of filter coefficients
Proposed method
60
SNR improvement (dB)
SNR improvement (dB)
SNR improvement by different methods (Female Voice)
LMS method NLMS method 40
20
0 -10
-5
0
5
10
LMS method LMS method 40
20
0 2
Input signal SNR (dB)
Proposed method
60
3
4
5
6
7
8
9
10
Number of filter coefficients of the room response
(a) Fig. 4. SNR improvement with the variation in the number of unknown filter coefficients of the room impulse response for a male voice under babble noise at SNR = 0 dB.
SNR improvement (dB)
SNR improvement by different methods (Male Voice) Proposed method LMS method NLMS method
60
40
satisfactory convergence rate, in comparison to that obtained by other state-oft-the-art methods.
20
ACKNOWLEDGEMENTS
0 -10
-5
0
5
The authors would like to express their sincere gratitude towards the authorities of the Department of Electrical and Electronic Engineering and Bangladesh University of Engineering and Technology (BUET) for providing constant support throughout this research work.
10
Input signal SNR (dB)
(b) Fig. 3. SNR improvement with the variation in the input SNR under babble noise: (a) for a female voice, (b) for a male voice.
can be concluded that the performance of the proposed PSObased scheme in terms of the SNR improvement is superior to that of the LMS and NLMS methods irrespective of types of voice (male/female). In order to simulate various acoustic environments, the number of unknown filter coefficients of the room response is varied. In Fig. 4, for an input SNR of 0 dB, the SNR improvement obtained for different number of filter coefficients in the presence of Babble noise is presented. It is found that for all different room response scenarios, the SNR improvements obtained by the proposed scheme remains considerably higher than those obtained by other methods. V. CONCLUSION
REFERENCES [1]
[2]
[3]
[4]
[5]
[6]
The main idea in this paper is to develop an adaptive noise cancellation scheme employing the PSO algorithm both in time and frequency domain. In the development of the proposed scheme, effect of variation of a major PSO parameter, the number of particles, has been taken in consideration along with different acoustic environments. Noise cancellation performance has been tested considering different variations in filter parameters resulting in various acoustic operating conditions as well as several types of noise and different voices. The outcomes have been compared with that of some of the standard techniques, such as the LMS and the NLMS adaptive algorithms. It has been shown that, the proposed time and frequency domain PSO based schemes exhibit superior performance under various acoustic conditions in terms of SNR improvement, while maintaining a
[7] [8] [9]
[10]
[11]
[12]
686
J. M. Gorriz, J. Ramrez, S. C. Alvarez, C. G. Puntonet, E. W. Lang, and D. Erdogmus, “A novel LMS algorithm applied to adaptive noise cancellation,” IEEE Signal Processing Letters, vol. 16, pp. 44–47, Jan. 2009. C.-T. Lin, “Single-channel speech enhancement in variable noise-level environment,” IEEE Trans. Systems, Man, Cybernetics-Part A: Systems and Humans, vol. 33, pp. 137–144, Jan. 2003. M. S. Ahmed, “Comparison of noisy speech enhancement algorithms in terms of LPC perturbation,” IEEE Trans. Acoust., Speech, Signal Processing, vol. 37, pp. 121–125, Jan. 1989. J. Beh, R. H. Baran, and H. Ko, “Dual channel based speech enhancement using novelty filter for robust speech recognition in automobile environment,” IEEE Trans. Consumer Electronics, vol. 52, pp. 583–589, May 2006. J.-S. Hu, C.-C. Cheng, W.-H. Liu, and C.-H. Yang, “A robust adaptive speech enhancement system for vehicular applications,” IEEE Trans. Consumer Electronics, vol. 52, pp. 1069–1077, Aug. 2006. M. Geravanchizadeh, “A sexual reproduction-based adaptive quantum particle swarm optimization algorithm for dual-channel speech enhancement,” Int. Symp. Communications, Control, Signal Processing, ISCCSP, Mar. 2010. X. Hu, “Particle swarm optimization.” [Online]. Available: http://www.swarmintelligence.org/tutorials.php Q. Bai, “Analysis of particle swarm optimization algorithm,” Computer and Information Science, vol. 3, 2010. R. C. Eberhart and J. Kennedy, “A new optimizer using particles swarm theory,” Int. Symp. Micro Machine, Human Science, pp. 39–43, 1995. L. Bai and Q. Yin, “A modified nlms algorithm for adaptive noise cancellation,” Int. Conf. Acoust., Speech, Signal Processing (ICASSP), pp. 3726 – 3729, 2010. J. R. Mohammed, “A new simple adaptive noise cancellation scheme based on ALE and NLMS filter,” Annual Conf. Communication, Networks, Services Research, pp. 245 – 254, May 2007. Y. Hu and P. Loizou, “Subjective evaluation and comparison of speech enhancement algorithms,” Speech Communication, vol. 49, pp. 588– 601.