Noise reduction method and device, terminal equipment and storage medium
By obtaining the target noise frequency and generating the target estimation coefficient, and using the real and imaginary values to perform product operations, the problem of large amount of calculation in the prior art is solved, and the operating speed and noise reduction effect of the active noise reduction system are improved.
Patent Information
- Application Number
- CN202310641218.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-05-31
- Publication Date
- 2024-12-03
AI Technical Summary
Among the existing active noise reduction technologies, the operation volume based on the filter x minimum mean square algorithm is large, resulting in slow operation of the active noise reduction system and poor noise reduction effect, which affects the user experience.
By obtaining the target noise frequency, generating the target estimation coefficient and the original filtered signal, using the real and imaginary values in the target estimation coefficient for product calculation, converting the convolution calculation of the reference signal and the secondary channel estimation, reducing the calculation amount and increasing the The operating speed of the active noise reduction system.
It improves the operating speed and noise reduction effect of the active noise reduction system, and improves the user experience.
Smart Images

Figure CN119068858A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to the technical field of active noise reduction, and in particular to a noise reduction method, apparatus, terminal device and storage medium. Background Art
[0002] Active noise reduction technology can achieve noise reduction effect in a specified area by emitting a secondary sound source with equal amplitude and opposite phase to the primary noise source to offset and attenuate the noise.
[0003] In the related technology, it is mainly implemented based on the filtered-x least mean square (FxLMS) algorithm. This method requires the use of a longer secondary path estimation to participate in the signal convolution calculation and filter coefficient update. It has a large amount of calculation and requires high chip computing power, which reduces the operating speed of the active noise reduction system, resulting in poor noise reduction effect and affecting user experience. Summary of the invention
[0004] The purpose of the present disclosure is to provide a noise reduction method, apparatus, terminal device and storage medium, obtain a target estimation coefficient, determine the target estimation coefficient and the original filtered signal according to the target noise frequency, and use the original filtered signal and the target estimation coefficient including the real value and the imaginary value to obtain the target filtered signal, select the real value and the imaginary value of the secondary path estimation frequency domain coefficient at the target noise frequency as the secondary path model coefficient, and participate in the modulation of the reference signal, that is, the original filtered signal. This method can convert the convolution calculation of the reference signal and the secondary channel estimation into a simple operation between the real value and the imaginary value of the target estimation coefficient corresponding to the reference signal and the target noise frequency, such as a product operation, which reduces the amount of calculation and improves the operating speed of the active noise reduction system, thereby improving the noise reduction effect.
[0005] According to a first aspect of an embodiment of the present disclosure, a noise reduction method is provided, including:
[0006] Obtaining a target estimation coefficient, wherein the target estimation coefficient is obtained by a target noise frequency, wherein the target noise frequency is a frequency corresponding to the target noise, and the target estimation coefficient includes a real part value and an imaginary part value;
[0007] According to the target noise frequency, generating an original filtered signal having a frequency equal to the target noise frequency;
[0008] A target filtering signal is obtained according to the original filtering signal and the real and imaginary values in the target estimation coefficients. The target filtering signal is used to control the loudspeaker to output a filtered sound signal to reduce the target noise.
[0009] Optionally, before obtaining the target estimation coefficient, the method further includes:
[0010] Obtaining an original estimation coefficient set, wherein the original estimation coefficient set is obtained through secondary path modeling, and the original estimation coefficient set includes estimation coefficients corresponding to multiple noise frequencies;
[0011] Performing data transformation on the estimation coefficient corresponding to each noise frequency in the original estimation coefficient set to obtain a target estimation coefficient set, wherein each estimation coefficient in the target estimation coefficient set includes a real part value and an imaginary part value;
[0012] The step of determining a target estimation coefficient according to the target noise frequency includes:
[0013] Obtain the estimation coefficient corresponding to the target noise frequency in the target estimation coefficient set to obtain the target estimation coefficient.
[0014] Optionally, the original filtered signal includes a sinusoidal reference signal and a phase-shifted signal;
[0015] The step of generating an original filtered signal having a frequency equal to the target noise frequency according to the target noise frequency includes:
[0016] According to the target noise frequency, generating the sinusoidal reference signal having a frequency equal to the target noise frequency;
[0017] The sinusoidal reference signal is phase-shifted to obtain the phase-shifted signal.
[0018] The step of obtaining a target filtered signal according to the original filtered signal and the real value and the imaginary value in the target estimated coefficient comprises:
[0019] Obtaining a reference filtered signal according to the original filtered signal and the real and imaginary values in the target estimated coefficients;
[0020] Obtaining a target weight coefficient according to the reference filter signal, the original error signal and the original weight coefficient, wherein the original weight coefficient is a current weight coefficient of the first adaptive filter model, and the original error signal is a residual noise signal corresponding to the current residual noise detected by the error microphone;
[0021] The target filtered signal is obtained according to the original filtered signal and the target weight coefficient.
[0022] Optionally, the original filtered signal includes a sinusoidal reference signal and a phase-shifted signal, and the reference filtered signal includes a first reference sub-signal and a second reference sub-signal;
[0023] The step of obtaining a reference filtered signal according to the original filtered signal and the real value and the imaginary value in the target estimated coefficient comprises:
[0024] Multiplying the real part value in the target estimation coefficient by the sinusoidal reference signal in the original filtered signal to obtain the first reference sub-signal;
[0025] The imaginary part value in the target estimation coefficient is multiplied by the phase shift signal in the original filtered signal to obtain the second reference sub-signal.
[0026] Optionally, the original weight coefficient includes a first original weight sub-coefficient, and the target weight coefficient includes a first target weight sub-coefficient;
[0027] The step of obtaining a target weight coefficient according to the reference filtered signal, the original error signal and the original weight coefficient comprises:
[0028] updating the first original weight sub-coefficient according to the first reference sub-signal and the original error signal to obtain the first target weight sub-coefficient;
[0029] The step of obtaining the target filtered signal according to the original filtered signal and the target weight coefficient comprises:
[0030] Obtaining a first filtered signal according to the sinusoidal reference signal and the first target weight sub-coefficient;
[0031] The target filtered signal is obtained according to the first filtered signal.
[0032] Optionally, the original weight coefficient further includes a second original weight sub-coefficient, and the target weight coefficient further includes a second target weight sub-coefficient;
[0033] The step of obtaining a target weight coefficient according to the reference filtered signal, the original error signal and the original weight coefficient comprises:
[0034] updating the second original weight sub-coefficient according to the second reference sub-signal and the original error signal to obtain the second target weight sub-coefficient;
[0035] The step of obtaining the target filtered signal according to the original filtered signal and the target weight coefficient comprises:
[0036] Obtaining a second filtered signal according to the phase shift signal and the second target weight sub-coefficient;
[0037] The target filtered signal is obtained according to the first filtered signal and the second filtered signal.
[0038] Optionally, the estimated coefficient corresponding to any noise frequency in the original estimated coefficient set is obtained by the following steps:
[0039] Obtaining a modeled noise signal corresponding to any noise frequency;
[0040] Inputting the modeled noise signal into a second adaptive filtering model to generate a modeled filtering signal;
[0041] synthesizing the modeling noise signal and the modeling filter signal to obtain a modeling error signal;
[0042] Optimizing the parameters of the second adaptive filtering model according to the modeling error signal, and returning to the step of: inputting the modeling noise signal into the second adaptive filtering model to generate a modeling filtering signal until the modeling error signal meets a preset condition, thereby obtaining a target adaptive filtering model;
[0043] The current estimation coefficient of the target adaptive filtering model is determined as the estimation coefficient corresponding to any one of the noise frequencies.
[0044] According to a second aspect of an embodiment of the present disclosure, there is provided a noise reduction device, comprising:
[0045] processor;
[0046] a memory for storing processor-executable instructions;
[0047] The processor is configured to execute the steps of the noise reduction method provided in the first aspect of the present disclosure.
[0048] According to a third aspect of an embodiment of the present disclosure, a computer-readable storage medium is provided, on which a computer program is stored. When the program is executed by a processor, the steps of the noise reduction method provided in the first aspect of the present disclosure are implemented.
[0049] According to a fourth aspect of an embodiment of the present disclosure, a terminal device is provided, comprising a speaker, an error microphone, a host and the noise reduction device provided in the second aspect of the present disclosure, wherein the noise reduction device is communicatively connected to the speaker, the error microphone and the host respectively.
[0050] Through the above technical scheme, the target estimation coefficient is obtained, and the target estimation coefficient includes a real value and an imaginary value. Then, according to the target noise frequency, an original filtering signal with a frequency of the target noise frequency is generated, and according to the original filtering signal and the real value and the imaginary value in the target estimation coefficient, the target filtering signal is obtained. Finally, according to the target filtering signal, the target filtering signal is used to control the loudspeaker to output the filtered sound signal to reduce the target noise. The real value and the imaginary value of the secondary path estimation frequency domain coefficient at the target noise frequency are selected as the secondary path model coefficients to participate in the modulation of the reference signal, that is, the original filtering signal. This method can convert the convolution calculation of the reference signal and the secondary channel estimation into a simple operation between the real value and the imaginary value of the target estimation coefficient corresponding to the reference signal and the target noise frequency, such as a product operation, which reduces the amount of calculation and improves the running speed of the active noise reduction system, thereby improving the noise reduction effect.
[0051] Other features and advantages of the present disclosure will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0052] The accompanying drawings are used to provide a further understanding of the present disclosure and constitute a part of the specification. Together with the following specific embodiments, they are used to explain the present disclosure but do not constitute a limitation of the present disclosure. In the accompanying drawings:
[0053] Figure 1 The diagram is a schematic diagram of a terminal device according to an exemplary embodiment.
[0054] Figure 2 The figure is a flow chart of a noise reduction method according to an exemplary embodiment.
[0055] Figure 3 FIG. 1 is a schematic diagram of multiple secondary paths according to an exemplary embodiment.
[0056] Figure 4 It is a schematic diagram showing target estimation coefficients corresponding to different frequencies according to an exemplary embodiment.
[0057] Figure 5 The figure is a flow chart showing a method for obtaining a target filtering signal according to an exemplary embodiment.
[0058] Figure 6 It is a flowchart of a noise reduction method according to an exemplary embodiment.
[0059] Figure 7 The present invention is a flowchart showing a method for determining an estimation coefficient corresponding to any noise frequency according to an exemplary embodiment.
[0060] Figure 8It is an overall flow chart of a noise reduction method according to an exemplary embodiment.
[0061] Fig. 9 It is a block diagram of an electronic device according to an exemplary embodiment. DETAILED DESCRIPTION
[0062] The specific implementation of the present disclosure is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described herein is only used to illustrate and explain the present disclosure, and is not used to limit the present disclosure.
[0063] Before introducing a noise reduction method provided by an embodiment of the present disclosure, a terminal device provided by an embodiment of the present disclosure is first introduced. The terminal device may include a speaker, an error microphone, a host, and a noise reduction device. The noise reduction device is respectively connected to the speaker, the error microphone, and the host for communication. Optionally, the terminal device may be a vehicle, a drone, a ship, and other types of equipment. Optionally, Figure 1 is a schematic diagram of a terminal device according to an exemplary embodiment, taking the terminal device as a vehicle as an example. Figure 1As shown, for example, the noise reduction method can be applied to a vehicle, and the noise of the engine 105 of the vehicle in the vehicle can be reduced. Among them, the terminal device may include the engine 105 of the vehicle, the vehicle host 103, the speaker 101, the error microphone 102 and the noise reduction controller 104, wherein the noise reduction controller 104 can be respectively connected to the speaker 101, the error microphone 102 and the vehicle host 103. For example, the noise reduction controller 104 can be connected to the vehicle host 103 through CAN (Controller Area Network). When the engine 105 is working, it will generate noise, thereby affecting the car experience of the user in the car. The speed of the engine 105 can be obtained through the vehicle host 103, and the target noise frequency of the target noise generated by the engine can be determined according to the speed of the engine 105. The vehicle host 103 then sends the target noise frequency to the noise reduction controller 104, and the noise reduction controller 104 can determine the target filtering signal according to the acquired target noise frequency. The target filter signal is sent to the speaker 101 so that the speaker 101 outputs a filter sound signal according to the target filter signal to offset and attenuate the target noise to achieve the effect of noise reduction. The residual noise after noise reduction can also be obtained through the error microphone 102, and the residual noise is transmitted to the noise reduction controller 104 through the error microphone 102, so that when the noise reduction controller 104 generates the target filter signal next time, it can simultaneously generate a more accurate target filter signal based on the acquired new target noise frequency and the residual noise, so as to obtain a better noise reduction effect. Optionally, there can be multiple speakers and error microphones, so that the target positions where the multiple error microphones are located can be noise-reduced by multiple speakers to reduce the overall noise in the vehicle.
[0064] Figure 2 is a flowchart of a noise reduction method according to an exemplary embodiment. Figure 3 is a schematic diagram of multiple secondary paths according to an exemplary embodiment, Figure 4 is a schematic diagram showing target estimation coefficients corresponding to different frequencies according to an exemplary embodiment. Figures 2 to 4 As shown, it can be applied to a noise reduction device, which can be a noise reduction controller. The method may include the following steps:
[0065] In step S201, a target estimation coefficient is obtained. The target estimation coefficient is obtained through a target noise frequency. The target noise frequency is a frequency corresponding to the target noise. The target estimation coefficient includes a real part value and an imaginary part value.
[0066] In this embodiment, the target estimation coefficient corresponding to the target noise frequency can be obtained from a predetermined target estimation coefficient set, and the target estimation coefficient set is obtained by data transformation of the original estimation coefficient set obtained in advance through secondary path modeling, and the original estimation coefficient set includes estimation coefficients corresponding to multiple noise frequencies, and each noise frequency can correspond to estimation coefficients of multiple secondary paths, and the data transformation method can be Fourier transform. Each estimation coefficient in the transformed original target estimation set is an imaginary number, and each estimation coefficient includes a real value and an imaginary value. The target estimation coefficient obtained thereby also includes a real value and an imaginary value, wherein the real value is the value corresponding to the real part of the target estimation coefficient, and the imaginary value is the value corresponding to the imaginary value of the target estimation coefficient. Among them, the target estimation coefficient is the estimation coefficient corresponding to the target secondary path. The target noise can be the noise emitted by the target noise source, for example, the target noise source can be the engine, and the target noise is the noise generated by the engine. For the engine of the vehicle, the target noise frequency corresponding to the target noise can be determined by obtaining the vehicle speed. The target noise can also be directly measured, and the target noise is analyzed to obtain the corresponding target noise frequency.
[0067] In step S202, an original filtered signal having a frequency equal to the target noise frequency is generated according to the target noise frequency.
[0068] In this implementation, according to the target noise frequency, an original filtering signal having the same frequency as the target noise frequency may be generated by a sine wave generator.
[0069] In step S203, a target filtering signal is obtained according to the original filtering signal and the real and imaginary values in the target estimation coefficients. The target filtering signal is used to control the loudspeaker to output a filtered sound signal to reduce the target noise.
[0070] In this embodiment, since the target estimation coefficient is the estimation coefficient corresponding to the target secondary path, and the target estimation coefficient is an imaginary number, including a real value and an imaginary value, the weight coefficient of the adaptive filtering model can be adjusted based on the product between the original filtered signal and the target estimation coefficient, thereby obtaining the target filtered signal, and the convolution calculation of the reference signal and the secondary channel estimation is converted into a simple operation between the real value and the imaginary value of the target estimation coefficient corresponding to the reference signal and the target noise frequency, such as a product operation, which reduces the amount of calculation and improves the generation rate of the target filtered signal.
[0071] Optionally, after obtaining the target filter signal, the speaker can be controlled to output a filter sound signal corresponding to the target filter signal, and the filter sound signal can be offset and attenuated with the target noise so as to reduce the target noise. For example, the target filter signal can be sent to the speaker so that the speaker outputs the filter sound signal according to the target filter signal.
[0072] Among them, Figure 3 As shown in the figure, when there are multiple speakers, the target speaker corresponding to the target secondary path can be controlled to output a filtered sound signal. The target secondary path is the secondary path between the target speaker and the target error microphone, where the position of the target error microphone represents the target position where noise reduction is required. A secondary path can be established between a speaker and an error microphone. There are a total of l×m secondary paths in the figure.
[0073] In one possible implementation, before obtaining the target estimation coefficient, the method also includes: obtaining an original estimation coefficient set, which is obtained through secondary path modeling, and the original estimation coefficient set includes estimation coefficients corresponding to multiple noise frequencies; performing data transformation on the estimation coefficient corresponding to each noise frequency in the original estimation coefficient set to obtain a target estimation coefficient set, and each estimation coefficient in the target estimation coefficient set includes a real value and an imaginary value.
[0074] In this embodiment, an original estimation coefficient set can be obtained in advance through secondary path modeling, and the original estimation coefficient set includes estimation coefficients corresponding to multiple noise frequencies. For example, if the noise frequency of the engine of the vehicle ranges from 50 to 200 Hz, an estimation coefficient corresponding to each Hz within the range of 50 to 200 Hz can be established. When there are multiple speakers and error microphones, multiple secondary paths can be established, and one secondary path can be established between one speaker and one error microphone. Each secondary path corresponds to one estimation coefficient. At this time, each noise frequency can correspond to multiple secondary paths, that is, each noise frequency can correspond to multiple estimation coefficients.
[0075] After obtaining the original estimated coefficient set, the estimated coefficient corresponding to each noise frequency in the original estimated coefficient set can be Fourier transformed to obtain the target estimated coefficient set. Since the estimated coefficient becomes an imaginary number after Fourier transformation, each estimated coefficient in the target estimated coefficient set includes its corresponding real part value and imaginary part value.
[0076] After obtaining the target estimation coefficient set, the estimation coefficient corresponding to the noise frequency that is the same as the target noise frequency can be searched from the target estimation coefficient set according to the target noise frequency to obtain the target estimation coefficient. The target estimation coefficient can be the estimation coefficient corresponding to multiple secondary paths corresponding to the noise frequency.
[0077] Through the above method, after obtaining the original estimation coefficient set through secondary path modeling, each estimation coefficient in the original estimation coefficient set can be subjected to Fourier transform, so that each estimation coefficient after the transform includes a real value and an imaginary value, so that the convolution calculation of the reference signal and the secondary channel estimation can be converted into a simple operation between the real value and the imaginary value of the target estimation coefficient corresponding to the reference signal and the target noise frequency, which can improve the calculation speed.
[0078] Figure 5 is a flow chart showing a method for obtaining a target filtering signal according to an exemplary embodiment. Figure 6 is a flowchart of a noise reduction method according to an exemplary embodiment. Figure 5 and Figure 6 As shown, in a possible implementation, before obtaining the target filter signal according to the original filter signal and the real and imaginary values in the target estimation coefficient, the original weight coefficient and the original error signal can also be obtained, the original weight coefficient is the current weight coefficient of the first adaptive filter model, and the original error signal is the residual noise signal corresponding to the current residual noise detected by the error microphone. In order to obtain the target filter signal by combining the original weight coefficient and the original error signal.
[0079] Optionally, when there are multiple speakers and error microphones, that is, when there are multiple secondary paths, the target filter signal of each secondary path can be calculated respectively, and then the target filter signal corresponding to each speaker can be determined. Among them, the original weight coefficient can be the current weight coefficient of the first adaptive filtering model under the target secondary path, and the original error signal is the residual noise signal corresponding to the current residual noise detected by the error microphone under the target secondary path.
[0080] Obtaining a target filtered signal according to the original filtered signal and the real and imaginary values in the target estimated coefficients may include the following steps:
[0081] In step S501, a reference filtered signal is obtained according to the original filtered signal and the real and imaginary values in the target estimated coefficients.
[0082] In this embodiment, during the whole process, the target noise frequency will change continuously in real time, generating target noises of different frequencies, and the target noise frequency can be continuously acquired, and the target filter signal corresponding to the target noise frequency acquired each time can be iteratively generated, so that the generated target filter signal can change with the change of the target noise, and obtain a better noise reduction effect. The reference filter signal can be obtained according to the product of the original filter signal and the real value and the imaginary value in the target estimation coefficient. The ordinal number of the acquired target noise frequency can be represented by n, that is, n can represent the number of iterations.
[0083] In a possible implementation manner, in order to facilitate calculation to obtain a target filtered signal, the original filtered signal may include a sinusoidal reference signal and a phase shift signal.
[0084] Optionally, the method for generating an original filtered signal with a target noise frequency according to the target noise frequency may be: generating a sinusoidal reference signal with a target noise frequency according to the target noise frequency; and performing phase transformation on the sinusoidal reference signal to obtain a phase shift signal.
[0085] In this embodiment, a sinusoidal reference signal having the same frequency as the target noise frequency may be generated by a sinusoidal wave generator according to the target noise frequency, wherein two sinusoidal reference signals may be generated, namely a first sinusoidal reference signal and a second sinusoidal reference signal, the first sinusoidal reference signal is retained, and the second sinusoidal reference signal is phase-shifted to obtain a phase-shifted signal. The second sinusoidal reference signal may be phase-shifted by 90° to obtain a phase-shifted signal.
[0086] The expression of the sinusoidal reference signal may be: x0() = A1sin 2πft.
[0087] The expression of the phase shift signal can be: x1() = A2cos 2πft.
[0088] Among them, x0() is the sinusoidal reference signal, x1() is the phase shift signal, A1 and A2 are both empirical parameters that can be set according to actual conditions, f is the target noise frequency, and t is time.
[0089] In a possible implementation, the reference filtered signal includes a first reference sub-signal and a second reference sub-signal. Optionally, the real value in the target estimation coefficient may be multiplied with the sinusoidal reference signal in the original filtered signal to obtain the first reference sub-signal; and the imaginary value in the target estimation coefficient may be multiplied with the phase shift signal in the original filtered signal to obtain the second reference sub-signal.
[0090] In this implementation, the reference filtered signal may be obtained according to the product of the original filtered signal and the target estimated coefficient, thereby reducing the amount of calculation.
[0091] For example, the calculation formula of the first reference sub-signal may be:
[0092]
[0093] The calculation formula of the first reference sub-signal can be:
[0094]
[0095] Among them, x 0f () is the first reference sub-signal, x 1f () is the second reference sub-signal, is the real part of the target estimated coefficient, is the imaginary part of the target estimated coefficient.
[0096] In step S502, a target weight coefficient is obtained according to the reference filtered signal, the original error signal and the original weight coefficient.
[0097] In this embodiment, the original weight coefficient may include a first original weight sub-coefficient and a second original weight sub-coefficient, and the target weight coefficient may include a first target weight sub-coefficient and a second target weight sub-coefficient. Optionally, the first original weight sub-coefficient may be updated according to the first reference sub-signal and the original error signal to obtain a first target weight sub-coefficient; the second original weight sub-coefficient may be updated according to the second reference sub-signal and the original error signal to obtain a first target weight sub-coefficient. In each round of iteration, the target filter signal is obtained based on the weight coefficient of the previous round and combined with the original error signal. The first original weight sub-coefficient in this round of iteration is the first target weight sub-coefficient obtained in the previous round of iteration and corresponding to the first reference confidence, and the second original weight sub-coefficient is the second target weight sub-coefficient obtained in the previous round of iteration and corresponding to the second reference confidence.
[0098] For example, the calculation formula of the first target weight sub-coefficient may be:
[0099] w0(+1)=w0()-μe() 0f ()
[0100] The calculation formula of the second objective weight sub-coefficient can be:
[0101] w1(+1)=w1()-μe() 1f ()
[0102] Among them, w0() is the first original weight sub-coefficient, w0(+1) is the first target weight sub-coefficient, μ is the step size, e(n) is the original error signal, x 0f () is the first reference sub-signal, w1() is the first original weight sub-coefficient, w1(+1) is the first target weight sub-coefficient, μ is the step size, e(n) is the original error signal, x 1f () is the first reference sub-signal, and n is the ordinal number of the acquired target noise frequency.
[0103] Optionally, when there are multiple secondary paths, each secondary path may have a corresponding weight coefficient, so that each secondary path may obtain a corresponding target weight coefficient through the above method. The original error signal is the residual noise signal detected by the corresponding error microphone in the secondary path.
[0104] In step S503, a target filtered signal is obtained according to the original filtered signal and the target weight coefficient.
[0105] In this implementation, the original filtered signal may be adjusted based on the target weight coefficient to obtain a target filtered signal.
[0106] For example, the calculation formula of the target filtering signal may be:
[0107] u(n)=w0()0()+w1()1()
[0108] Among them, u(n) is the target filtering signal.
[0109] Optionally, when there are multiple secondary paths, u(n) is the target filter signal corresponding to one of the secondary paths, and the target filter signals corresponding to all the secondary paths corresponding to each speaker can be determined by the above method, and the final target filter signal corresponding to each speaker can be determined according to the target filter signals corresponding to all the secondary paths corresponding to each speaker. For any speaker, the final target filter signal corresponding to it can be any signal among all the target filter signals corresponding to the speaker, or the final target filter signal corresponding to it can be the average signal of all the target filter signals corresponding to the speaker.
[0110] In a possible implementation manner, the original weight coefficient includes a first original weight sub-coefficient, and the target weight coefficient includes a first target weight sub-coefficient.
[0111] According to the reference filtering signal, the original error signal and the original weight coefficient, the method for obtaining the target weight coefficient may be: according to the first reference sub-signal and the original error signal, the first original weight sub-coefficient is updated to obtain the first target weight sub-coefficient.
[0112] Furthermore, according to the original filtered signal and the target weight coefficient, the method for obtaining the target filtered signal may be: obtaining the first filtered signal according to the sinusoidal reference signal and the first target weight sub-coefficient, and obtaining the target filtered signal according to the first filtered signal.
[0113] Figure 7 is a flow chart showing a method for determining an estimation coefficient corresponding to any noise frequency according to an exemplary embodiment. Figure 7 As shown, in a possible implementation manner, the estimated coefficient corresponding to any noise frequency in the original estimated coefficient set can be obtained in advance by means of secondary path modeling, which may include the following steps:
[0114] In step S701, a modeled noise signal corresponding to any noise frequency is obtained.
[0115] In this embodiment, a corresponding estimation coefficient can be established for each noise frequency. If there are multiple speakers and error microphones, multiple secondary paths can be established, and a corresponding estimation coefficient can be established for each secondary path at each noise frequency. The white noise generator can emit a white noise signal of any noise frequency to drive the speaker as the modeling noise, thereby obtaining the modeling noise signal corresponding to the any noise frequency.
[0116] In step S702, the modeled noise signal is input into the second adaptive filtering model to generate a modeled filtered signal.
[0117] In step S703, the modeled noise signal and the modeled filter signal are synthesized to obtain a modeled error signal.
[0118] In this embodiment, the modeling filter signal is used to reduce the modeling noise signal. By synthesizing the modeling noise signal and the modeling filter signal, a synthesized modeling error signal can be obtained. The modeling error signal is the sum of the modeling filter signal and the modeling noise signal.
[0119] In step S704, the parameters of the second adaptive filtering model are optimized according to the modeling error signal, and the process returns to the step of inputting the modeling noise signal into the second adaptive filtering model to generate a modeling filtering signal until the modeling error signal meets the preset conditions to obtain the target adaptive filtering model.
[0120] In this embodiment, the parameters of the second adaptive filtering model can be optimized by the modeling error signal, and the step S702 is returned to re-input the modeling noise signal into the optimized second adaptive filtering model to obtain a new modeling filter signal, so that the modeling filter signal output by the second adaptive filtering model can be closer to the modeling noise signal, until the modeling error signal meets the preset condition, for example, the value of the error signal can be determined, the value of the error signal can be a value between 0 and 1, and whether the target adaptive filtering model is obtained can be determined based on the relationship between the value of the error signal and the preset distance, for example, when the value of the error signal is less than or equal to the preset distance, it is determined that the target adaptive filtering model is obtained. The preset distance can be 0 or 0.1. The target adaptive filtering model is obtained by training the second adaptive filtering model with the modeling noise signal corresponding to any noise frequency. For example, the target adaptive filtering model corresponding to the target noise signal, i.e., the first adaptive filtering model, can be obtained by training the second adaptive filtering model with the target noise signal. By respectively training the second adaptive filter model with modeled noise signals of different noise frequencies, the target adaptive filter model corresponding to the noise signals of different noise frequencies can be obtained, and then the estimation coefficients corresponding to multiple noise frequencies can be obtained according to the target adaptive filter model corresponding to the noise signals of different noise frequencies, and then the original estimation coefficient set can be obtained. For example, the target estimation coefficient can be obtained by the target adaptive filter model corresponding to the target noise signal of the target noise frequency.
[0121] In step S705, the current estimation coefficient of the target adaptive filtering model is determined as the estimation coefficient corresponding to any noise frequency.
[0122] In this embodiment, according to the current estimated coefficients of the target adaptive filtering model, the corresponding modeling filter signal that meets the preset conditions can be obtained. When there are multiple secondary paths, the method of this embodiment obtains the estimated coefficients corresponding to a secondary path at any noise frequency. The estimated coefficients corresponding to the secondary paths at other frequencies can be obtained by the same method, and finally the original estimated coefficient set is obtained.
[0123] Figure 8 is an overall flow chart of a noise reduction method according to an exemplary embodiment. Figure 8 As shown, optionally, the noise reduction method may include the following steps:
[0124] In step S801, a loudspeaker is driven to emit modeled noise according to a modeled noise signal of any frequency.
[0125] In step S802, the error microphone collects the modeled noise signal played by the loudspeaker.
[0126] In step S803, a modeling filter signal is generated using the second adaptive filter model.
[0127] In step S804, the modeled noise signal and the modeled filtered signal are synthesized to obtain a modeled error signal.
[0128] In step S805, it is determined whether the modeling error signal meets the preset condition. If the modeling error signal does not meet the preset condition, step S806 is executed. If the modeling error signal meets the preset condition, step S807 is executed.
[0129] In step S806, the original weight coefficients are updated to obtain target weight coefficients.
[0130] In step S807, the current estimation coefficient of the target adaptive filtering model is determined as the estimation coefficient corresponding to any noise frequency, and a Fourier transform is performed on it.
[0131] In step S808, the engine is started and the noise reduction system is turned on.
[0132] In step S809, the host obtains the engine speed information, obtains the target noise frequency, and sends it to the sine wave generator.
[0133] In step S810, a sine wave generator generates a sine reference signal and a phase shift signal.
[0134] In step S811, the sinusoidal reference signal and the phase-shifted signal are respectively multiplied by the real value and the imaginary value of the target estimation coefficient to obtain a reference filtered signal.
[0135] In step S812, the reference filtered signal and the original error signal are input into a first adaptive filtering model to obtain a target filtered signal.
[0136] In step S813, the speaker outputs a filtered sound signal according to the target filtered signal, and the filtered sound signal is used to reduce the target noise.
[0137] In step S814, an error signal is collected by the error microphone, and the process returns to step S812.
[0138] Fig. 9 900 is a block diagram of an electronic device according to an exemplary embodiment. For example, the electronic device 900 may be provided as a noise reduction device, and the noise reduction device may be a noise reduction controller. Fig. 9The electronic device 900 includes a processor 922, which may be one or more, and a memory 932 for storing a computer program executable by the processor 922. The computer program stored in the memory 932 may include one or more modules, each corresponding to a set of instructions. In addition, the processor 922 may be configured to execute the computer program to perform the above-mentioned noise reduction method.
[0139] Preferably, the electronic device 900 may further include a power supply component 926 and a communication component 950, wherein the power supply component 926 may be configured to perform power management of the electronic device 900, and the communication component 950 may be configured to implement communication of the electronic device 900, for example, wired or wireless communication. Preferably, the electronic device 900 may further include an input / output interface 958. The electronic device 900 may operate based on an operating system stored in the memory 932.
[0140] In another exemplary embodiment, a computer-readable storage medium including program instructions is also provided, and when the program instructions are executed by the processor, the steps of the above-mentioned noise reduction method are implemented. For example, the computer-readable storage medium can be the above-mentioned memory 932 including program instructions, and the above-mentioned program instructions can be executed by the processor 922 of the electronic device 900 to complete the above-mentioned noise reduction method.
[0141] In another exemplary embodiment, a computer program product is also provided. The computer program product includes a computer program executable by a programmable device, and the computer program has a code portion for executing the above-mentioned noise reduction method when executed by the programmable device.
[0142] The preferred embodiments of the present disclosure are described in detail above in conjunction with the accompanying drawings; however, the present disclosure is not limited to the specific details in the above embodiments. Within the technical concept of the present disclosure, a variety of simple modifications can be made to the technical solution of the present disclosure, and these simple modifications all fall within the protection scope of the present disclosure.
[0143] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, the present disclosure will not further describe various possible combinations.
[0144] In addition, various embodiments of the present disclosure may be arbitrarily combined, and as long as they do not violate the concept of the present disclosure, they should also be regarded as the contents disclosed by the present disclosure.
Claims
1. A noise reduction method, characterized in that: include: Obtaining a target estimation coefficient, wherein the target estimation coefficient is obtained by a target noise frequency, wherein the target noise frequency is a frequency corresponding to the target noise, and the target estimation coefficient includes a real part value and an imaginary part value; According to the target noise frequency, generating an original filtered signal having a frequency equal to the target noise frequency; A target filtering signal is obtained according to the original filtering signal and the real and imaginary values in the target estimation coefficients. The target filtering signal is used to control the loudspeaker to output a filtered sound signal to reduce the target noise.
2. The noise reduction method according to claim 1, characterized in that: Before obtaining the target estimation coefficient, the method further includes: Obtaining an original estimation coefficient set, wherein the original estimation coefficient set is obtained through secondary path modeling, and the original estimation coefficient set includes estimation coefficients corresponding to multiple noise frequencies; Performing data transformation on the estimation coefficient corresponding to each noise frequency in the original estimation coefficient set to obtain a target estimation coefficient set, wherein each estimation coefficient in the target estimation coefficient set includes a real part value and an imaginary part value; The step of determining a target estimation coefficient according to the target noise frequency includes: Obtain the estimation coefficient corresponding to the target noise frequency in the target estimation coefficient set to obtain the target estimation coefficient.
3. The noise reduction method according to claim 1, characterized in that: The original filtered signal includes a sinusoidal reference signal and a phase shift signal; The step of generating an original filtered signal having a frequency equal to the target noise frequency according to the target noise frequency includes: According to the target noise frequency, generating the sinusoidal reference signal having a frequency equal to the target noise frequency; The sinusoidal reference signal is phase-shifted to obtain the phase-shifted signal.
4. The noise reduction method according to claim 1, characterized in that: The step of obtaining a target filtered signal according to the original filtered signal and the real value and the imaginary value in the target estimated coefficient comprises: Obtaining a reference filtered signal according to the original filtered signal and the real and imaginary values in the target estimated coefficients; Obtaining a target weight coefficient according to the reference filter signal, the original error signal and the original weight coefficient, wherein the original weight coefficient is a current weight coefficient of the first adaptive filter model, and the original error signal is a residual noise signal corresponding to the current residual noise detected by the error microphone; The target filtered signal is obtained according to the original filtered signal and the target weight coefficient.
5. The noise reduction method according to claim 4, characterized in that: The original filtered signal includes a sinusoidal reference signal and a phase shift signal, and the reference filtered signal includes a first reference sub-signal and a second reference sub-signal; The step of obtaining a reference filtered signal according to the original filtered signal and the real value and the imaginary value in the target estimated coefficient comprises: Multiplying the real part value in the target estimation coefficient by the sinusoidal reference signal in the original filtered signal to obtain the first reference sub-signal; The imaginary part value in the target estimation coefficient is multiplied by the phase shift signal in the original filtered signal to obtain the second reference sub-signal.
6. The noise reduction method according to claim 5, characterized in that: The original weight coefficient includes a first original weight sub-coefficient, and the target weight coefficient includes a first target weight sub-coefficient; The step of obtaining a target weight coefficient according to the reference filtered signal, the original error signal and the original weight coefficient comprises: updating the first original weight sub-coefficient according to the first reference sub-signal and the original error signal to obtain the first target weight sub-coefficient; The step of obtaining the target filtered signal according to the original filtered signal and the target weight coefficient comprises: Obtaining a first filtered signal according to the sinusoidal reference signal and the first target weight sub-coefficient; The target filtered signal is obtained according to the first filtered signal.
7. The noise reduction method according to claim 6, characterized in that: The original weight coefficient also includes a second original weight sub-coefficient, and the target weight coefficient also includes a second target weight sub-coefficient; The step of obtaining a target weight coefficient according to the reference filtered signal, the original error signal and the original weight coefficient comprises: updating the second original weight sub-coefficient according to the second reference sub-signal and the original error signal to obtain the second target weight sub-coefficient; The step of obtaining the target filtered signal according to the original filtered signal and the target weight coefficient comprises: Obtaining a second filtered signal according to the phase shift signal and the second target weight sub-coefficient; The target filtered signal is obtained according to the first filtered signal and the second filtered signal.
8. The noise reduction method according to claim 2, characterized in that: The estimated coefficient corresponding to any noise frequency in the original estimated coefficient set is obtained by the following steps: Obtaining a modeled noise signal corresponding to any noise frequency; Inputting the modeled noise signal into a second adaptive filtering model to generate a modeled filtering signal; synthesizing the modeling noise signal and the modeling filter signal to obtain a modeling error signal; Optimizing the parameters of the second adaptive filtering model according to the modeling error signal, and returning to the step of: inputting the modeling noise signal into the second adaptive filtering model to generate a modeling filtering signal until the modeling error signal meets a preset condition, thereby obtaining a target adaptive filtering model; The current estimation coefficient of the target adaptive filtering model is determined as the estimation coefficient corresponding to any one of the noise frequencies.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the steps of the noise reduction method described in any one of claims 1 to 8 are implemented.
10. A noise reduction device, characterized in that: include: a memory having a computer program stored thereon; A processor, configured to execute the computer program in the memory to implement the steps of the noise reduction method according to any one of claims 1 to 8.
11. A terminal device, characterized in that: The invention comprises a loudspeaker, an error microphone, a host and the noise reduction device according to claim 10, wherein the noise reduction device is communicatively connected with the loudspeaker, the error microphone and the host respectively.
Citation Information
Cited By
Noise reduction method and apparatus, terminal device, and storage medium
EP4723098A1
