Method and device for determining unvarnished transmission adaptive filter, medium, equipment and earphone
Through the determination method of the adaptive filter, the target path transfer function and the current weight parameters are used to calculate the expected signal and error signal, and determine the target weight parameters, which solves the stability problem of transparent transmission headphones in different wearing methods and motion states, and achieves Provides more accurate ambient sound transmission and high-quality audio output.
Patent Information
- Application Number
- CN202411437443.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-15
- Publication Date
- 2025-01-21
- Estimated Expiration
- 2044-10-15
AI Technical Summary
The existing transparent inlet earphones have poor stability in different wearing methods and sports conditions, and cannot effectively adapt to the changes in the positional relationship between the earphones and the ears.
By obtaining the preset target path transmission function and the current weight parameters of the filter, the external microphone and internal microphone are used to collect input signals and superimposed signals, calculate the expectations of the desired signal and the first error signal, and determine the target weight parameters of the filter to achieve self -self Adapt to filtering.
Provide more accurate and natural environmental sound transmission effects in a complex environment, which significantly improves the user experience, and enables the headset to maintain high -quality audio output while achieving intelligent management of acoustic transparency.
Smart Images

Figure CN119342381A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of transparent in-ear headphones, and specifically relates to a method, device, medium, equipment and headphones for determining a transparent adaptive filter. Background Art
[0002] Ambient sound transmission is a technology that allows users to hear the surrounding sounds clearly and naturally while wearing headphones. It enables a convenient experience of communicating with others without taking off the headphones, which is especially important for those who need to communicate in noisy environments. For users who need to wear headphones outdoors, being able to clearly hear the ambient sounds helps to ensure the safety of the users. In terms of audio applications for augmented reality (AR), the primary goal is to enable headphones to transmit external sounds naturally and accurately.
[0003] The structure of the prior art transmissive earphone is as follows: Figure 1 As shown, it mainly includes: an external microphone, a secondary speaker, an internal microphone and a filter. The external microphone can collect ambient sound, and then the filter processes the collected ambient sound according to a preset weight coefficient to generate an analog signal, and then the analog signal output by the secondary speaker makes the sound received by the human ear as restored as possible to the sound received when not wearing headphones. The internal microphone is closer to the human ear than the secondary speaker and is used to collect external sounds received at the human ear. Among them, since wearing headphones will hinder the natural transmission of external sounds, but it cannot completely isolate external sounds, there will still be residual signals that pass through the human ear of external sounds. Therefore, when wearing through-ear headphones, the sounds received by the human ear mainly include: the residual signals generated by the direct transmission of external sounds and the analog signals played by the secondary speaker.
[0004] However, when a person wears headphones, the positional relationship between the headphones and the ears is not fixed, which causes the residual signal heard by the human ear to be different due to different wearing methods. The prior art generates analog signals by giving the filter a fixed weight coefficient, and is unable to make adaptive adjustments according to the wearing method of the headphones. As a result, the transparent transmission stability of the transparent headphones is poor, especially when the user is in motion. At this time, the positional relationship between the headphones and the ears will change differently with the movement, making the transparent transmission stability of the transparent headphones in the prior art even worse. Summary of the invention
[0005] In response to the above technical problems, the present invention proposes a method, device, medium, equipment and earphone for determining a transparent adaptive filter. The present application obtains a preset target path transfer function and the current weight parameters of the filter, and obtains an input signal through the external microphone of the transparent in-ear earphone, and obtains a superimposed signal through the internal microphone; determines an expected signal according to the input signal and the target path transfer function; determines a first error signal according to the expected signal and the superimposed signal; determines the target weight parameters of the filter according to the first error signal and the current weight parameters. It can provide a more accurate and natural environmental sound transmission effect under various complex environmental conditions. This improvement significantly improves the user experience, allowing the earphones to truly achieve intelligent management of acoustic transparency while maintaining high-quality audio output.
[0006] To solve the above technical problems, the technical solution provided by the present invention includes five aspects.
[0007] In the first aspect, the present application provides a method for determining a transparent adaptive filter, including: obtaining a preset target path transfer function and current weight parameters of the filter, and obtaining an input signal through an external microphone of a transparent in-ear headphone, and obtaining a superimposed signal through an internal microphone; determining an expected signal based on the input signal and the target path transfer function; determining a first error signal based on the expected signal and the superimposed signal; and determining the target weight parameters of the filter based on the first error signal and the current weight parameters.
[0008] In some embodiments, determining the first error signal based on the expected signal and the superimposed signal includes: acquiring the input autopower spectrum of the input signal, the expected autopower spectrum of the expected signal, and the cross power spectrum between the input signal and the expected signal; determining the number of time-shift points of the expected signal based on the input autopower spectrum, the expected autopower spectrum, and the cross power spectrum; determining the expected time-shifted signal based on the number of time-shift points and the expected signal; and determining the first error signal based on the expected time-shifted signal and the superimposed signal.
[0009] In some embodiments, determining the target weight parameters of the filter based on the first error signal and the current weight parameters includes: obtaining a preset secondary path estimate and a preset basic update step; determining a filtered signal of the filter based on the input signal and the secondary path estimate; and determining the target weight parameters based on the filtered signal, the first error signal, the current weight parameters, and the basic update step.
[0010] In some embodiments, determining the target weight parameter based on the filtered signal, the first error signal, the current weight parameter and the basic update step size includes: determining a first relationship between the basic update step size and the filtered signal based on the first error signal; determining the real-time update step size of the filter based on the first relationship and the basic update step size; determining the target weight coefficient based on the real-time update step size, the filtered signal, the current weight coefficient and the first error signal.
[0011] In some embodiments, determining the target weight coefficient based on the real-time update step, the filter signal, the current weight coefficient and the first error signal includes: determining a first update formula for the filter based on the current weight information, the first error signal and the filter signal; determining a second update formula for the filter based on the first update formula and the real-time update step; and determining the target weight coefficient based on the second update formula.
[0012] In some embodiments, the second update formula is as follows: Wherein, w(n+1) is the target weight coefficient of the filter, w(n) is the current weight coefficient of the filter, and w(n)≡[w0(n)w1(n-1)…w L-1 (n)] T is the weight vector; w l (n)(l-0,...,L-1) is the l-th coefficient of the filter with a filter length of L, and μ is the update step size. is the real-time update step size, x′(n) is the filtered signal, e′(n) is the first error signal, and δ is a constant.
[0013] In the second aspect, the present application proposes a device for determining a transparent adaptive filter, comprising: a first acquisition module, used to obtain a preset target path transfer function and a current weight parameter of the filter, and obtain an input signal through an external microphone of a transparent in-ear headphone, and obtain a superimposed signal through an internal microphone; a first determination module, used to determine an expected signal based on the input signal and the target path transfer function; a second determination module, used to determine a first error signal based on the expected signal and the superimposed signal signal; a third determination module, used to determine a first error signal based on the expected signal and the superimposed signal signal; a third determination module, used to determine the target weight parameters of the filter based on the first error signal and the current weight parameters.
[0014] In a third aspect, the present application provides an electronic device, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of any one of the methods described in the first aspect.
[0015] In a fourth aspect, the present application provides a readable storage medium having a computer program stored thereon, characterized in that when the computer program is executed by a processor, the steps of any one of the methods described in the first aspect are implemented.
[0016] In a fifth aspect, the present application provides a through-ear earphone, comprising: an earphone body and an electronic device as described in the third aspect, wherein the electronic device is connected to the earphone body.
[0017] Beneficial effects created by the present invention: The present application obtains the preset target path transfer function and the current weight parameters of the filter, and obtains the input signal through the external microphone of the in-ear headphone, and obtains the superimposed signal through the internal microphone; determines the expected signal according to the input signal and the target path transfer function; determines the first error signal according to the expected signal and the superimposed signal; determines the target weight parameters of the filter according to the first error signal and the current weight parameters. It can provide a more accurate and natural environmental sound transmission effect under various complex environmental conditions. This improvement significantly improves the user experience, allowing the headphones to truly achieve intelligent management of acoustic transparency while maintaining high-quality audio output. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] The scope of the present disclosure may be better understood by reading the following detailed description of exemplary embodiments in conjunction with the accompanying drawings. The drawings included are:
[0019] Figure 1 A schematic diagram of the structure of a transmissive in-ear headset provided in an embodiment of the present application;
[0020] Figure 2 An overall flow chart of a method for determining a transparent transmission adaptive filter provided in an embodiment of the present application;
[0021] Figure 3 A schematic diagram of a control system block diagram of a transmissive in-ear headset provided in an embodiment of the present application;
[0022] Figure 4 A structural block diagram of a device for determining a transparent adaptive filter provided in an embodiment of the present application. DETAILED DESCRIPTION
[0023] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.
[0024] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.
[0025] If similar descriptions of "first\second\third" appear in the application documents, the following instructions will be added. In the following description, the terms "first\second\third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged in a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0026] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application and are not intended to limit this application.
[0027] Embodiment 1:
[0028] When people wear headphones, the positional relationship between the headphones and the ears is not fixed, which causes the residual signal heard by the human ear to be different due to different wearing methods. The prior art generates analog signals by giving the filter a fixed weight coefficient, and cannot make adaptive adjustments according to the wearing method of the headphones, resulting in poor transmission stability of the transparent headphones. Especially when the user is in motion, the positional relationship between the headphones and the ears will change differently with the movement, which makes the transmission stability of the transparent headphones in the prior art even worse.
[0029] In view of the problems existing in the prior art, such as Figure 2 As shown, the present application provides a method for determining a transparent adaptive filter, and the method is applied to an electronic device, and the electronic device can be a server, a mobile terminal, a computer, a cloud platform, etc. The function implemented by the device data processing provided in the embodiment of the present application can be implemented by calling a program code by a processor of the electronic device, wherein the program code can be stored in a computer storage medium, and the method for determining a transparent adaptive filter includes:
[0030] Step S1: obtaining a preset target path transfer function and current weight parameters of a filter, obtaining an input signal through an external microphone of a through-ear headphone, and obtaining a superimposed signal through an internal microphone.
[0031] The external microphone of the transparent earphone can collect environmental sounds, that is, the input signal mentioned in this application. The secondary speaker plays the analog signal generated by the filter according to the input signal, and restores the sound of the outside world as much as possible. The internal microphone is closer to the human ear than the secondary speaker, and is used to collect the sound received at the human ear. Among them, since the natural transmission of external sounds will be blocked when wearing headphones, it is difficult for the human ear to directly obtain the sound of the outside world when wearing headphones. In this application, if the human ear wants to obtain the same external sound when wearing headphones as when not wearing headphones, it is necessary to clarify a reference signal for correcting the filter weight coefficient, that is, the expected signal. The expected signal is the external signal collected at the human ear when the human ear is not wearing headphones. Of course, no matter how the current headphones are worn, they cannot completely isolate the external sound, so there will be residual signals transmitted to the internal microphone through the external sound. Therefore, when wearing transparent earphones, the external sound received by the human ear mainly includes: the residual signal generated by the direct transmission of the external sound and the compensation signal when the analog signal played by the secondary speaker reaches the internal microphone. Therefore, for the human ear, the external sound heard when wearing headphones is the superposition of the compensation signal and the residual signal, that is, the superposition signal, and the superposition signal can be collected by the internal microphone. The superposition signal collected at this time is the superposition of the analog signal generated by the filter based on the current weight coefficient and the residual signal, but when the external input signal changes, the residual signal will also change accordingly. If the current weight coefficient is still collected to generate the analog signal at this time, the difference between the superposition signal and the real sound will be large. Moreover, the main path transfer function of input signals of different frequencies is different when they are naturally transmitted to the human ear. Therefore, if you want the transparent transmission headphones to achieve a stable transparent transmission effect, you need to update the weight coefficient of the filter in real time according to the input signal. The weight coefficient that needs to be updated in this application is called the target weight coefficient, and if you want to get the target weight coefficient, you need to get the current weight coefficient first, and update it on the basis of the current weight coefficient to get the target weight coefficient.
[0032] The expected signal cannot be obtained in real time while wearing headphones, but we can obtain the transfer function of external sound when it is transmitted to the human ear when not wearing headphones, that is, the target path transfer function of this application. When the target path transfer function is obtained, we can calculate the expected signal at this time based on the input signal. However, when calculating the target path transfer function, it is necessary to perform the technology without wearing headphones.
[0033] Therefore, when calculating the target path transfer function, it is necessary to first obtain the desired signal directly collected when not wearing headphones. In this application, when obtaining the desired signal, pink noise is played as the excitation signal, and the desired signal when not wearing headphones, as well as the residual signal and input signal after wearing headphones are collected respectively. Then white noise is played through the secondary speaker, and the compensation signal formed after the white noise is propagated is collected at the internal microphone.
[0034] The secondary path is formed from the secondary speaker to the internal microphone, the main path is formed from the external microphone to the internal microphone, and the target path is formed from the external microphone to the human ear when the headphones are not worn.
[0035] Therefore, the control block diagram designed for the transparent in-ear headphones in this application is as follows Figure 3 As shown. Where P(z) is the primary path transfer function, which represents the acoustic path between the external microphone and the internal microphone when wearing headphones; S(z) is the secondary path transfer function, which represents the acoustic path from the secondary speaker to the internal microphone. is the estimate of the secondary path transfer function; T(z) is the target path transfer function, which represents the acoustic path between the external microphone when wearing headphones and the human ear when not wearing headphones, is the estimate of the target path transfer function. W(z) is the adaptive HT controller, i.e., the filter.
[0036] Step S2: Determine an expected signal according to the input signal and the target path transfer function.
[0037] Since the present application has obtained the preset target path transfer function and input signal, the expected signal corresponding to the current input signal can be easily calculated on the premise that the target path transfer function and input signal are clear.
[0038] Step S3: Determine a first error signal according to the expected signal and the superimposed signal.
[0039] In some embodiments, step S3 “determine a first error signal according to the expected signal and the superimposed signal” includes:
[0040] Step S31: acquiring an input autopower spectrum of the input signal, an expected autopower spectrum of the expected signal, and a cross power spectrum between the input signal and the expected signal.
[0041] Step S32: determining the number of time-shift points of the expected signal according to the input autopower spectrum, the expected autopower spectrum and the cross-power spectrum.
[0042] Step S33: determining an expected time-shifted signal according to the time-shift point number and the expected signal.
[0043] Step S34: determining a first error signal according to the desired time-shifted signal and the superimposed signal.
[0044] Since the input signal and the expected signal cannot be collected at the same time, the expected signal in the present application is calculated through the input signal, but there is a large difference between the calculated expected signal and the actually collected expected signal, and thus the actual correlation between the expected signal and the input signal is very low, almost zero, so the expected signal at this time cannot be directly used for other calculations, so it is also necessary to calculate the time-shift points of the input signal and the expected signal so that the expected signal can be aligned at both ends of the input signal to improve the correlation between the two.
[0045] First, define the correlation function between the input signal x(n) and the desired signal d′(n) as:
[0046] Where S dd (ω) and S xx (ω) represent the autopower spectra of the desired signal d′(n) and the input signal x(n); S dx (ω) is the cross power spectrum, ω represents the frequency. Correlation C dx (ω) is a normalized cross-spectral density function that satisfies the following constraints at all frequencies:
[0047]
[0048] In order to select the optimal number of time offset points, the average amplitude square correlation is used as the evaluation indicator. It can be expressed as:
[0049] where ω k are the sampling points in the frequency domain.
[0050] like Figure 3 As shown in the figure, the delayed time shift point △2 acts on the expected signal d′(n). By continuously changing △2, we can find a point that can make C avg Maximize the number of time-shift points so that the input signal and the expected signal satisfy the causal relationship.
[0051] Therefore, in the present application, after the number of time shift points is determined, the expected time shift signal can be determined according to the number of time shift points and the expected signal.
[0052] Step S4: determining a target weight parameter of the filter according to the first error signal and the current weight parameter.
[0053] In some embodiments, step S4 "determining the target weight parameter of the filter according to the first error signal and the current weight parameter" includes:
[0054] Step S41: Obtain a preset secondary path estimate and a preset basic update step size.
[0055] Step S42: Determine a filtered signal of the filter according to the input signal and the secondary path estimation.
[0056] Although the secondary path can be measured in theory, in practical applications, the secondary path transfer function S(z) is unknown, such as Figure 3 As shown, an additional filter must be estimated Here, it is referred to as secondary path estimation. Therefore, the input signal after the secondary path estimation generates the input signal of the filter, that is, the filtered signal. Therefore, after the input signal passes through the secondary path estimation, x'(n) will be generated as the input signal of the filter, which can also be understood as the signal that the filter needs to filter, so it is called the filtered signal in this application.
[0057] Step S43: determining the target weight parameter according to the filtered signal, the first error signal, the current weight parameter and the basic update step size.
[0058] In some embodiments, step S43 "determining the target weight parameter according to the filtered signal, the first error signal, the current weight parameter and the basic update step size" includes:
[0059] Step S431: Determine a first relationship between a basic update step size and the filtered signal according to a first error signal.
[0060] Step S432: Determine the real-time update step size of the filter according to the first relationship and the basic update step size.
[0061] Step S433: Determine the target weight coefficient according to the real-time update step size, the filter signal, the current weight coefficient and the first error signal.
[0062] The step size μ is very important for the update of the filter. It has a great influence on the stability, convergence speed and misadjustment parameters. When fast convergence is required, a larger step size can be selected. However, this will lead to larger misadjustment parameters. If the step size is too large, the algorithm will not converge. On the other hand, a small step size will lead to smaller misadjustment, but also slower convergence. The stability condition of the step size is:
[0063] where tr[R] is the autocorrelation matrix E[x T (n)x(n)].
[0064] Therefore, a basic update step size is set in the present application, and then the relationship between the basic update step size and the filter signal is established by using the normalized least mean square algorithm, so that the update step size in actual calculation can change with the change of the filter signal, so as to ensure both stability and rapid convergence.
[0065] In some embodiments, step S433 "determining the target weight coefficient according to the real-time update step size, the filter signal, the current weight coefficient and the first error signal" includes;
[0066] Step S4331: Determine a first update formula of the filter according to the current weight information, the first error signal and the filtered signal.
[0067] In the field of acoustics, the minimum mean square error is usually used as the weight update formula, and the instantaneous error estimate is usually used instead of the average error.
[0068] Therefore, the weight update formula in this application is: J(n) = E[e' 2 (n)], where e'(n) is the first error signal.
[0069] According to the gradient descent method, the weight update formula can be converted to: Among them It means that J(n) takes the partial derivative of x(n), which can be expressed as:
[0070] According to Figure 3 It can be known that: e′(n)=d′(n-△2)-e(n), where d′(n-△2) represents the desired time-shifted signal, that is, d′(n-△2)=t T (n-△2)x(n), e(n) represents the superposition signal generated by the superposition of the compensation signal y′(n) and the residual signal d(n), which can be expressed as: e(n)=y'(n)+d(n). Where y'(n) is the output signal of the filter through the secondary path, which can be expressed as: y'(n)=y(n)*s(n).
[0071] The output signal y(n) of the filter is expressed as: y(n) = w T (n)x(n), where w(n)≡[w0(n)w1(n-1)…w L-1 (n)] T is the current weight coefficient; w l (n)(l=0,1,...L-1) is the lth coefficient of the filter of length L, x(n)=[x(n)x(n-1)…x(n-L+1)] T Input signal picked up by an external microphone.
[0072] Therefore, based on the above e′(n)=d′(n-△2)-e(n), e(n)=y′(n)+d(n), y′(n)=y(n)*s(n), we can get the following relationship:
[0073] Where x'(n)=x(n)*s(n), * represents linear convolution.
[0074] Substituting this relationship into the weight update formula after the gradient descent method, the first update formula is as follows:
[0075] w(n+1)=w(n)-μx′(n)e′(n), where μ is the base update step size.
[0076] Step S4332: Determine a second update formula for the filter according to the first update formula and the real-time update step size.
[0077] In some embodiments, the second update formula is as follows:
[0078]
[0079] Where w(n+1) is the current weight coefficient of the filter, w(n)≡[w0(n)w1(n-1)…w L-1 (n)] T is the current weight coefficient. l (n)(l-0,…,L-1) is the l-th coefficient of the filter with a filter length of L, and μ is the update step size. To update the step size in real time, x'(n) is the filtered signal, e'(n) is the first error signal, and δ is a constant. δ is a very small constant, the purpose of which is to prevent the denominator from being zero during the iteration process.
[0080] Step S4333: Determine the filter according to the second update formula.
[0081] This application achieves a more accurate and natural environmental sound transmission effect in various complex environmental conditions through the above method. This improvement significantly improves the user experience, allowing the headphones to truly achieve intelligent management of acoustic transparency while maintaining high-quality audio output. In addition, in the process of determining the filter, the real-time update step size is used, so that the filter can converge quickly while ensuring stability.
[0082] Moreover, the above method can make the weight coefficient of the transparent headphone filter adaptively adjusted according to the wearing method of the headphone, and can also make adaptive adjustments according to the input signals of different frequencies, and can also make adaptive adjustments according to the different transmission angles of the input signals, so that the transparent headphone has a better transparent effect and can better meet the needs of users.
[0083] Embodiment 2:
[0084] Based on the foregoing embodiments, the embodiments of the present application provide a device for determining a transparent adaptive filter. The modules included in the device and the units included in the modules can be implemented by a processor in a computer device; of course, they can also be implemented by a specific logic circuit; in the implementation process, the processor can be a central processing unit (CPU, Central Processing Unit), a microprocessor (MPU, Microprocessor Unit), a digital signal processor (DSP, Digital Signal Processing) or a field programmable gate array (FPGA, Field Programmable Gate Array), etc.
[0085] like Figure 4 As shown, a device for determining a transparent adaptive filter includes: a first acquisition module 1, a first determination module 2, a second determination module 3 and a third determination module 4.
[0086] The first acquisition module 1 is used to obtain the preset target path transfer function and the current weight parameters of the filter, and obtain the input signal through the external microphone of the in-ear headphone, and obtain the superposition signal through the internal microphone. The first determination module 2 is used to determine the expected signal according to the input signal and the target path transfer function. The second determination module 3 is used to determine the first error signal according to the expected signal and the superposition signal. The third determination module 4 is used to determine the target weight parameters of the filter according to the first error signal and the current weight parameters.
[0087] Each module in the above-mentioned device for determining a transparent adaptive filter can be implemented in whole or in part by software, hardware, and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of the processor in the device in hardware form, or can be stored in a memory in the processing device in software form, so that the processor can call and execute the operations corresponding to each of the above modules. It should be noted that the division of modules in the embodiment of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation.
[0088] Embodiment 3:
[0089] In a third aspect, an electronic device is provided, comprising a memory, a processor, and a computer program stored in the memory, wherein the processor executes the computer program to implement the steps of any one of the methods described in the first aspect.
[0090] Embodiment 4:
[0091] In a fourth aspect, the present application provides a readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of any one of the methods described in the first aspect.
[0092] Embodiment 5:
[0093] In a fifth aspect, the present application provides a through-ear earphone, comprising: an earphone body and an electronic device as described in the third aspect, wherein the electronic device is connected to the earphone body.
[0094] Those of ordinary skill in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory or optical memory, etc. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM).
[0095] It should be understood that "one embodiment" or "an embodiment" mentioned throughout the specification means that specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, "in one embodiment" or "in an embodiment" appearing throughout the specification does not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It should be understood that in various embodiments of the present application, the size of the sequence number of the above-mentioned processes does not mean the order of execution, and the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application. The above-mentioned sequence numbers of the embodiments of the present application are only for description and do not represent the advantages and disadvantages of the embodiments.
[0096] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or device including the element.
[0097] In the several embodiments provided in the present application, it should be understood that the disclosed devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of the devices or units can be electrical, mechanical or other forms.
[0098] The units described above as separate components may or may not be physically separated, and the components shown as units may or may not be physical units. They may be located in one place or distributed over multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0099] In addition, all functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may be separately used as a unit, or two or more units may be integrated into one unit. The above integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.
[0100] Those skilled in the art can understand that all or part of the steps of the above method embodiments can be completed by hardware related to program instructions, and the above program can be stored in a computer-readable storage medium, and when the program is executed, the steps of the above method embodiments are executed. The above storage medium includes: a mobile storage device, a read-only memory (ROM), a magnetic disk or an optical disk, and other media that can store program codes.
[0101] Alternatively, if the above-mentioned integrated unit of the present application is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the embodiment of the present application can essentially or in other words, the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium and includes a number of instructions for a controller to execute all or part of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROMs, magnetic disks, or optical disks.
[0102] The above is only an implementation method of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A method for determining a transparent adaptive filter, characterized in that: include: Obtaining a preset target path transfer function and current weight parameters of the filter, and obtaining an input signal through an external microphone of the in-ear headphone and a superimposed signal through an internal microphone; determining a desired signal based on the input signal and the target path transfer function; Determine a first error signal according to the expected signal and the superimposed signal; The target weight parameter of the filter is determined according to the first error signal and the current weight parameter.
2. The method according to claim 1, characterized in that The determining of a first error signal according to the expected signal and the superimposed signal comprises: Acquire an input autopower spectrum of the input signal, an expected autopower spectrum of the expected signal, and a cross power spectrum of the input signal and the expected signal; Determining the number of time shift points of the expected signal according to the input autopower spectrum, the expected autopower spectrum and the cross power spectrum; Determine an expected time-shifted signal according to the time-shifted points and the expected signal; A first error signal is determined based on the desired time-shifted signal and the superimposed signal.
3. The method according to claim 1, characterized in that The step of determining the target weight parameter of the filter according to the first error signal and the current weight parameter comprises: Obtaining a preset secondary path estimate and a preset basic update step size; determining a filtered signal of the filter based on the input signal and the secondary path estimate; The target weight parameter is determined according to the filtered signal, the first error signal, the current weight parameter and the basic update step size.
4. The method according to claim 3, characterized in that The step of determining the target weight parameter according to the filtered signal, the first error signal, the current weight parameter and the basic update step size comprises: determining a first relationship between a basic update step size and the filtered signal according to a first error signal; Determine a real-time update step size of the filter according to the first relationship and the basic update step size; The target weight coefficient is determined according to the real-time update step size, the filtered signal, the current weight coefficient and the first error signal.
5. The method according to claim 4, characterized in that The determining the target weight coefficient according to the real-time update step size, the filter signal, the current weight coefficient and the first error signal comprises: Determine a first update formula of the filter according to the current weight information, the first error signal and the filtered signal; Determine a second update formula for the filter according to the first update formula and the real-time update step size; The target weight coefficient is determined according to the second updating formula.
6. The method according to claim 5, characterized in that The second update formula is as follows: Wherein, w(n+1) is the target weight coefficient of the filter, w(n) is the current weight coefficient of the filter, and w(n)≡[w0(n)w1(n-1)…w L-1 (n)] T is the weight vector; w l (n)(l-0,...,L-1) is the l-th coefficient of the filter with a filter length of L, and μ is the update step size. is the real-time update step size, x′(n) is the filtered signal, e′(n) is the first error signal, and δ is a constant.
7. A device for determining a transparent adaptive filter, characterized in that: include: A first acquisition module is used to obtain a preset target path transfer function and a current weight parameter of the filter, and obtain an input signal through an external microphone of the in-ear headset, and obtain a superimposed signal through an internal microphone; A first determination module determines an expected signal according to the input signal and the target path transfer function; A second determination module, configured to determine a first error signal according to the expected signal and the superimposed signal; A third determination module, configured to determine a first error signal according to the expected signal and the superimposed signal; The third determination module is used to determine the target weight parameter of the filter according to the first error signal and the current weight parameter.
8. An electronic device comprising a memory, a processor and a computer program stored in the memory, characterized in that: The processor executes the computer program to implement the steps of the method according to any one of claims 1 to 6.
9. A readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
10. A transparent in-ear headphone, characterized in that: include: An earphone body and an electronic device as claimed in claim 8, wherein the electronic device is connected to the earphone body.
Citation Information
Patent Citations
Filter coefficient setting method and device and electronic equipment
CN115379354A
Filter coefficient setting method and device and electronic equipment
CN115442712A
Self-adaptive noise reduction method, active noise reduction circuit and device, earphone and storage medium
CN115798451A
Active noise reduction earphone and active noise reduction method of wireless earphone
CN118016041A
Method for determining parameter corresponding to earphone mode, and earphone, terminal and system
WO2023197474A1
Cited By
Leakage noise extraction method and device for water supply network
CN120636467A