The content of the invention
It is an object of the invention to provide a kind of linear echo removing method and its device, it is possible to increase linear echo is eliminated
Efficiency.
In order to solve the above technical problems, embodiments of the present invention provide a kind of linear echo removing method, including:
The near end signal of the reference signal of full band and full band is parsed into the reference signal and N number of subband of N number of subband respectively
Near end signal, the N is the integer more than 1;
Reference signal to N number of subband carries out adaptive-filtering, obtains the estimated echo signal of N number of subband;
The near end signal of N number of subband is made into difference with the estimated echo signal of N number of subband and obtains the residual of N number of subband
Difference signal;
Residual signals to N number of subband carry out integrated filter, obtain the residual signals of full band, the residual error of the full band
Signal is the signal after linear echo is eliminated.
Embodiments of the present invention provide the device that a kind of linear echo is eliminated, including:
Analysis filter group, including N number of analysis filter, for the near end signal of the reference signal of full band and full band to be divided
The reference signal of N number of subband and the near end signal of N number of subband are not parsed into, and the N is the integer more than 1;
Sef-adapting filter group, including N number of sef-adapting filter, for the N number of subband exported to the analysis filter
Reference signal carry out adaptive-filtering, obtain the estimated echo signal of N number of subband;
Processing unit, for described N number of son that the near end signal to N number of subband and the sef-adapting filter are exported
The estimated echo signal of band makees the residual signals that difference obtains N number of subband;
Synthesis filter group, including N number of synthesis filter, for described N number of subband for being exported to the processing unit
Residual signals carry out integrated filter, the residual signals of full band are obtained, after the residual signals of the full band are eliminated for linear echo
Signal.
Embodiment of the present invention in terms of existing technologies, first, reference signal and near end signal is passed through respectively to divide
Analyse filter analysis into the reference signal of N number of subband and the near end signal of N number of subband so that disappear in the echo for carrying out signal every time
During except treatment, the near end signal of the reference signal of N number of subband and N number of subband can simultaneously be processed, then, to N number of son
The reference signal of band carries out adaptive-filtering treatment, obtains the N number of subband estimated echo signal after linear echo is eliminated, finally,
The residual signals that difference obtains N number of subband are made with the estimated echo signal of N number of subband to the near end signal of N number of subband,
And the residual signals to N number of subband carry out integrated filter, full band residual signals are obtained, so by the adaptive-filtering of full band
Device coefficient is decomposed in N number of subband, and the sef-adapting filter length of each subband is the 1/N of full strip length, is reduced linear
Amount of calculation during echo cancellor, improves the efficiency of linear echo elimination.
In addition, carrying out adaptive-filtering in the reference signal to N number of subband, the estimated echo letter of N number of subband is obtained
Number afterwards, methods described also includes:Update the coefficient of the sef-adapting filter, the renewal of the coefficient of the sef-adapting filter
Formula is as follows:
Wherein, m is discrete time, and the m is the integer more than or equal to 0, describedFor m moment self adaptation is filtered
The coefficient vector of ripple device, it is describedIt is the coefficient vector of (m+1) moment sef-adapting filter, when the μ (m) is m
The step factor of sef-adapting filter is carved, the e (m) is that, at the m moment, the X reference signal of subband is filtered by self adaptation
The X residual signals of subband obtained after the adaptive-filtering of ripple device, it is describedIt is the X ginseng of subband of m moment
Signal vector is examined, it is describedIt is the X transposed vector of the reference signal of subband of m moment, T represents transposition, the △
It is a constant more than 0, the K (m) is the m positive diagonal square matrix of moment scale factor.
Because subband has the characteristics of bandwidth is small, and signal fluctuation is slow, therefore, believed using the reference signal in subband and near-end
Number estimate that the coefficient ratio of sef-adapting filter for obtaining estimates the step-length for obtaining using the reference signal and near end signal in full band
The factor is accurate.
In addition, in the coefficient for updating the sef-adapting filter, the μ (m) is calculated according to equation below:A, root
The estimation for obtaining near end signal p (m), the m moment X subbands of the m moment X subbands respectively according to below equation is returned
Acoustical signalWith the instantaneous energy R of residual signals e (m) of the m moment X subbandspp(m)、Ree(m), specifically
Formula is as follows:
Rpp(m)=λ Rpp(m-1)+(1-λ)p2(m)
Ree(m)=λ Ree(m-1)+(1-λ)e2(m)
Wherein, λ is first order recursive smoothing factor;
B, according to the Rpp(m)、Ree(m), material calculation factor mu (m), the formula for calculating the μ (m) is:
Wherein, ε is the constant more than 0, and abs () represents the computing that takes absolute value, and max () is represented and taken maximum operation.
Because subband has the characteristics of bandwidth is small, and signal fluctuation is slow, therefore, believed using the reference signal in subband and near-end
Number estimate that the step factor Billy that obtains estimates that the step factor for obtaining is accurate with the reference signal and near end signal in full band.
Specific embodiment
To make the object, technical solutions and advantages of the present invention clearer, below in conjunction with accompanying drawing to each reality of the invention
The mode of applying is explained in detail.However, it will be understood by those skilled in the art that in each implementation method of the invention,
In order that reader more fully understands the application and proposes many ins and outs.But, even if without these ins and outs and base
Many variations and modification in following implementation method, it is also possible to realize the application each claim technical side required for protection
Case.
First embodiment of the invention provides a kind of linear echo removing method, as shown in figure 1, the method includes:
101st, the near end signal of the reference signal of full band and full band is parsed into the reference signal of N number of subband and N number of respectively
The near end signal of subband.
The N is the integer more than 1.
The reference signal is the useful voice signal that transmitter sends, and the near end signal is near-end speech, near-end
The real echo signal that noise and the reference signal are produced is overlapped the signal of composition, and the near-end speech is microphone
The voice signal of the speaker of reception, the ambient noise signal that the near-end noise is received for transmitter, the reference signal
The real echo signal for producing is that the useful voice signal that the transmitter sends is reflected back microphone by loudspeaker
Signal.
As shown in Fig. 2 Fig. 2 eliminates structural representation for the linear echo that first embodiment of the invention is provided.In figure, x
N () represents reference signal, b (n) represents near-end noise signal, and d (n) represents reference signal x (n) by real echo pathThe real echo signal for obtaining, s (n) represents near-end voice signals.P (n) represents near end signal.Near-end noise signal b
The mutual statistical independence of (n), real echo signal d (n) and near-end voice signals s (n), and its Fourier spectrum estimation in short-term
Average is 0.
201 is the first analysis filter group, and N group analysis wave filters are had in first analysis filter group, and N is more than 1
Integer, for being the reference signal of N number of subband by the analysis of reference signal x (n) of full band, as shown in Fig. 2 reference signal x (n)
The reference signal x of N number of subband is obtained by the first analysis filter group0(n)、x1(n)、...、xN-1(n), the ginseng of N number of subband
Examining signal can be expressed as xjN (), j values are the integer between 0 to N-1.First analysis filter is by described with reference to letter
Number x (n) analysis is prior art for the method for the reference signal of N number of subband, and specific embodiment may be referred to prior art,
Therefore not to repeat here for the present invention;202 is the second analysis filter group, and the filtering of N group analysis is had in second analysis filter group
Device, for being the near end signal of N number of subband by near end signal p (n) analysis of full band, as shown in Fig. 2 near end signal p (n) passes through
Analysis filter group obtains the near end signal p of N number of subband0(n)、p1(n)、...、pN-1N (), the near end signal of N number of subband can
To be expressed as pjN (), j values are the integer between 0 to N-1.Second analysis filter divides near end signal p (n)
Analyse as the method for the near end signal of N number of subband is prior art, specific embodiment may be referred to prior art, and the present invention exists
This is not repeated.
First analysis filter group exports the reference signal of N number of subband, the N number of analysis filtering in the first analysis filter group
Device is corresponded with the reference signal of N number of subband, and the second analysis filter group exports the near end signal of N number of subband, the second analysis
N number of analysis filter in wave filter group is corresponded with the near end signal of N number of subband.
102nd, the reference signal to N number of subband carries out adaptive-filtering, obtains the estimated echo signal of N number of subband.
As shown in Fig. 2 in Fig. 2 203 be sef-adapting filter group, have N number of adaptive-filtering in the sef-adapting filter group
DeviceThe value of j is the integer between 0 to N-1, and the reference signal of N number of sef-adapting filter and N number of subband is one by one
Correspondence, each sef-adapting filter is used for a filtering for subband.The N that sef-adapting filter is exported to the first analysis filter group
The reference signal of individual subband carries out adaptive-filtering for prior art, and specific embodiment may be referred to prior art, this hair
It is bright to will not be repeated here.As shown in Fig. 2 carry out adaptive-filtering to the reference signal of N number of subband, the N number of subband for obtaining is estimated
Counting echo signal isThe estimated echo signal of N number of subband can be expressed as
J values are the integer between 0 to N-1.The estimated echo signal of each subbandIt is the reference signal x of each subbandjN () passes through
Cross its corresponding Subband adaptive filtersOutput.
103rd, the estimated echo signal of the near end signal of N number of subband and N number of subband is made into the residual error letter that difference obtains N number of subband
Number.
Residual signals subtract remaining signal after estimated echo for signal that near-end is received.In Fig. 2, e0(n)、e1
(n)、...、eN-1N () is residual signals, the residual signals can be expressed as ejN (), j values are the integer between 0 to N-1.Should
The residual signals e of N number of subbandjN () is the near end signal p of corresponding N number of subbandjThe estimated echo of (n) and corresponding N number of subband
SignalMake what difference was obtained.
104th, the residual signals to N number of subband carry out integrated filter, obtain the residual signals of full band.
It is full the signal after linear echo is eliminated with residual signals, the full band residual signals are that near end signal passes through linear returning
Voice signal after sound elimination.As shown in Fig. 2 204 being synthesis filter group in Fig. 2, synthesis filter group is residual to N number of subband
Difference signal ejN () obtains full band residual signals e (n) after carrying out integrated filter.The synthesis filter group is to the residual of N number of subband
Difference signal ejN method that () carries out integrated filter is prior art, and specific embodiment may be referred to prior art, the present invention
Therefore not to repeat here.
Embodiment of the present invention in terms of existing technologies, first, reference signal and near end signal is passed through respectively to divide
Analyse filter analysis into the reference signal of N number of subband and the near end signal of N number of subband so that disappear in the echo for carrying out signal every time
During except treatment, the near end signal of the reference signal of N number of subband and N number of subband can simultaneously be processed, then, to N number of son
The reference signal of band carries out adaptive-filtering treatment, obtains the N number of subband estimated echo signal after linear echo is eliminated, finally,
The residual signals that difference obtains N number of subband are made with the estimated echo signal of N number of subband to the near end signal of N number of subband,
And the residual signals to N number of subband carry out integrated filter, full band residual signals are obtained, so by the adaptive-filtering of full band
Device coefficient is decomposed in N number of subband, and the sef-adapting filter length of each subband is the 1/N of full strip length, is reduced linear
Amount of calculation during echo cancellor, improves the efficiency of linear echo elimination.
Second embodiment of the invention provides another linear echo removing method, second embodiment and the first embodiment party
Formula is roughly the same, as shown in figure 3, main distinction part is:Self adaptation filter is carried out in the reference signal to N number of subband
Ripple, obtains after the estimated echo signal of N number of subband, first updates the coefficient of sef-adapting filter, then perform first embodiment
In step 103 and 104.The formula for updating the coefficient of sef-adapting filter is as follows:
Wherein, m is discrete time, and m is the integer more than or equal to 0,It is the coefficient of m moment sef-adapting filters
Vector,It is the coefficient vector of (m+1) moment sef-adapting filter, μ (m) is the step of m moment sef-adapting filters
The factor long, e (m) be at the m moment, the X reference signal of subband by the X adaptive-filtering of sef-adapting filter it
The X residual signals of subband for obtaining afterwards,It is the X reference signal vector of subband of m moment,It is m
The X transposed vector of the reference signal of subband of moment, Δ be one more than 0 constant, K (m) be m moment scale factor just
Diagonal square matrix, calculates the diagonal element k of K (m)iM the formula of () is:
Wherein, α is the sparse factor relevant with the sparse degree of echo path, in the range from (- 1,1),wjM () is the adaptive filter coefficient at m moment, j is from 0 to LW-
1 integer,It is expressed as the adaptive filter coefficient w that the m moment estimatesj
The transposition of the matrix of (m) composition, LwIt is sef-adapting filter length.By using signal fluctuation in subband it is slow the characteristics of, in son
Calculated in band and update sef-adapting filter, the convergence and stability of effective control sef-adapting filter.
Particularly, before the coefficient of sef-adapting filter is updated, the linear echo removing method also includes:
μ (m) is calculated, μ (m) is calculated and is comprised the following steps:
A, near end signal p (m) according to m moment X subbands, the estimated echo signal of m moment X subbandsWith
Residual signals e (m) of m moment X subbands obtain near end signal p (m) of m moment X subbands, m moment X respectively
The estimated echo signal of bandWith the instantaneous energy R of residual signals e (m) of m moment X subbandspp(m)、Ree
M (), specific formula is as follows:
Rpp(m)=λ Rpp(m-1)+(1-λ)p2(m)
Ree(m)=λ Ree(m-1)+(1-λ)e2(m)
Wherein, λ is first order recursive smoothing factor;
B, according to Rpp(m)、Ree(m), material calculation factor mu (m), calculate μ (m) formula be:
Wherein, ε is 0 value.
Specifically, the method and step for calculating adaptive filter coefficient are as follows:
Assuming that calculating the X coefficient of the sef-adapting filter of subband of the n-th moment.First, according to the n-th moment reference signal
VectorThe echo signal vector estimated with the n-th moment sef-adapting filterCalculate the n-th moment linear estimated echo
SignalComputing formula is:Then, obtained according to the n-th moment near end signal p (n) and the n-th moment
Linear Estimation echo signalTo calculate residual signals e (n), computing formula is:Then, according to n-th
The Linear Estimation echo signal that near end signal p (n) at moment, the n-th moment obtainWith residual signals e (n) at the n-th moment,
To estimate the instantaneous energy of above-mentioned three kinds of signals, the formula for calculating the instantaneous energy of near end signal is:Rpp(n)=λ Rpp(n-1)+
(1-λ)p2(n);The formula of instantaneous energy for calculating Linear Estimation echo signal is:Calculate residual
The formula of the instantaneous energy of difference signal is:Ree(n)=λ Ree(n-1)+(1-λ)e2(n).In above three formula, λ is single order
Recurrence smoothing factor, general value is 0.9.Then, the instantaneous energy R according near end signalpp(n), Linear Estimation echo signal
Instantaneous energyAnd the instantaneous energy R of residual signalseeN () calculates step factor μ (n) at the n-th moment, calculates μ (n)
Formula be:Wherein abs () is modulo operation, max ()
To take maximum operation, ε be one it is less for 0 value, ensure that denominator is not 0.Again, according to the n-th moment self adaptation
The echo path vector that wave filter is estimatedTo calculate scale factor square formation K (n) at the n-th moment, the formula of K (n) is calculated
For:
Wherein, α is the sparse factor relevant with the sparse degree of echo path, in the range from (- 1,1),wjN () is the adaptive filter coefficient at the n-th moment, j be from 0 to
LW- 1 integer, T is transposition, LwIt is sef-adapting filter length.Finally obtain the adaptive filter coefficient after updating Wherein Δ is a less value, generally 10-3。
Finally, reference signal can be updatedWith near end signal p (n), the self adaptation filter at (n+1) moment is then calculated
The coefficient of ripple device.
Because subband has the characteristics of bandwidth is small, and signal fluctuation is slow, therefore, using reference signal in subband and near end signal
Step factor is carried out to estimate that the step factor for obtaining can be more accurate.
Especially, embodiments of the present invention provide a kind of DFT (discrete Fourier transform, Discrete Fourier
Transform) the quick implementation of wave filter group, for realizing analysis filter group and synthesis filter group.Due to first
As being achieved in that of analysis filter group and the second analysis filter group, hereafter for convenience of description, filtered with analysis
Ripple device group represents the first analysis filter group and the second analysis filter group.
In actual applications, analysis filter group is in the form of the modulated filter group of multinomial structure.The multinomial structure
Modulated filter group the use of length is LPFIR (Finite Impulse Response, there is limit for length's impulse response)
Imitative tenth of the twelve Earthly Branches ptototype filter h (n), by after complex-exponential-modulation, obtaining N number of Subband Analysis Filter, N number of Subband Analysis Filter
H can be expressed asKZ (), k values are 0 to N-1 integer.Complex-exponential-modulation mode is prior art, be will not be repeated here.
In the description of the quick implementation of following DFT wave filter groups, T is modulation matrix, and for DFT wave filter groups, T represents discrete
Fourier transformation;For cosine modulated filters group, T represents discrete cosine transform.L1To extract matrix, L2It is a sequence square
Battle array.
For the analysis filter group with N number of subband, the multinomial I types of wave filter of its k-th subband can be expressed as:
Wherein Hk|nZ () is HkMultinomial n-th component of I types of (z), D for extract or interpolation number (used here as extract and insert
The consistent wave filter group of value).
For reference signal X (z), its multinomial II type can be decomposed into:
Wherein, XnZ () is multinomial n-th component of II types of X (z).
The vector form that reference signal and analysis filter group can be written as:
So, analysis filter group is output as:
Can be expressed as:Assuming that LpSimultaneously
It is D and the multiple of subband number N, then the modulation sequence of k-th sub-filter isThe
The coefficient of the wave filter after the modulation of k sub-filter isTherefore,
Wherein IDIt is D × D unit matrix, pi, i=0,1 ..., Lp- 1 is ptototype filter coefficient.
In element with N as cycle, order
It is the complex-exponential-modulation vector in a cycle N.
Final modulation matrix is:
Then the Multi-Nominal Matrix of analysis filter group can be expressed as:
H(z)=T·L2·P·L1(z)
Then analysis filter group is output as:
The perfect reconstruction filter bank of analysis filter group can be:
F (z) H (z)=Δ (z), Δ (z) is pure time delay,
Perfect reconstruction filter bank and ptototype filter according to analysis filter group are paraunitary filters, can obtain comprehensive filter
The Multi-Nominal Matrix of ripple device group is:
F (z)=Δ (z) HH(z-1)=Δ (z) L1 T(z-1)·P·L2 T·TH
Subscript H represents conjugate transposition, for Δ (z) L1 T(z-1) item, order
WhereinIt is Lp×LpAnti- unit matrix:
For the ease of realizing, by reconstruction signalIt is divided into two parts, adds an intermediate variable V
Z (), then has
Wherein IDWith 0DThe respectively null matrix of the unit matrix of D × D and D × D.
Then synthesis filter group is output as:
That is last N number of element of V (z).
Example, a kind of Structures of Fast Realizing schematic diagram of analysis filter group that Fig. 4 is provided for embodiment of the present invention,
A kind of Structures of Fast Realizing schematic diagram of synthesis filter group that Fig. 5 is provided for embodiment of the present invention.DFT wave filter groups it is fast
Fast implementation is not only limited to this, and the embodiment of the present invention is merely illustrative, and those skilled in the art is without creativeness
Work, any implementation expected all should be comprising within the scope of the present invention.
Third embodiment of the invention provides a kind of linear echo canceling device 60, as shown in fig. 6, the linear echo is eliminated
Device 60 includes:
Analysis filter group 601, including N number of analysis filter, for the near-end of the reference signal of full band and full band to be believed
Number the reference signal of N number of subband and the near end signal of N number of subband are parsed into respectively, the N is the integer more than 1;
Sef-adapting filter group 602, including N number of sef-adapting filter, for the N number of son exported to the analysis filter
The reference signal of band carries out adaptive-filtering, obtains the estimated echo signal of N number of subband.
Processing unit 603, for the N that the near end signal to N number of subband and the sef-adapting filter are exported
The estimated echo signal of individual subband makees the residual signals that difference obtains N number of subband.
Synthesis filter group 604, including N number of synthesis filter, for the described N number of subband exported to the processing unit
Residual signals carry out integrated filter, the residual signals of full band are obtained, after the residual signals of the full band are eliminated for linear echo
Signal.
In terms of existing technologies, analysis filter group distinguishes reference signal and near end signal to embodiment of the present invention
The reference signal of N number of subband and the near end signal of N number of subband are parsed into by analysis filter so that carrying out signal every time
During echo cancellation process, the near end signal of the reference signal of N number of subband and N number of subband can simultaneously be processed, self adaptation
Wave filter group carries out adaptive-filtering treatment to the reference signal of N number of subband, obtains the N number of subband after linear echo is eliminated and estimates
Echo signal, processing unit makees difference and obtains N to the near end signal of N number of subband with the estimated echo signal of N number of subband
The residual signals of individual subband, synthesis filter group carries out integrated filter to the residual signals of N number of subband, obtains full band residual error
Signal, during the adaptive filter coefficient of full band so decomposed into N number of subband, the sef-adapting filter length of each subband
It is the 1/N of full strip length, reduces amount of calculation when linear echo is eliminated, improves the efficiency of linear echo elimination.
Four embodiment of the invention provides another linear echo canceling device, the 4th implementation method and the 3rd embodiment party
Formula is roughly the same, and main distinction part is:Each sef-adapting filter in the sef-adapting filter group also includes:Update
Unit 6021, the coefficient for updating the sef-adapting filter before integrated filter calculates new sef-adapting filter
The formula of coefficient is as follows:
Wherein, m is discrete time, and the m is the integer more than or equal to 1, describedIt is m moment adaptive-filterings
The coefficient vector of device, it is describedIt is the coefficient vector of (m+1) moment sef-adapting filter, the μ (m) is the m moment
The step factor of sef-adapting filter, the e (m) is that, at the m moment, the X reference signal of subband is by the X self adaptation
The X residual signals of subband obtained after the adaptive-filtering of wave filter, it is describedIt is the X subband of m moment
Reference signal vector, the Δ is a constant more than 0, and the K (m) is the m positive diagonal square matrix of moment scale factor.
Fifth embodiment of the invention provides another linear echo canceling device, the 5th implementation method and the 4th embodiment party
Formula is roughly the same, and main distinction part is:As shown in fig. 7, each sef-adapting filter in the sef-adapting filter group
Also include:
Diagonal components computing unit 6022, for calculating the K (m).
Adaptive step computing unit 6023, for calculating the μ (m).
The formula for calculating the K (m) is:
Wherein, the α is the sparse factor relevant with the sparse degree of echo path, described in the range from (- 1,1)wjM () is the adaptive filter coefficient at m moment, j is from 0 to LW-
1 integer, it is describedIt is expressed as the sef-adapting filter that the m moment estimates
Coefficient vector, the LwIt is sef-adapting filter length.By using signal fluctuation in subband it is slow the characteristics of, calculate in a sub-band
And update the μ (m) of sef-adapting filter, the convergence and stability of effective control sef-adapting filter.
As shown in figure 8, adaptive step computing unit 6023 includes following subelement:Instantaneous energy computation subunit
60231, near end signal p (m) according to m moment subbands, estimated echo signalObtained respectively with residual signals e (m)
Obtain near end signal p (m), the estimated echo signalWith the instantaneous energy R of residual signals e (m)pp(m)、ReeM (), specific formula is as follows:
Rpp(m)=λ Rpp(m-1)+(1-λ)p2(m)
Ree(m)=λ Ree(m-1)+(1-λ)e2(m)
Wherein, λ is first order recursive smoothing factor.
Step factor computation subunit 60232, for according to the Rpp(m)、Ree(m), material calculation factor mu
M (), the formula for calculating the μ (m) is:
Wherein, ε is the constant more than 0, and abs () represents the computing that takes absolute value;Max () is represented and is taken maximum operation.
Because subband has the characteristics of bandwidth is small, and signal fluctuation is slow, therefore, using reference signal in subband and near end signal
Step factor is carried out to estimate that the step factor for obtaining can be more accurate.
It is noted that each module involved in present embodiment is logic module, in actual applications, one
Individual logic unit can be a part for a physical location, or a physical location, can also be with multiple physics lists
The combination of unit is realized.The operation principle of each physical location may be referred to the narration in embodiment of the method, and the present invention is herein no longer
Repeat.Additionally, in order to protrude innovative part of the invention, not by the skill proposed by the invention with solution in present embodiment
The less close unit of art issue concerns is introduced, but this is not intended that in present embodiment do not exist other units.
It will be understood by those skilled in the art that the respective embodiments described above are to realize specific embodiment of the invention,
And in actual applications, can to it, various changes can be made in the form and details, without departing from the spirit and scope of the present invention.