语音通信终端背景噪声的消除装置及方法 Device and method for eliminating background noise of voice communication terminal
技术领域 Technical field
本发明涉及通信终端语音处理技术, 特别是涉及一种语音通信终端 背景噪声的消除装置及方法。 发明背景 The present invention relates to a communication terminal voice processing technology, and in particular to a device and method for eliminating background noise of a voice communication terminal. Background of the invention
随着通信技术的飞速发展和日益普及, 通信已经成为人们日常联络 交流的一种重要手段, 因此, 人们对通话的语音质量也提出了更高的要 求。 在实际通信中, 通信用户双方常常在一些嘈杂的背景环境下进行通 话。 这时, 接收方用户听到的声音不仅包括发送方用户的说话话音, 还 包括发送方和接收方用户周围其它声音, 比如他人话音、 脚步声、 物品 碰撞声、 音乐以及交通工具发出的声音等。 这些除了通信用户双方的说 话话音之外的声音称为背景噪声, 位于发送方用户周围的背景噪声称为 发送方背景噪声, 位于接收方用户周围的背景噪声称为接收方背景噪 声。 With the rapid development and increasing popularity of communication technologies, communication has become an important means of daily communication and communication. Therefore, people have put forward higher requirements for the voice quality of calls. In actual communication, both communication users often talk in some noisy background environment. At this time, the sound heard by the recipient user includes not only the voice of the sender user, but also other voices around the sender and the receiver, such as voices of others, footsteps, collision of objects, music, and sounds from vehicles. . These sounds other than the speech voices of the communication users are called background noise, the background noise around the sender's user is called the sender's background noise, and the background noise around the receiver's user is called the receiver's background noise.
图 1为移动通信终端的语音传递过程示意图, 其中, 发送方麦克风 同时接收发送方语音和发送方背景噪声, 经过对收到的声音进行釆样和 编码、 传输、 解码处理后, 传送给接收方耳机或喇叭, 接收方通过耳机 或喇叭收听传递来的声音, 同时也听到接收方背景噪声。 由此可见, 语 音在传递过程收到发送方背景噪声和接收方背景噪声的双重干扰。 在很 多情况下, 背景噪声掩盖了通信说话人的话音, 使接收方听者不能正确 地获取说话者发送的语音信息, 从而造成通信的困难。 1 is a schematic diagram of a voice transmission process of a mobile communication terminal, wherein a sender microphone simultaneously receives a sender voice and a sender background noise, and after transmitting, encoding, transmitting, and decoding the received voice, transmitting to the receiver Headphones or speakers, the receiver listens to the transmitted sound through headphones or speakers, and also hears the receiver's background noise. It can be seen that the speech receives double interference of the sender's background noise and the receiver's background noise during the transmission process. In many cases, the background noise masks the voice of the communicating speaker, making the recipient's listener unable to correctly acquire the voice information sent by the speaker, thereby causing communication difficulties.
基于图 1所示的移动通信终端的语音传递过程,现有移动通信终端, 比如 CDMA手机和 GSM手机在发话方的声码器对语音进行编码之前,
均采用自适应滤波技术来消除发送方背景噪声。 图 2为现有技术移动通 信终端中发送方背景噪声的消除装置结构组成示意图, 包括: 麦克风 201、 采样模块 202、 自适应滤波器 203和语音编码模块 204。 Based on the voice delivery process of the mobile communication terminal shown in FIG. 1, existing mobile communication terminals, such as CDMA mobile phones and GSM mobile phones, before the vocoder of the utterer encodes the voice, Adaptive filtering techniques are used to eliminate the sender's background noise. 2 is a schematic structural diagram of a device for canceling a background noise of a sender in a mobile communication terminal of the prior art, including: a microphone 201, a sampling module 202, an adaptive filter 203, and a speech encoding module 204.
其中, 麦克风 201接收发送方语音和背景噪声, 然后将收到的发送 方语音和背景噪声传送给采样模块 202; 釆样模块 202收到发送方语音 和背景噪声后, 对其进行采样, 即将模拟信号转换成数字信号, 并将获 得的数字信号输出给自适应滤波器 203; 自适应滤波器 203对收到的信 号进行背景噪声的消除,并将剩下的语音信号输出给语音编码模块 204; 语音编码模块 204对收到的语音信号进行编码。 The microphone 201 receives the sender voice and the background noise, and then transmits the received sender voice and background noise to the sampling module 202. After receiving the voice and background noise, the sample module 202 samples the sample, which is to be simulated. The signal is converted into a digital signal, and the obtained digital signal is output to the adaptive filter 203; the adaptive filter 203 performs background noise cancellation on the received signal, and outputs the remaining speech signal to the speech encoding module 204; Speech encoding module 204 encodes the received speech signal.
其中, 自适应滤波器 203的具体结构如图 3所示。 其中, x(n)为经 过采样处理的麦克风接收到的输入信号, 包括发送方语音信号 s(n)和发 送方背景噪声信号 v(n), 即 x(n) = s(n) + v(n)。 x(n)经过延迟 Δ后得到 χ(η-Δ)= s(n-A) + v(n-A), χ(η-Δ)通过自适应滤波器 203的滤波器部分, 输 出语音信号 s(n)的估计值 , 并把估计值 (/7)与输入信号 x(n)相减得到 误差信号 e(n)。 其中的相减运算不是一般的代数相减, 而是需要相应的 算法进行运算, 比如相关功率的功率谱密度分析等。 The specific structure of the adaptive filter 203 is shown in FIG. 3. Where x(n) is the input signal received by the sampled microphone, including the sender voice signal s(n) and the sender background noise signal v(n), ie x(n) = s(n) + v (n). After x(n) is delayed by Δ, χ(η-Δ)= s(nA) + v(nA) is obtained, and χ(η-Δ) passes through the filter portion of the adaptive filter 203, and the speech signal s(n) is output. The estimated value, and the estimated value (/7) is subtracted from the input signal x(n) to obtain an error signal e(n). The subtraction operation is not a general algebraic subtraction, but requires a corresponding algorithm to perform operations, such as power spectral density analysis of the relevant power.
自适应滤波器 203采用最小均方误差 ( LMS , Least Mean Square ) 算法, 其权值 由误差信号 e(n) = x(n)-;(") = v(n) + (s(n)-;(") )调节, 其中, 0≤ ≤M - 1 , M是滤波器的阶数。 如果定义权值矢量 W(n)和输入 矢量 X n)分别为: The adaptive filter 203 employs a Least Mean Square (LMS) algorithm whose weight is determined by the error signal e(n) = x(n)-;(") = v(n) + (s(n) -;(") ) adjustment, where 0 ≤ ≤ M - 1 , M is the order of the filter. If the weight vector W(n) and the input vector X n) are defined as:
f (") = [w。(") wx (n) ■■■ wM_2 (n) wM_x (n) f (") = [w.(") w x (n) ■■■ w M _ 2 (n) w M _ x (n)
X(n) = [x0 (n) χ (η) · · · xM_2 (n) X(n) = [x 0 (n) χ (η) · · · x M _ 2 (n)
则自适应滤波器的 LMS算法可以表达为: Then the LMS algorithm of the adaptive filter can be expressed as:
s(n) = WT (n)X(n— Δ) = WT (n)S(n— Δ) + WT (n)V(n - Δ)
e(n)=x(n) - s(n) s(n) = W T (n)X(n - Δ) = W T (n)S(n - Δ) + W T (n)V(n - Δ) e(n)=x(n) - s(n)
W(n+1) = W(n) + μΧ(η)θ(η)0 W(n+1) = W(n) + μΧ(η)θ(η) 0
其中, μ是根据最小均方误差准则进行搜索时的步长因子。 Where μ is the step factor when searching according to the minimum mean square error criterion.
由于语音具有准周期性, 因此语音信号 s(n)和 s(n-A)强相关, 同时 认为噪声信号 v(n)和 ν(η-Δ)不相关, 且也认为噪声信号和语音信号不相 关。 基于这一假设, 可以估计出输入信号 χ(η)中相关性较强的成分。 同 时, 调整滤波器的权值 »使 e(n)的均方误差最小, 就可以得到语音信 号 s(n)在最小均方误差准则下的最佳估计值 。 Since the speech has quasi-periodicity, the speech signals s(n) and s(nA) are strongly correlated, and the noise signals v(n) and ν(η-Δ) are considered irrelevant, and the noise signal and the speech signal are also considered uncorrelated. . Based on this assumption, a highly correlated component of the input signal χ(η) can be estimated. At the same time, adjusting the weight of the filter » to minimize the mean square error of e(n), the best estimate of the speech signal s(n) under the minimum mean square error criterion can be obtained.
虽然现有技术提供的消除发送方背景噪声的方案可以减少背景噪声 对语音的干扰, 但是现有技术仅考虑到消除发送方背景噪声, 而对接收 方背景噪声没有进行任何处理, 忽略了接收方背景噪声对接收方耳机发 出的声音的干扰, 特别是当接收方处于嘈杂环境时, 接收方背景噪声对 说话者的语音干扰尤其严重。 而目前移动通信终端克服接收方背景噪声 的方法是釆用提高耳机的音量, 这种方法受耳机最大音量的限制, 在嘈 杂环境中的效果依然很差。 同样地, 现有的固定通信终端也存在上述问 题。 发明内容 Although the prior art scheme for eliminating the background noise of the sender can reduce the interference of the background noise to the voice, the prior art only considers to eliminate the background noise of the sender, and does not perform any processing on the background noise of the receiver, ignoring the receiver. The background noise interferes with the sound emitted by the receiver's earphones, especially when the receiver is in a noisy environment, and the receiver's background noise is particularly severe to the speaker's voice. At present, the method for the mobile communication terminal to overcome the background noise of the receiver is to increase the volume of the earphone. This method is limited by the maximum volume of the earphone, and the effect in the noisy environment is still poor. Similarly, the existing fixed communication terminal also has the above problems. Summary of the invention
有鉴于此, 本发明的主要目的在于提供一种语音通信终端背景噪声 的消除装置, 能够对接收方背景噪声进行消噪处理, 减少接收方背景噪 声对接收者的干扰。 In view of this, the main object of the present invention is to provide a device for canceling the background noise of a voice communication terminal, which can perform noise cancellation processing on the background noise of the receiver and reduce interference of the receiver background noise on the receiver.
本发明的另一目的在于提供一种语音通信终端背景噪声的消除方 法, 能够减少接收方背景噪声对接收者的干扰。 Another object of the present invention is to provide a method for canceling background noise of a voice communication terminal, which can reduce interference of receiver background noise to a receiver.
基于上述第一个主要目的本发明提供了一种语音通信终端背景噪声 的消除装置, 所述语音通信终端中包括有用于将输入的声音信号转换为
声音进行播放的播放器; Based on the above first main object, the present invention provides a device for canceling background noise of a voice communication terminal, the voice communication terminal including for converting an input sound signal into a player that plays sounds;
该装置包括: The device includes:
声音传感模块,用于采集所述播放器播放的声音和接收方背景噪声, 转换成声音信号并输出; a sound sensing module, configured to collect sound played by the player and background noise of the receiver, convert the sound into a sound signal, and output the sound signal;
自适应滤波器, 用于根据输入的来自声音传感模块的声音信号和来 自发送方的语音信号, 计算所述声音传感模块的声音信号中含有的噪声 信号并输出; An adaptive filter, configured to calculate and output a noise signal contained in a sound signal of the sound sensing module according to the input sound signal from the sound sensing module and the voice signal from the transmitting side;
噪声估计模块, 用于根据所述自适应滤波器输出的噪声信号预测接 收方背景噪声信号并输出; a noise estimation module, configured to predict and output a receiver background noise signal according to the noise signal output by the adaptive filter;
加法器模块, 用于将所述噪声估计模块输出的接收方背景噪声信号 与发送方语音信号进行反相位叠加并输入至所述语音通信终端的播放 器。 And an adder module, configured to inversely superimpose the receiver background noise signal output by the noise estimation module and the sender voice signal into the player of the voice communication terminal.
该装置所述声音传感模块输出的信号为模拟信号; 该装置进一步包 括: A/D变换模块, 用于将所述声音传感模块输出的模拟信号转换成数 字信号并输入至所述自适应滤波器 The signal output by the sound sensing module of the device is an analog signal; the device further includes: an A/D conversion module, configured to convert an analog signal output by the sound sensing module into a digital signal and input the Filter
该装置所述声音传感模块数量为两个或两个以上。 The number of the sound sensing modules of the device is two or more.
该装置进一步包括叠加器; The device further includes an inserter;
所述叠加器位于所述声音传感模块和 A/D变换模块之间, 用于将多 个声音传感模块输出的模拟信号进行叠加并输出给 A/D变换模块; The adder is located between the sound sensing module and the A/D conversion module, and is configured to superimpose and output the analog signals output by the plurality of sound sensing modules to the A/D conversion module;
或者所述叠加器位于 A/D变换模块和自适应滤波器之间, 用于将多 个声音传感模块输出给 A/D变换模块的、由 A/D变换模块分別进行模数 转换后的信号进行叠加, 并输出给自适应滤波器。 Or the adder is located between the A/D conversion module and the adaptive filter, and is used for outputting the plurality of sound sensing modules to the A/D conversion module and performing analog-to-digital conversion by the A/D conversion module respectively. The signals are superimposed and output to an adaptive filter.
该装置所述 A/D变换模块为用于对多个声音传感模块输出的信号分 别进行模数转换并分别输出给自适应滤波器的 A/D变换模块;所述自适 应滤波器为用于接收所述 A/D 变换模块输出的多路信号并分别进行滤
波处理的自适应滤波器。 The A/D conversion module of the device is an A/D conversion module for respectively performing analog-to-digital conversion on signals output by a plurality of sound sensing modules and outputting the signals to an adaptive filter respectively; Receiving multiple signals output by the A/D conversion module and filtering separately Wave adaptive filter.
基于上述另一个主要目的本发明提过了一种语音通信终端背景噪声 的消除方法, 包括: Based on the above another main object, the present invention provides a method for eliminating background noise of a voice communication terminal, including:
a. 采集接收方用户接听的包含有发送方语音和接收方背景噪声的 声音信号; a. collecting a sound signal that is received by the recipient user and includes the sender's voice and the receiver's background noise;
b. 从步骤 a获得的信号中估计出接收方背景噪声信号; b. estimating the receiver background noise signal from the signal obtained in step a;
c 将估计得到的接收方背景噪声信号反相位后与语音通信终端收 到的发送方语音信号进行叠加后向接收方用户播放。 c The estimated background noise signal of the receiver is reversed and then superimposed with the sender voice signal received by the voice communication terminal, and then played to the receiver user.
该方法步骤 a所述釆集声音信号的方法为: 将釆集到的声音转换为 模拟信号, 通过模数转换转换为数字信号。 The method for collecting the sound signal in the method step a is: converting the collected sound into an analog signal and converting it into a digital signal through analog-to-digital conversion.
该方法步骤 a所述采集的声音为分多路釆集, 在将采集到的声音转 换为模拟信号后, 进一步包括: The sound collected in the method step a is divided into multiple channels, and after converting the collected sound into an analog signal, the method further includes:
将多路模拟信号进行叠加后进行模数转换; Performing analog-to-digital conversion by superimposing multiple analog signals;
或者分别将多路模拟信号进行模数转换, 将转换结果进行叠加; 或者分别将多路模拟信号进行模数转换, 并分别输出。 Or respectively, multi-channel analog signals are subjected to analog-to-digital conversion, and the conversion results are superimposed; or the multi-channel analog signals are respectively subjected to analog-to-digital conversion, and respectively output.
该方法步骤 b包括: 以语音通信终端收到的发送方语音信号作为自 适应滤波处理的参考信号, 利用自适应滤波处理计算步驟 a获得信号中 的噪声信号估计值, 然后利用该噪声信号估计值预测接收方背景噪声信 号的估计值。 The method step b includes: using the sender voice signal received by the voice communication terminal as a reference signal for adaptive filtering processing, using the adaptive filtering processing calculation step a to obtain the noise signal estimation value in the signal, and then using the noise signal estimation value The estimated value of the receiver's background noise signal is predicted.
该方法所述利用自适应滤波处理获得噪声信号的方法为: 利用最小 均方误差算法获得噪声信号的估计值。 The method for obtaining a noise signal by using adaptive filtering processing in the method is: obtaining an estimated value of the noise signal by using a minimum mean square error algorithm.
该方法步骤 a获得的信号为多路, 步骤 b中对多路输入信号分别进 行自适应滤波处理, 并选择经过自适应滤波处理所得到的多个处理结果 中的最大值或本次所有处理结果之和作为噪声信号的估计值。 The signal obtained in step a of the method is multiplexed, and the multiple input signals are respectively adaptively filtered in step b, and the maximum value of the plurality of processing results obtained through the adaptive filtering process or all the processing results of the current time are selected. The sum is used as an estimate of the noise signal.
该方法所述预测接收方背景噪声信号估计值的方法为: 当前时刻的
背景噪声信号估计值为前一时刻的背景噪声信号估计值与经过自适应 滤波处理获得的噪声信号估计值之和。 The method for predicting a receiver background noise signal estimate by the method is: current time The background noise signal estimate is the sum of the background noise signal estimate at the previous moment and the noise signal estimate obtained through the adaptive filtering process.
由上述方案可以看出, 本发明的关键在于: 本发明装置主要包括用 于估计背景噪声的自适应滤波器和噪声估计模块, 通过自适应滤波器和 噪声估计模块估计出背景噪声, 将背景噪声估计值反相位后与语音信号 进行叠加, 然后将包含该背景噪声估计值的语音信号通过耳机播放出 来, 使其中的背景噪声估计值与实际的接收方背景噪声相互抵消, 从而 获得消噪后的语音信号。 It can be seen from the above scheme that the key to the present invention is that the apparatus of the present invention mainly includes an adaptive filter and a noise estimation module for estimating background noise, and the background noise is estimated by the adaptive filter and the noise estimation module, and the background noise is used. After the estimated value is inverted, the voice signal is superimposed, and then the voice signal including the background noise estimate is played out through the earphone, so that the background noise estimate and the actual receiver background noise cancel each other, thereby obtaining the noise cancellation. Voice signal.
因此, 本发明所提供的这种语音通信终端背景噪声的消除装置及方 法, 可以很好地抵消耳机周围的背景噪声, 减少接收方背景噪声对接收 者的干扰, 使接收方在耳机音量不大的情况下也可以清晰地听清发送方 的话音。 附图简要说明 Therefore, the apparatus and method for eliminating background noise of the voice communication terminal provided by the present invention can well cancel the background noise around the earphone, reduce the interference of the receiver background noise to the receiver, and make the receiving party have a small volume in the earphone. In the case of the sender, the voice of the sender can be clearly heard. BRIEF DESCRIPTION OF THE DRAWINGS
图 1为移动通信终端的语音传递过程示意图; 1 is a schematic diagram of a voice transmission process of a mobile communication terminal;
图 2为现有技术移动通信终端中发送方背景噪声的消除装置结构组 成示意图; 2 is a schematic structural diagram of a structure of a device for canceling a background noise of a sender in a mobile communication terminal of the prior art;
图 3为图 2所示的发送方背景噪声消除装置中自适应滤波器的结构 示意图; 3 is a schematic structural diagram of an adaptive filter in a transmitter background noise canceling apparatus shown in FIG. 2;
图 4为本发明移动通信终端中接收方背景噪声的消除装置的一个实 施例的结构组成示意图; . 4 is a schematic structural diagram of an embodiment of a device for canceling a background noise of a receiver in a mobile communication terminal according to the present invention;
图 5为图 4所示的接收方背景噪声消除装置的一个实施例中自适应 滤波器的结构示意图; FIG. 5 is a schematic structural diagram of an adaptive filter in an embodiment of the receiver background noise canceling apparatus shown in FIG. 4; FIG.
图 6为本发明接收方背景噪声的消除装置的一个实施例中耳机和麦 克风的排列方式示意图;
图 7 为本发明用于消除语音通信终端的背景噪声的方法实现流程 图; 6 is a schematic diagram showing an arrangement manner of an earphone and a microphone in an embodiment of a receiving device background noise canceling apparatus according to the present invention; 7 is a flowchart of a method for implementing background noise for eliminating a voice communication terminal according to the present invention;
图 8为本发明固定通信终端中接收方背景噪声的消除装置的一个实 施例的结构组成示意图。 实施本发明的方式 Figure 8 is a block diagram showing the structure of an embodiment of a device for canceling background noise of a receiving side in a fixed communication terminal of the present invention. Mode for carrying out the invention
下面结合附图及具体实施例对本发明再作进一步详细的说明。 The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
本发明应用的语音通信终端中应包括有用于将输入的声音信号转换 为声音进行播放的播放器。 本发明提供的语音通信终端背景噪声的消除 装置主要包括: 声音传感模块, 用于采集语音通信终端播放器播放的声 音和接收方背景噪声, 将采集的声音转换成声音信号并输出; 自适应滤 波器, 用于根据输入的来自声音传感模块的声音信号和来自发送方的语 音信号, 计算所述声音传感模块的声音信号中含有的噪声信号并输出; 噪声估计模块, 用于根据所述自适应滤波器输出的噪声信号预测接收方 背景噪声信号并输出; 加法器模块, 用于将所述噪声估计模块输出的接 收方背景噪声信号与发送方语音信号进行反相位叠加并输入至所述语 音通信终端的播放器。 The voice communication terminal to which the present invention is applied should include a player for converting the input sound signal into sound for playback. The device for eliminating background noise of a voice communication terminal provided by the invention mainly comprises: a sound sensing module, configured to collect sound played by a player of a voice communication terminal and background noise of a receiver, convert the collected sound into a sound signal and output; a filter, configured to calculate, according to the input sound signal from the sound sensing module and the voice signal from the sender, a noise signal contained in the sound signal of the sound sensing module, and output; a noise estimation module, configured to The noise signal output by the adaptive filter predicts the receiver background noise signal and outputs; the adder module is configured to inversely superimpose the receiver background noise signal output by the noise estimation module and the sender voice signal into the a player of the voice communication terminal.
基于同样原理本发明提供的语音通信终端背景噪声的消除方法主要 包括以下步驟: 采集接收方用户接听的包含有发送方语音和接收方背景 噪声的声音信号; 从获得的信号中估计出接收方背景噪声信号; 将估计 得到的接收方背景噪声信号反相位后与语音通信终端收到的发送方语 音信号进行叠加后向接收方用户播放。 Based on the same principle, the method for eliminating background noise of a voice communication terminal provided by the present invention mainly includes the following steps: collecting a sound signal including a sender voice and a receiver background noise received by a receiver user; and estimating a receiver background from the obtained signal. The noise signal is superimposed on the estimated background noise signal of the receiver and superimposed with the sender voice signal received by the voice communication terminal, and then played to the receiver user.
本发明较佳实施例的移动通信终端中消除接收方背景噪声装置的结 构参见图 4所示, 包括: 加法器模块 401、 数 /模(D/A ) 变换模块 402、 耳机 403、 麦克风 405、 模 /数(A/D ) 变换模块 406、 自适应滤波器 407
和噪声估计模块 408 , 其中, 耳机 403和数 /模( D/A ) 变换模块 402为 移动通信终端中已有器件。 Referring to FIG. 4, the structure of the device for canceling the background noise of the receiver in the mobile communication terminal of the preferred embodiment of the present invention includes: an adder module 401, a digital/analog (D/A) conversion module 402, an earphone 403, a microphone 405, Analog/digital (A/D) conversion module 406, adaptive filter 407 And a noise estimation module 408, wherein the earphone 403 and the digital/analog (D/A) conversion module 402 are existing devices in the mobile communication terminal.
加法器模块 401用于将通信终端收到的发送方语音信号 s(n)和接收 方背景噪声信号估计值^ 7)进行反相位叠加; D/A变换模块 402用于将 输入的数字信号转换为模拟信号; 耳机 403用于将输入的模拟电信号转 化为声音信号进行播放, 在本发明中耳机 403播放的实际上是来自发送 方的语音信号和反相位的接收方背景噪声信号叠加后的信号, 这里也可 以采用扬声器代替耳机; 麦克风 405用于接收用户的语音信号和被耳机 输出信号抵消后的背景噪声; A/D变换模块 406用于将模拟信号转换为 数字信号; 自适应滤波器 407用于估计采集到的信号中的噪声信号值; 噪声估计模块 408用于预测背景噪声的估计值。 The adder module 401 is configured to inversely superimpose the sender voice signal s(n) received by the communication terminal and the receiver background noise signal estimate value (7); the D/A conversion module 402 is configured to input the digital signal. Converting to an analog signal; the earphone 403 is configured to convert the input analog electrical signal into a sound signal for playing. In the present invention, the earphone 403 actually plays the voice signal from the sender and the opposite phase of the received background noise signal. After the signal, the speaker can also be used instead of the earphone; the microphone 405 is used for receiving the user's voice signal and the background noise cancelled by the headphone output signal; the A/D conversion module 406 is used to convert the analog signal into a digital signal; Filter 407 is used to estimate the noise signal value in the acquired signal; noise estimation module 408 is used to predict the estimated value of the background noise.
通信终端收到的发送方语音信号 s(n)经过加法器模块 401处理后传 送给 D/A变换模块 402, D/A变换模块 402对收到的信号进行数字信号 到模拟信号的转换, 并将转换后的模拟信号输出给作为播放器的耳机 403, 耳机 403将模拟信号转化成声音信号进行播放。 耳机 403播放出 来的声音信号通过语音传输通道 404传送给接收方用户和作为所述声音 传感模块的麦克风 405 , 同时接收方的背景噪声 V也通过语音传输通道 404传送给接收方用户和麦克风 405。 The sender voice signal s(n) received by the communication terminal is processed by the adder module 401 and then transmitted to the D/A conversion module 402, and the D/A conversion module 402 performs digital signal to analog signal conversion on the received signal, and The converted analog signal is output to the earphone 403 as a player, and the earphone 403 converts the analog signal into a sound signal for playback. The sound signal played by the earphone 403 is transmitted to the receiver user and the microphone 405 as the sound sensing module through the voice transmission channel 404, and the background noise V of the receiver is also transmitted to the receiver user and the microphone 405 through the voice transmission channel 404. .
麦克风 405将接收到的声音信号转化为模拟信号 X送到 A/D变换模 块 406, 信号 X中包含有发送方的语音信号和接收方噪声信号; A/D变 换模块 406对模拟信号进行抽样并转换为数值信号 x(n)送入自适应滤波 器 407; 自适应滤波器 407以语音信号 s(n)作为参考输入进行自适应滤 波, 估计噪声信号的估计值 噪声估计模块 408根据噪声信号的估 计值 预测背景噪声信号的估计值 , 并将背景噪声估计值 送
给加法器模块 401。 这里, A/D变换模块 406不是必须的, 比如: 如果 自适应滤波器 407、 噪声估计模块 408等模块可处理模拟信号, 则不必 设置所述 A/D变换模块 406; 另外, 如果麦克风 405可以直接输出数字 信号, 也不必设置所述 A/D变换模块 406。 The microphone 405 converts the received sound signal into an analog signal X and sends it to the A/D conversion module 406. The signal X includes the sender's voice signal and the receiver noise signal. The A/D conversion module 406 samples the analog signal and The converted value signal x(n) is sent to the adaptive filter 407; the adaptive filter 407 performs adaptive filtering with the speech signal s(n) as a reference input, and the estimated value noise estimation module 408 of the estimated noise signal is based on the noise signal. The estimated value predicts the estimated value of the background noise signal and sends the background noise estimate The adder module 401 is provided. Here, the A/D conversion module 406 is not necessary, for example: if the adaptive filter 407, the noise estimation module 408, and the like can process the analog signal, the A/D conversion module 406 does not have to be set; in addition, if the microphone 405 can The digital signal is directly output, and it is not necessary to set the A/D conversion module 406.
加法器模块 401 将接收方背景噪声信号的估计值 反相位后与发 送方语音信号 s(n)进行叠加,得到信号 s(n) - ν(π) ,并将该信号输出给 D/A 变换模块 402, 再通过耳机 403播放出来。 这样反相位的接收方背景噪 声信号的估计值 - θ)与接收方背景噪声 V在语音传输通道 404中相互抵 消,使传送到接收方用户和麦克风 405的声音主要是发送方的语音信号。 The adder module 401 superimposes the estimated value of the received background noise signal with the transmitted speech signal s(n) to obtain a signal s(n) - ν(π), and outputs the signal to the D/A. The conversion module 402 is played back through the earphone 403. The inverse phase of the received background noise signal estimate - θ) and the receiver background noise V cancel each other in the voice transmission channel 404 such that the sound transmitted to the recipient user and the microphone 405 is primarily the sender's voice signal.
自适应滤波器 407的具体结构参见图 5所示。 经由麦克风接收到的 包含有发送方语音信号 s(n)和背景噪声信号的混合数字信号 x(n)经过自 适应滤波器 407 的滤波器部分, 恢复出发送方语音信号的最佳估计值 ) ,语音信号的最佳估计值 ")与移动终端通过天线接收到的发送方语 音信号 s(n)的延迟信号 s(n-A)相减, 得到所求的误差信号 。 The specific structure of the adaptive filter 407 is shown in FIG. The mixed digital signal x(n) received via the microphone including the sender speech signal s(n) and the background noise signal passes through the filter portion of the adaptive filter 407 to recover the best estimate of the transmitted speech signal) The best estimated value of the speech signal is subtracted from the delayed signal s(nA) of the transmitted speech signal s(n) received by the mobile terminal through the antenna to obtain the obtained error signal.
自适应滤波器 407采用 LMS算法, 其权值1^")由误差信号 = s(n) - s(n-A)调节, 其中, 0≤ ≤ikT- 1 , M是滤波器的阶数。 由于语音 信号和背景噪声信号不相关,调整滤波器的权值 w»使 的均方误差 最小, 就可以得到在最小均方误差准则下的 χ(η)中语音信号 s(n)的最佳 估计值 ) , 同时也就认为 W是背景噪声相消后剩余噪声信号的最佳 估计值。 其中 Δ是语音信号的延迟, 可以根据最小均方误差准则'搜索得 到。 当然, 自适应滤波器 407也可以釆用其它自适应算法和最佳准则。 The adaptive filter 407 employs an LMS algorithm whose weight 1 ^") is adjusted by the error signal = s(n) - s(nA), where 0 ≤ ≤ ikT - 1 , M is the order of the filter. The signal is not correlated with the background noise signal. Adjusting the weight of the filter w » to minimize the mean square error, the best estimate of the speech signal s(n) in χ(η) under the minimum mean square error criterion can be obtained. At the same time, it is considered that W is the best estimate of the residual noise signal after the background noise is cancelled. Where Δ is the delay of the speech signal, which can be searched according to the minimum mean square error criterion. Of course, the adaptive filter 407 can also Use other adaptive algorithms and best practices.
噪声估计模块 408根据噪声信号的最佳估计值 预测当前的背景
噪声估计值。 最简单的预测方法为 v(") = v(" _ l) + ve(")。 其中, v(«)为当 前的背景噪声估计值, _ 1)为前一时刻的背景噪声估计值。 The noise estimation module 408 predicts the current background based on the best estimate of the noise signal Noise estimate. The simplest prediction method is v(") = v(" _ l) + v e (") where v(«) is the current background noise estimate and _ 1) is the background noise estimate from the previous moment. .
为了使噪声抵消的效果更好, 耳机 403和麦克风 405的数量可以设 置为多个, 且耳机和麦克风的数量可以不同。 麦克风的位置是在希望抵 消噪声的区域, 通常希望抵消噪声的区域在接收方是指耳机周围, 但在 其他应用时也有例外, 比如: 睡觉时, 如果仅仅把手机当成一个降低周 围噪声的工具, 该区域就可以比较大。 以一个耳机和三个麦克风为例, 可以采取如图 6所示的分布方式。 其中, 耳机位于中间, 三个麦克风位 于耳机周围成 120度角分布。 In order to make the effect of noise cancellation better, the number of headphones 403 and microphone 405 can be set to be plural, and the number of headphones and microphones can be different. The position of the microphone is in the area where it is desired to cancel the noise. The area where it is usually desired to cancel the noise is around the earphone on the receiving side, but there are exceptions in other applications, such as: When sleeping, if the mobile phone is only used as a tool to reduce the surrounding noise, This area can be larger. Taking one earphone and three microphones as an example, the distribution method shown in Fig. 6 can be adopted. Among them, the earphone is in the middle, and the three microphones are distributed at an angle of 120 degrees around the earphone.
多个麦克风同时接收的信号可以叠加后传送给自适应滤波器, 也可 单独传送给自适应滤波器后由自适应滤波器分别处理, 如果需要叠加, 则.需要在本发明装置中相应的位置增加一个叠加器。 比如: 多个麦克风 的输出信号可以在进行 A/D变换前叠加在一起,则将叠加器设置在麦克 风和 A/D变换模块之间;也可以在进行 A/D变换后叠加在一起,则将叠 加器设置在 A/D变换模块和自适应滤波器之间; 另外, 多个麦克风的输 出信号还可以在进行 A/D 变换后分别送到自适应滤波器来分别进行处 理。 Signals received simultaneously by multiple microphones may be superimposed and transmitted to the adaptive filter, or separately transmitted to the adaptive filter and then processed by the adaptive filter separately. If superimposition is required, the corresponding position in the device of the present invention is required. Add a stacker. For example: the output signals of multiple microphones can be superimposed before A/D conversion, then the adder is set between the microphone and the A/D conversion module; or it can be superimposed after A/D conversion. The adder is disposed between the A/D conversion module and the adaptive filter. In addition, the output signals of the plurality of microphones can also be separately sent to the adaptive filter for processing after performing A/D conversion.
本发明还提供了一种用于接收方语音通信终端的背景噪声消除方 法, 参见图 7所示, 包括以下步驟: The present invention also provides a background noise canceling method for a receiving party voice communication terminal, as shown in Fig. 7, comprising the following steps:
步骤 701 , 釆集将被接收方用户听到的声音, 包括有语音通信终端 的耳机发出的声音和接收方背景噪声, 并将采集的声音转换为声音信号 并进行 A/D变换。 Step 701: Collecting a sound to be heard by the user of the receiving party, including a sound emitted by the earphone of the voice communication terminal and a background noise of the receiving side, and converting the collected sound into a sound signal and performing A/D conversion.
其中, 用于采集声音信号的麦克风可以是一个和多个, 即采集的信 号可以是一路或多路。 当使用多个麦克风采集信号时, 可以将多个麦克
风输出的信号先叠加起来, 再进行 A/D变换并输出; 也可以将多个麦克 风输出的信号先分别进行 A/D变换, 再叠加起来输出; 或者还可以将多 个麦克风输出的信号分别进行 A/D变换, 然后分别输出。 The microphones for collecting sound signals may be one or more, that is, the collected signals may be one or more channels. Multiple microphones can be used when acquiring signals using multiple microphones The signals of the wind output are first superimposed, and then A/D is converted and outputted. The signals output by the plurality of microphones may be respectively A/D-converted and then superimposed and outputted; or the signals output by the plurality of microphones may be separately Perform A/D conversion and output separately.
这里, A/D变换过程也不是必须的, 比如: 如果后面的自适应滤波、 噪声估计等处理可基于模拟信号进行, 则这里不必进行所述 A/D变换; 另外, 如果麦克风可以直接输出数字信号, 也不必进行所述 A/D变换。 Here, the A/D conversion process is also not necessary, for example: if the subsequent adaptive filtering, noise estimation, etc. processing can be performed based on the analog signal, the A/D conversion is not necessary here; in addition, if the microphone can directly output the digital The signal does not have to be subjected to the A/D conversion.
步骤 702, 将发送方语音信号作为参考输入, 对采集到的数字声音 信号进行自适应滤波处理, 估计出其中的噪声信号; 其中, 自适应滤波 器可以采用 LMS算法或采用其他自适应算法和最佳准则。 Step 702: The sender voice signal is used as a reference input, and the collected digital sound signal is adaptively filtered to estimate a noise signal therein. wherein the adaptive filter may adopt an LMS algorithm or adopt another adaptive algorithm and most Good guidelines.
对于多个麦克风输出的信号分别进行 A/D变换再分别输出给自适应 滤波器的情况, 需要对各路信号分别进行自适应滤波处理。 这里以三个 麦克风、 一个耳机为例进行简单说明。 When the signals output from a plurality of microphones are respectively A/D-converted and output to the adaptive filter, it is necessary to perform adaptive filtering processing on each of the signals. Here is a brief description of three microphones and one earphone.
例如, 三个麦克风接收的信号分别经过自适应滤波器在最小均方误 差准则下进行处理, 得到三个噪声信号的估计值 ^φ7)、 ^2(«)和^3 (/7)。 然后计算 ve 0) =max( (77) , ve2 (η) , ve3 (77) )或 ve {n) =sum( vei (n) , ve2 (;7) , v (n) ) , 其中 max为求最大值运算, sum为求和运算。 也就是说, 可以选择自适 应滤波处理后获得的三个估计值中的最大值或将三个估计值叠加作为 自适应滤波结果输出。 由于各路信号的延迟不同, 需要先对各路噪声信 号估计值, 比如 («)、 2 ( )和 e3( )进行同步处理, 再选择或叠加。 For example, the signals received by the three microphones are processed by the adaptive filter under the minimum mean square error criterion to obtain the estimated values of the three noise signals ^φ 7 ), ^ 2 («) and ^3 (/7). Then calculate v e 0) =max( (77) , v e2 (η) , v e3 (77) ) or v e {n) =sum( v e i (n) , v e2 (;7) , v ( n) ) , where max is the maximum operation and sum is the sum operation. That is to say, the maximum of the three estimated values obtained after the adaptive filtering process can be selected or the three estimated values can be superimposed as the adaptive filtering result output. Since the delays of the signals are different, it is necessary to first evaluate the noise signals of each channel, such as («), 2 ( ) and e3 ( ), and then select or superimpose them.
由于人耳对声音的感觉并不是和声音的功率成正比, 而是和声音的 分贝数成正比, 所以, 也可以对^(")的绝对值取对数, 即 log 后以使 log 最小为最优准则。相应地, 对于多路输入的情况, 也可以
对每个 Va 的绝对值取对数, 再求和, 即 (log| ve(n)) , 然后以使 ∑(log ; νβ(«))最小为最优准则。 步骤 703、 根据得到的噪声信号预测实际背景噪声信号的估计值; 最筒单的预测方法为: o) = ( - 1)+ ve(n) . 其中, )为当前的背景噪 声信号估计值, /7-l)为前一时刻的背景噪声信号估计值, 7)为经过 自适应滤波得到的噪声信号的最佳估计值。 Since the human ear's perception of sound is not proportional to the power of the sound, but proportional to the number of decibels of the sound, it is also possible to take the logarithm of the absolute value of ^("), that is, log to minimize the log. Optimal criteria. Correspondingly, for multiple inputs, The absolute value of each Va is taken as a logarithm, and then summed, that is, (log| ve(n)), and then ∑(log ; ν β («)) is minimized as the optimal criterion. Step 703: Predict an estimated value of the actual background noise signal according to the obtained noise signal; the prediction method of the most single unit is: o) = (-1)+ve(n). Where, where is the current estimated value of the background noise signal, /7-l) is the estimated value of the background noise signal at the previous moment, and 7) is the best estimate of the noise signal obtained by adaptive filtering.
步骤 704、 将预测获得的实际背景噪声信号估计值反相位后与发送 方语音信号进行叠加, 并通过耳机输出。 Step 704: The predicted background actual signal noise signal is inversely phase-phased and superimposed with the sender voice signal, and output through the earphone.
步骤 705、 耳机输出的声音与接收方背景噪声在语音传输时进行叠 加, 抵消其中的背景噪声, 接收方用户获得消噪后的发送方语音。 Step 705: The sound outputted by the earphone and the background noise of the receiver are superimposed during the voice transmission to cancel the background noise therein, and the receiver user obtains the noise of the sender after the noise cancellation.
本发明方案同样可以适用于固定的语音通信终端, 其实现时的区别 仅在于: 由于现有的固定通信终端接收方收到的是来自发送方的模拟信 号, 因此需要先将收到的模拟信号转换成数字信号, 再进行噪声估计和 消噪处理。 具体参见图 8所示, 需要在发送方语音信号输入端之前增加 一个 A/D转换模块 800, 用于将输入的模拟信号转换为数字信号。 The solution of the invention can also be applied to a fixed voice communication terminal, and the implementation thereof is only different in that: since the existing fixed communication terminal receiver receives the analog signal from the sender, it is necessary to first convert the received analog signal. A digital signal is then used for noise estimation and noise cancellation. Referring to Figure 8, it is necessary to add an A/D conversion module 800 before the sender's voice signal input terminal for converting the input analog signal into a digital signal.
从上述方案可以看出, 本发明通过自适应滤波处理可以得到经过噪 声相消后的剩余噪声, 再通过噪声预测处理不断叠加, 就可以估计出接 收方背景噪声, 然后用估计得到的接收方背景噪声与实际的接收方背景 噪声进行对消处理, 进而可以减少了背景噪声对接收者的干扰。 It can be seen from the above scheme that the present invention can obtain residual noise after noise cancellation through adaptive filtering processing, and then continuously superimposes by noise prediction processing, and can estimate the background noise of the receiver, and then use the estimated receiver background. The noise is cancelled by the actual receiver background noise, which reduces the interference of the background noise to the receiver.
总之, 以上所述仅为本发明的较佳实施例而已, 并不用以限制本发 明, 凡在本发明的精神和原则之内, 所作的任何修改、 等同替换、 改进 等, 均应包含在本发明的保护范围之内。
In conclusion, the above description is only the preferred embodiment of the present invention, and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., which are included in the spirit and principle of the present invention, should be included in the present invention. Within the scope of protection of the invention.