Audio signal compensation method and device, earphone, and storage medium
By autonomously detecting the user's hearing characteristics and performing system frequency response correction through headphones, the environmental dependence problem of traditional audio signal compensation schemes is solved, and accurate audio signal compensation is achieved in ordinary environments.
Patent Information
- Application Number
- CN202110928243.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Priority Date
- 2021-04-14
- Filing Date
- 2021-08-13
- Publication Date
- 2026-02-27
- Estimated Expiration
- 2041-08-13
AI Technical Summary
Traditional audio signal compensation solutions rely on professional physicians to conduct tests in a quiet room or anechoic chamber, which leads to inaccurate test results and reduces the flexibility and accuracy of audio signal compensation.
The system outputs a corrected audio signal through the speaker in the headphones, obtains the user's hearing test information, determines compensation parameters based on the test information, and compensates the target audio signal to achieve environmentally adaptive system frequency response correction.
It can accurately obtain users' hearing test information without the need for a soundproof room or anechoic chamber, improving the flexibility and accuracy of audio signal compensation.
Smart Images

Figure CN115209292B_ABST
Abstract
Description
[0001] This application claims priority to Chinese Patent Application No. 202110400452.9, filed on April 14, 2021, and entitled "Audio Signal Compensation Method and Device, Earphone, and Storage Medium", the entire contents of which are incorporated herein by reference. TECHNICAL FIELD
[0002] The present application relates to the technical field of audio processing, and in particular to an audio signal compensation method and device, an earphone, and a storage medium. BACKGROUND
[0003] Currently, different users often have different sensitivities to audio signals due to differences in their own hearing characteristics (such as different degrees of hearing impairment, different style preferences, etc.), and therefore, in order to ensure that the user can hear the audio signal, the audio signal output to the user needs to be compensated accordingly. However, it is found in practice that the traditional audio signal compensation scheme often relies on the detection results obtained by professional physicians in a special environment such as a soundproof room or an anechoic chamber for hearing detection of the user, which is difficult to implement. And the detection results obtained by the user himself are easy to be inaccurate, which leads to inaccurate and ineffective audio signal compensation in the subsequent process, and reduces the flexibility and accuracy of audio signal compensation according to the hearing detection results. SUMMARY
[0004] The embodiments of the present application disclose an audio signal compensation method and device, an earphone, and a storage medium, which can more accurately obtain the actual hearing detection information of the user, thereby improving the flexibility and accuracy of audio signal compensation according to the hearing detection results.
[0005] The first aspect of the embodiments of the present application discloses an audio signal compensation method applied to an earphone, wherein the earphone comprises a loudspeaker, and the method comprises:
[0006] performing system frequency response correction on an initial audio signal to obtain a corrected audio signal;
[0007] outputting the corrected audio signal through the loudspeaker;
[0008] obtaining hearing detection information fed back for the corrected audio signal;
[0009] determining a compensation parameter according to the hearing detection information, wherein the compensation parameter is used for compensating a target audio signal to be output.
[0010] The second aspect of the embodiments of the present application discloses an audio signal compensation device applied to an earphone, wherein the earphone comprises a loudspeaker, and the audio signal compensation device comprises:
[0011] a frequency response correction unit, configured to perform system frequency response correction on the initial audio signal to obtain a corrected audio signal;
[0012] an output unit, configured to output the corrected audio signal through the loudspeaker;
[0013] a detection information acquisition unit, configured to acquire hearing detection information fed back by the user in response to the corrected audio signal;
[0014] a compensation unit, configured to determine a compensation parameter according to the hearing detection information, the compensation parameter being used to compensate a target audio signal to be output.
[0015] A third aspect of an embodiment of the present application discloses an earphone, comprising a memory and a processor, the memory storing a computer program, and the computer program, when executed by the processor, causes the processor to implement all or part of steps in any one of the audio signal compensation methods disclosed in the first aspect of the present application.
[0016] A fourth aspect of an embodiment of the present application discloses a computer readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements all or part of steps in any one of the audio signal compensation methods disclosed in the first aspect of the present application.
[0017] Compared with the related art, the embodiments of the present application have the following beneficial effects:
[0018] In the embodiments of the present application, the earphone applying the audio signal compensation method can comprise a loudspeaker and output a detection audio signal through the loudspeaker to implement hearing detection on the user. Specifically, the earphone can first perform system frequency response correction on an initial audio signal to obtain a corrected audio signal, then output the corrected audio signal through the loudspeaker, and acquire hearing detection information fed back by the user in response to the corrected audio signal. On this basis, the earphone can determine a compensation parameter according to the hearing detection information, and the compensation parameter is used to compensate a target audio signal to be output by the loudspeaker. As can be seen, by implementing the embodiments of the present application, the user can conveniently implement detection on the hearing characteristics of the user by means of the earphone, and a proper detection audio signal is obtained by relying on system frequency response correction that is adaptive to the environment, so that a relatively accurate hearing detection result can be acquired without needing a special environment such as a soundproof room or anechoic chamber. Furthermore, the earphone can calculate a corresponding compensation parameter according to the hearing detection result to compensate a target audio signal to be output to the user, so as to ensure that the user can hear the target audio signal that meets the actual needs of the user, thereby enabling the user to more accurately acquire the actual hearing detection information of the user and further improving the flexibility and accuracy of audio signal compensation according to the hearing detection result. BRIEF DESCRIPTION OF DRAWINGS
[0019] To more clearly illustrate the technical solutions in the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. Obviously, the accompanying drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0020] Figure 1A This is a schematic diagram illustrating an application scenario of the audio signal compensation method disclosed in the embodiments of this application;
[0021] Figure 1B This is a schematic diagram illustrating another application scenario of the audio signal compensation method disclosed in the embodiments of this application;
[0022] Figure 2 This is a flowchart illustrating an audio signal compensation method disclosed in an embodiment of this application;
[0023] Figure 3 This is a flowchart illustrating another audio signal compensation method disclosed in an embodiment of this application;
[0024] Figure 4 This is a schematic diagram of the structure of an earphone disclosed in an embodiment of this application;
[0025] Figure 5 This is a schematic diagram illustrating the effect of a system frequency response correction disclosed in an embodiment of this application;
[0026] Figure 6 This is a flowchart illustrating another audio signal compensation method disclosed in the embodiments of this application;
[0027] Figure 7 This is a schematic diagram of the frequency response of a target compensation filter disclosed in an embodiment of this application;
[0028] Figure 8 It is by Figure 7 The diagram shows the effect of the target compensation filter on audio signal compensation.
[0029] Figure 9 This is a modular schematic diagram of an audio signal compensation device disclosed in an embodiment of this application;
[0030] Figure 10 This is a modular schematic diagram of an earphone disclosed in an embodiment of this application. Detailed Implementation
[0031] With reference to the drawings and embodiments disclosed herein, the technical solutions in the embodiments of the present application will be clearly and completely described, obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor are within the scope of protection of the present application.
[0032] It should be noted that the terms "comprising" and "having" and any variations thereof in the embodiments of the present application are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device comprising a series of steps or units does not have to be limited to only those steps or units clearly listed, but can include other steps or units not clearly listed or inherent to the process, method, product or device.
[0033] The embodiments of the present application disclose an audio signal compensation method and device, earphone and storage medium, which can more accurately obtain actual hearing detection information of a user, thereby improving flexibility and accuracy of audio signal compensation according to the hearing detection result.
[0034] The following will be described in detail with reference to the drawings.
[0035] Please refer to Figure 1A and Figure 1B , Figure 1A is an application scenario diagram of the audio signal compensation method disclosed by the embodiments of the present application, Figure 1B is another application scenario diagram of the audio signal compensation method disclosed by the embodiments of the present application. As Figure 1A indicated, the application scenario can include a user 10 and an earphone 20, the user 10 can perform hearing detection through the earphone 20, so that the earphone 20 obtains hearing detection information corresponding to the user 10, and then the corresponding audio signal compensation can be realized according to the hearing detection information, that is, the earphone 20 can compensate the target audio signal to be output in different degrees according to the hearing characteristics of the user 10 (such as different degrees of hearing impairment, different style preferences, etc.), and output the compensated target audio signal, so as to ensure that the user 10 can hear the target audio signal.
[0036] Exemplarily, when hearing detection needs to be performed on the user 10 to perform corresponding audio signal compensation, interaction can be performed with the earphone 20, and a hearing detection instruction is sent to the earphone 20 to trigger the earphone 20 to start hearing detection. Specifically, the hearing detection can be performed by using one or more detection audio signals, that is, the earphone 20 can output the detection audio signal and collect the feedback of the user 10 to the detection audio signal to evaluate the hearing characteristics of the user 10.
[0037] In the embodiment of the present application, the earphone 20 can first perform system frequency response correction on the initial audio signal to obtain a corrected audio signal, and output the corrected audio signal through the loudspeaker (not marked) of the earphone 20. Wherein, the above-mentioned system frequency response correction can eliminate the environmental influence on the audio signal in the transmission process as much as possible, so that the audio signal actually output by the loudspeaker can be restored to the initial audio signal as much as possible after being transmitted and heard by the user 10, thereby improving the fidelity of the audio signal and realizing the environmental adaptive system frequency response correction. On this basis, the earphone 20 can obtain the hearing detection information fed back by the user 10 for the above-mentioned corrected audio signal, and then can determine the compensation parameter according to the hearing detection information, so as to use the compensation parameter to compensate the target audio signal to be output by the above-mentioned loudspeaker.
[0038] Optionally, as shown in the figure, Figure 1B The earphone 20 can also be connected with the terminal device 30, so that when it is necessary to perform hearing detection on the user 10, the terminal device 30 can be interacted with to send a hearing detection instruction to the earphone 20 through the terminal device 30, and trigger the earphone 20 to start hearing detection. Illustratively, the above-mentioned terminal device 30 can include various devices or systems with wireless communication function, such as mobile phone, smart wearable device, vehicle-mounted terminal, tablet computer, PC (Personal Computer, personal computer), PDA (Personal Digital Assistant, personal digital assistant), etc., which are not limited in the embodiment of the present application. It should be noted that when the earphone 20 obtains the hearing detection information fed back by the user 10 for the corrected audio signal, it can be that the earphone 20 obtains the hearing detection information fed back by the user 10 directly through the earphone 20; or the terminal device 30 can obtain the hearing detection information fed back by the user 10, and then the earphone 20 communicates with the terminal device 30 to obtain the above-mentioned hearing detection information sent by the terminal device 30.
[0039] In the related art, in order to realize hearing detection of a user, a professional audiologist can detect the hearing impairment degree (such as the degree of outer hair cell impairment, the degree of inner hair cell impairment, etc.) of the user in a special environment such as a soundproof room or an anechoic chamber, and then design a corresponding compensation model according to the difference in audio signal perception between normal hearing and impaired hearing, and calculate the gain compensation that should be provided at each frequency point. It can be seen that the related art has very high requirements for the hearing detection environment, and it is also relatively difficult to implement. To solve the above problems, the audio signal compensation method disclosed in the embodiments of the present application can help the user to conveniently realize detection of the hearing characteristics of the user by means of the earphone, and determine the appropriate detection audio signal through system frequency response correction that is adaptive to the environment, so as to eliminate the possible environmental influence in the audio signal transmission process as much as possible, thereby realizing relatively accurate hearing detection without the need for a special environment such as a soundproof room or an anechoic chamber. After calculating the corresponding compensation parameters according to the results of the above hearing detection, the earphone can perform corresponding audio signal compensation on the target audio signal to be output to the user, ensuring that the user can hear the target audio signal, so as to more accurately obtain the actual hearing detection information of the user, and further improve the flexibility and accuracy of audio signal compensation according to the hearing detection results.
[0040] Please refer to Figure 2 , Figure 2 is a flowchart of an audio signal compensation method disclosed in an embodiment of the present application. The method can be applied to the earphone described above, and the earphone can include a loudspeaker. As shown in Figure 2 , the audio signal compensation method can include the following steps:
[0041] 202, performing system frequency response correction on the initial audio signal to obtain a corrected audio signal.
[0042] In the embodiments of the present application, in order to perform corresponding audio signal compensation for the hearing characteristics of the user (such as the presence of different degrees of hearing impairment, different style preferences, etc.), the hearing detection information corresponding to the user needs to be obtained first. Therefore, the earphone can output a certain audio signal and collect the feedback of the user for the audio signal, so as to evaluate the hearing characteristics of the user and obtain the corresponding hearing detection information.
[0043] Specifically, the earphone can first determine an initial audio signal. The initial audio signal can include a pure tone signal at a certain frequency point (such as 500 Hz, 1000 Hz, etc.), that is, an audio signal composed of only the audio signal component corresponding to the frequency point, without audio signal components of other frequencies. By using a pure tone signal as the initial audio signal, the hearing sensitivity of the user at the frequency point can be accurately judged through the subsequent hearing detection process, so as to determine the corresponding hearing detection information.
[0044] On this basis, the earphone can obtain a corrected audio signal corresponding to the initial audio signal by performing system frequency response correction on the initial audio signal. The system frequency response correction can eliminate the influence of the audio signal on the audio system as much as possible, so that the corrected audio signal actually output by the earphone can be restored to the initial audio signal as much as possible after being transmitted and heard by the user. It should be noted that the audio system refers to the path through which the audio signal output by the earphone is transmitted between the earphone and the user. Alternatively, the earphone can include a loudspeaker and a feedback microphone, and when the user wears the earphone, the feedback microphone is between the loudspeaker and the user, so that the audio system can be approximately replaced by the path through which the audio signal is transmitted between the loudspeaker and the feedback microphone. By performing the system frequency response correction, the fidelity of the audio system to the audio signal transmission can be improved, and the corrected audio signal after subsequent transmission can be restored to the initial audio signal as much as possible, thereby improving the accuracy and reliability of the hearing detection.
[0045] 204、outputting the corrected audio signal through the loudspeaker.
[0046] Specifically, after obtaining the corrected audio signal, the earphone can convert the corrected audio signal in the form of an electrical signal into corresponding acoustic vibrations through the loudspeaker, so as to output the corrected audio signal to the user, so as to obtain feedback of whether the user hears the corrected audio signal in the subsequent step, and further obtain hearing detection information of the user feedback to the corrected audio signal.
[0047] 206、obtaining hearing detection information of feedback to the corrected audio signal.
[0048] In the embodiment of the present application, when the earphone obtains the hearing detection information of the feedback to the corrected audio signal, it needs to be realized through interaction with the user, that is, to determine the hearing detection result corresponding to the corrected audio signal based on whether the user hears the feedback of the corrected audio signal. The hearing detection information can include subjective judgment information of whether the user hears the corrected audio signal, and can also include the critical sound intensity (i.e. the sound intensity of the corrected audio signal when the user can just hear the corrected audio signal) determined according to the subjective judgment information, the audible sound intensity range, etc.
[0049] In one embodiment, when the user obtains the hearing detection information of the feedback through the earphone, it can be realized by detecting the user operation to the earphone. For example, the user operation to the earphone can include touch operation, voice operation, movement operation, etc.
[0050] For example, when the user hears the corrected audio signal, the user can touch a designated touch point on the earphone, and the earphone can determine the hearing state of the user hearing the corrected audio signal and obtain the corresponding hearing detection information when detecting the touch operation on the designated touch point.
[0051] For another example, when the user hears the corrected audio signal, the user can directly issue a voice instruction of "heard", and when the user does not hear the corrected audio signal, the user can directly issue a voice instruction of "not heard", so that the earphone can analyze the voice instruction detected thereby to determine whether the user hears the corrected audio signal.
[0052] For another example, the user can also move, turn or shake the head in different directions according to different situations of hearing or not hearing the corrected audio signal, so that the earphone can detect the motion state thereof by a sensor to determine the hearing state of the user hearing or not hearing the corrected audio signal. For example, when the user hears the corrected audio signal, the user can lean the head to the left, so that the earphone detects a trend of moving to the left, and when the user does not hear the corrected audio signal, the user can lean the head to the right, so that the earphone detects a trend of moving to the right, and the earphone can determine the hearing detection information of the user feeding back to the corrected audio signal according to the detected moving trend. For another example, when the user hears the corrected audio signal, the user can horizontally turn the head to the left (or to the right), and when the user does not hear the corrected audio signal, the user can horizontally turn the head to the right (or to the left), so that the earphone can determine the hearing detection information of the user feeding back to the corrected audio signal according to the detected motion track. For another example, when the user hears the corrected audio signal, the user can shake the head forward and backward (i.e., nodding), and when the user does not hear the corrected audio signal, the user can shake the head left and right (i.e., shaking), so that the earphone can also determine the hearing detection information of the user feeding back to the corrected audio signal according to the detected motion direction or frequency.
[0053] In another embodiment, when the user also obtains the feedback hearing detection information through a terminal device in communication connection with the earphone, the hearing detection information can also be obtained by obtaining a user operation on the terminal device. For example, the user operation on the terminal device can include a touch operation, a button click operation, etc. When the terminal device detects the user operation, the terminal device can determine the hearing state of the user hearing or not hearing the corrected audio signal according to the user operation and send the hearing state to the earphone. On this basis, the earphone can further obtain the hearing detection information of the user feeding back to the corrected audio signal according to the received hearing state.
[0054] 208、determining a compensation parameter according to the hearing detection information, the compensation parameter being used to compensate a target audio signal to be output by the loudspeaker.
[0055] Specifically, the earphone can invoke the hearing detection information by its built-in processor, and analyze the hearing characteristics of the user (such as the presence of different degrees of hearing impairment, different style preferences, etc.) according to the hearing detection information, to determine the hearing sensitivity of the user to different frequency components of the audio signal. For example, if it is determined according to the hearing detection information that the user has low hearing sensitivity at a certain frequency point, i.e., the user is not easy to hear the audio signal of the frequency component, then subsequent enhancement can be performed on the frequency component of the audio signal; if it is determined according to the hearing detection information that the user has high hearing sensitivity at a certain frequency point, i.e., the user is easily stimulated by the audio signal of the frequency component, then subsequent preservation or weakening can be performed on the frequency component of the audio signal.
[0056] According to the user's hearing characteristics obtained by the above analysis, the earphone can further calculate a corresponding compensation parameter, which can be used to compensate the target audio signal to be output by the loudspeaker, i.e., different frequency components of the target audio signal are compensated respectively according to the user's hearing characteristics. For example, the compensation parameter can include filter parameters (such as tap coefficients used to configure filters, etc.), so that according to the user's hearing characteristics, a corresponding filter can be configured for the frequency component of the target audio signal to be output, to perform compensation filtering. For example, when a specific frequency band of the audio signal needs to be compensated, a bandpass filter or a bandstop filter can be configured to perform compensation filtering; when multiple frequency bands of the audio signal need to be compensated, a cascaded FIR (Finite Impulse Response) filter or an IIR (Infinite Impulse Response) filter can be configured to perform corresponding compensation filtering.
[0057] It can be seen that the audio signal compensation method described in the above embodiments can help the user to conveniently detect the hearing characteristics of the user by means of the earphone, and determine the appropriate detection audio signal through the system frequency response correction adapted to the environment, so as to eliminate the possible environmental influence in the audio signal transmission process as much as possible, thereby realizing relatively accurate hearing detection without the need for a special environment such as a soundproof room or an anechoic chamber, and more accurately obtaining the actual hearing detection information of the user. Furthermore, through corresponding audio signal compensation, the user can hear the target audio signal output by the loudspeaker, thereby further improving the flexibility and accuracy of audio signal compensation according to the hearing detection result.
[0058] Please refer to Figure 3 , Figure 3 is a flow diagram of another audio signal compensation method disclosed in embodiments of the present application. The method can be applied to the earphone described above, which can include a speaker and a feedback microphone. As shown in Figure 3 , the audio signal compensation method can include the following steps:
[0059] 302, output a test audio signal through the speaker.
[0060] In embodiments of the present application, when it is necessary to conduct hearing detection on a user, the earphone can first output a test audio signal through its speaker before outputting an actual detection audio signal. The test audio signal can include a short piece of audio signal, which is used to transmit in the audio system (i.e. the path through which the audio signal output by the earphone is transmitted between the earphone and the user) and is received by the feedback microphone to calculate the system frequency response corresponding to the audio system. It can be understood that the above-mentioned audio system can also be approximately replaced by the path through which the audio signal is transmitted between the speaker and the feedback microphone, since the feedback microphone is between the speaker and the user. By calculating the system frequency response of the audio system, the environmental influence on the transmission of the audio signal in the audio system can be determined, and the system frequency response correction of the initial audio signal can be performed in subsequent steps.
[0061] As an optional implementation, when the earphone outputs a test audio signal through its speaker, the influence of the environmental sound in the environment where the earphone is located can also be considered. If the sound intensity of the environmental sound is large, the sound intensity of the output test audio signal should also be increased to improve the signal-to-noise ratio of the audio signal and avoid interference of the environmental sound on the system frequency response correction.
[0062] Specifically, to evaluate the influence of the environmental sound, as shown in Figure 4 , the above-mentioned earphone can include a feed-forward microphone 43 in addition to the speaker 41 and the feedback microphone 42 arranged in front of the speaker 41. The feed-forward microphone 43 can be arranged behind the speaker 41 (i.e. when the user wears the earphone, the feed-forward microphone is between the speaker and the external environment) to collect the external environmental sound through the feed-forward microphone 43. Exemplarily, the above-mentioned earphone can collect the environmental sound through the feed-forward microphone, and then determine the test sound intensity of the test audio signal output by the speaker according to the environmental sound intensity of the environmental sound, so that when the test audio signal is output through the speaker, the test audio signal with the test sound intensity can be output through the speaker.
[0063] For example, the test audio signal can include a white noise signal, and the test sound intensity of the white noise signal can be positively correlated with the sound intensity of the ambient sound collected by the feed-forward microphone. For example, when the earphone collects the ambient sound through the feed-forward microphone, the test sound intensity of the white noise signal corresponding to the ambient sound can be calculated according to the ambient sound intensity of the ambient sound and a specified positive correlation function, and then the white noise signal with the test sound intensity can be output as the test audio signal through the loudspeaker.
[0064] 304, collecting a receiving audio signal corresponding to the test audio signal through the feedback microphone.
[0065] In the embodiments of the present application, when the earphone outputs the test audio signal through the loudspeaker, the receiving audio signal corresponding to the test audio signal collected by the built-in feedback microphone of the earphone can be obtained immediately. It can be understood that the feedback microphone of the earphone can continuously collect audio signals, so that the receiving audio signal collected by the feedback microphone at a time point near the time stamp (e.g., 0.01 milliseconds later, 0.1 milliseconds later, etc.) of the output of the test audio signal by the loudspeaker can be obtained according to the time stamp. In some embodiments, the feedback microphone of the earphone can also not be continuously turned on, but can be triggered to be turned on by the loudspeaker after the loudspeaker outputs the test audio signal, and the audio signal collected after the feedback microphone is turned on can be used as the receiving audio signal corresponding to the test audio signal. Optionally, for the receiving audio signal collected by the feedback microphone, the earphone can also use the built-in processor to compare the test audio signal output by the loudspeaker with the receiving audio signal, and when the comparison result indicates that the waveform similarity of the test audio signal and the receiving audio signal satisfies a similarity threshold (e.g., 50%, 80%, etc.), the receiving audio signal can be confirmed as the receiving audio signal corresponding to the test audio signal.
[0066] 306, calculating a system correction parameter according to the test audio signal and the receiving audio signal.
[0067] In the embodiments of the present application, the earphone can first calculate the system frequency response of the audio system in which the earphone is located according to the test audio signal and the received audio signal, to determine the environmental influence on the audio signal in the transmission process of the audio system. On this basis, the earphone can further calculate the system correction parameter corresponding to the system frequency response based on the system frequency response. The system correction parameter can include filter parameters (such as tap coefficients for configuring a filter), equalizer parameters (such as tap coefficients and gain coefficients for configuring filters included in an equalizer), and the like, to correct the system frequency response of the audio system to eliminate the environmental influence on the audio signal in the transmission process of the audio system as much as possible.
[0068] For example, when calculating the system correction parameter according to the test audio signal and the received audio signal, the earphone can first perform Fourier transform on the test audio signal and the received audio signal respectively, and then compare the Fourier-transformed received audio signal with the test audio signal to obtain the system frequency response. Specifically, the processor built in the earphone can first perform frame windowing processing on the test audio signal and the received audio signal, that is, divide the macroscopically unstable audio signal into a plurality of audio signal frames with short-time stationarity (such as audio signal frames with a frame length of 10-30 milliseconds), and then perform windowing truncation on the audio signal frames according to a specified window function to obtain each frame of test audio signal and received audio signal. For example, the windowing truncation can be realized by a window function as shown in formula 1:
[0069] Formula 1:
[0070] w(n) = 1, 0 ≤ n ≤ N-1;
[0071] w(n) = 0, otherwise
[0072] where w(n) is a window function, and N is the length of a unit window. The effect of windowing truncation can be realized by convolving the test audio signal or the received audio signal with the window function in the time domain.
[0073] On this basis, a frame of test audio signal or received audio signal obtained after frame windowing can be subjected to short-time Fourier transform by an FFT (Fast Fourier Transform) algorithm or the like, and its expression can be as shown in formula 2:
[0074] Formula 2:
[0075]
[0076] wherein n is a discrete time, ω=2πk / N, k=0, 1,..., N-1 is a continuous frequency, N is a Fourier transform length, and x(m) is an mth frame of audio signals. On this basis, the received audio signals after Fourier transform are compared with the test audio signals, and the system frequency response is obtained, i.e., the system frequency response H(k) can be obtained from the ratio Y(k) / X(k) of the frequency domain received audio signals Y(k) and the frequency domain test audio signals X(k).
[0077] Further, the earphone can calculate target equalizer parameters according to the system frequency response based on a least square criterion, wherein the target equalizer parameters can include tap coefficients, gain coefficients, etc. used for configuring filters included in the target equalizer. The target equalizer configured by the target equalizer parameters can be used to perform equalization correction on the initial audio signals in a subsequent step to obtain corrected audio signals. Optionally, the target equalizer can include an equalizer composed of FIR (Finite Impulse Response) filters, so that a regularized filter, an ideal bandpass filter, etc. can be used, and the target equalizer is designed based on the least square criterion and the target of minimizing equalization error by the regularized filter. Exemplarily, the expression of the response M(k) of the target equalizer in the frequency domain can be as shown in the following formula 3:
[0078] Formula 3:
[0079]
[0080] wherein H(k) is the system frequency response, D(k) can represent a Fourier transform of an ideal bandpass filter response, B(k) can represent a Fourier transform of a regularized filter response, and β can represent a weighting scalar of the regularized filter. By configuring the FIR equalizer, amplitude equalization with a flat amplitude-frequency response as a target and phase equalization with a linear phase as a target can be achieved.
[0081] 308. performing system frequency response correction on the initial audio signals according to the system correction parameters to obtain corrected audio signals.
[0082] wherein step 308 is similar to step 202. It should be noted that when the target equalizer parameters are calculated by the system correction parameter calculation method exemplified in the above embodiments, the earphone can perform equalization correction on the initial audio signals by the target equalizer configured by the target equalizer parameters, and then obtain corrected audio signals. Exemplarily, as shown in formula 4: Figure 5 Figure 5 is a schematic diagram of the effect of system frequency response correction disclosed by the embodiment of the present application, wherein the dotted line represents the system frequency response before system frequency response correction, and the solid line represents the system frequency response after system frequency response correction. As can be seen, by performing the above system frequency response correction, the system frequency response is made more flat and linear in phase, which is conducive to eliminating the environmental influence on the audio signal in the transmission process as much as possible.
[0083] It can be understood that the above system correction parameter can be calculated not only during actual use by the user, but also before the user actually uses it (i.e., before the product is shipped), and stored in the storage module built in the earphone. For example, when the earphone needs to perform system frequency response correction on the initial audio signal to obtain a corrected audio signal for subsequent hearing detection and audio signal compensation, the system correction parameter stored in advance can be obtained from the storage module, and then the initial audio signal for hearing detection can be corrected according to the system correction parameter.
[0084] Specifically, before the earphone is shipped, in order to obtain the above system correction parameter, a corresponding test can be performed in advance, for example, the system correction parameter is calculated according to the method shown in steps 302 to 306. Alternatively, after obtaining the above system correction parameter, the earphone can be calibrated according to the system correction parameter, so that the system calibration can be completed before the earphone is shipped, which is convenient for the user to perform hearing detection and audio signal compensation during actual use of the earphone.
[0085] It should be noted that the above system calibration can include correction of the frequency response difference of each frequency point in the audio system in which the earphone is located, so that the audio signal amplitude of each frequency point (especially each to-be-detected frequency point) can be kept at the same level during subsequent hearing detection, i.e., the reference sound intensity corresponding to each frequency point is equal or close (e.g., within a certain threshold range), which helps to improve the accuracy and reliability of hearing detection; it can also include calibration of the acoustic devices, assembly process, etc. of the earphone itself, so as to reduce the system deviation caused by hardware differences between different earphones. Alternatively, the above two system calibrations can be performed separately or combined, which is not limited in the embodiment of the present application. For example, the first system calibration can be completed before the earphone is shipped, and the second system calibration can be performed during actual use by the user (i.e., by the method shown in steps 302 to 306); the two system calibrations can be completed before the earphone is shipped; or the two system calibrations can be completed during actual use of the earphone by the user.
[0086] 310、output the corrected audio signal through the loudspeaker.
[0087] 312、acquire hearing detection information for correcting audio signal feedback.
[0088] 314、determine compensation parameters according to the hearing detection information, the compensation parameters being used for compensating target audio signals to be output by the loudspeaker.
[0089] The steps 310, 312 and 314 are similar to the steps 204, 206 and 208, and thus are not described herein.
[0090] Optionally, if the compensation parameters are determined before the earphone is shipped (e.g., the compensation parameters are specified in advance for several typical and common hearing detection information according to artificial experience or big data analysis results), the earphone can directly acquire the corresponding compensation parameters and use them to compensate the target audio signals to be output by the loudspeaker.
[0091] It can be seen that the audio signal compensation method described in the above embodiments can more accurately acquire actual hearing detection information of a user, thereby improving flexibility and accuracy of audio signal compensation according to the hearing detection results. In addition, the system frequency response correction is performed in a balanced manner, the amplitude balance with a flat amplitude-frequency response as a target and the phase balance with a linear phase as a target are realized, which is conducive to eliminating as much as possible the environmental influence on the audio signal in the transmission process.
[0092] Please refer to Figure 6 , Figure 6 is a flowchart of another audio signal compensation method disclosed by the embodiments of the present application. The method can be applied to the earphone described above, which can include a loudspeaker, a feedback microphone and a feed-forward microphone. As shown in Figure 6 , the audio signal compensation method can include the following steps:
[0093] 602、in response to a hearing detection instruction, collect ambient sound through the feed-forward microphone.
[0094] The hearing detection instruction can include a hearing detection operation (e.g., a specified touch operation, a voice operation, a movement operation, etc.) directly performed by the user on the earphone, or a hearing detection operation (e.g., a specified touch operation, a button click operation, etc.) performed by the user on a terminal device in communication connection with the earphone. For the latter, the terminal device can also send a corresponding hearing detection instruction to the earphone when detecting the hearing detection operation. On this basis, when the earphone detects the hearing detection operation on itself or receives the hearing detection instruction sent by the terminal device connected thereto, the feed-forward microphone of the earphone can be triggered to collect ambient sound.
[0095] 604、calculate an ambient sound parameter according to the ambient sound.
[0096] Exemplarily, the environmental sound parameter can include various parameters for characterizing the strength of the environmental noise, such as sound intensity, sound energy, sound power, etc. In the embodiments of the present application, after the environmental sound is collected by the feed-forward microphone of the earphone, the environmental sound can be analyzed to calculate the corresponding environmental sound parameter.
[0097] Exemplarily, taking the sound energy as an example, for the environmental sound collected by the feed-forward microphone, the processor built-in the earphone can first perform windowed segmentation on the environmental sound according to the unit window length to obtain at least one frame of environmental sound sub-signal. The window function used for windowed segmentation of the environmental sound can include the rectangular window function shown in the above formula 1, or other forms of window functions, such as triangular window function, Hamming window function, etc. Preferably, in order to reduce the calculation amount before and after windowed segmentation, only the rectangular window function can be used for the above windowed segmentation step.
[0098] On this basis, the processor built-in the earphone can calculate the short-time average energy of each frame of environmental sound sub-signal respectively, and perform smoothing processing on the calculated short-time average energy to obtain the environmental sound parameter corresponding to the environmental sound. Exemplarily, when calculating the short-time average energy of each frame of environmental sound sub-signal respectively, the calculation can be performed in the manner shown in the following formula 4:
[0099] Formula 4:
[0100]
[0101] wherein, E n represents the short-time average energy of the nth frame (or nth time point) of environmental sound sub-signal, n is the discrete time, w(n-m) is the time shift representation of the window function w(n), x(m) represents each frame of environmental sound sub-signal, and N is the unit window length. By calculating the short-time average energy of the environmental sound sub-signal, the strength of a frame of environmental sound sub-signal can be quickly determined, so as to reduce the calculation amount of the environmental sound parameter related calculation in the subsequent step. Further, after obtaining the short-time average energy of each frame of environmental sound sub-signal, the smoothing processing can be performed in the manner shown in the following formula 5:
[0102] Formula 5:
[0103] E n (m) = a E n (m-1) + (1-a) E n (m), 0 < a < 1
[0104] wherein, E n(m) is the smoothed audio signal energy, and a is the coefficient for performing the above exponential smoothing. The processor built in the earphone can determine the smoothed audio signal energy E n (m) determining an ambient sound parameter corresponding to the ambient sound.
[0105] 606、If the ambient sound parameter is lower than the ambient sound threshold, determining a test sound intensity of the test audio signal output by the loudspeaker according to the sound intensity of the ambient sound.
[0106] Exemplarily, the earphone can compare the ambient sound parameter with an ambient sound threshold (such as 5dB, 10dB, etc.), and can determine whether to continue to perform subsequent steps according to the comparison result. Specifically, if the ambient sound parameter is lower than the ambient sound threshold, it indicates that the ambient sound in the environment where the earphone is located has less influence, and the subsequent hearing detection and other steps can be continued to be performed. If the ambient sound parameter is higher than the ambient sound threshold, it indicates that the ambient sound in the environment where the earphone is located has greater influence, and the subsequent steps can be discontinued to be performed. Optionally, when it is judged that the ambient sound parameter is higher than the ambient sound threshold, the earphone can output corresponding prompt information through the loudspeaker to remind the user to replace to an environment with less ambient sound (especially less environmental noise) to reduce the influence of the ambient sound on the subsequent hearing detection and other steps, and ensure the accuracy and reliability of the audio signal compensation according to the hearing detection result. Exemplarily, if the ambient sound parameter is higher than the ambient sound threshold, the earphone can output first prompt information for guiding the user to move to a quiet environment. On this basis, the earphone can re-respond to the hearing detection instruction, collect new ambient sound through the front feed microphone, and calculate a new ambient sound parameter for continuing to compare with the ambient sound threshold. The above steps can be repeatedly performed until the calculated ambient sound parameter is not higher than the ambient sound threshold.
[0107] In the embodiments of the present application, when it is judged that the ambient sound parameter is lower than the ambient sound threshold, the earphone can further determine the test sound intensity of the test audio signal subsequently output by the loudspeaker. Exemplarily, the test audio signal can include a white noise signal, and the test sound intensity of the white noise signal can have a positive correlation with the sound intensity of the ambient sound collected by the front feed microphone. On this basis, the earphone can calculate the test sound intensity of the white noise signal corresponding to the ambient sound according to the sound intensity of the ambient sound and a specified positive correlation function, so as to output the white noise signal with the test sound intensity in the subsequent step, so as to improve the signal-to-noise ratio of the audio signal and avoid the interference of the ambient sound on the system frequency response correction.
[0108] 608、Outputting the test audio signal with the test sound intensity through the loudspeaker.
[0109] Among them, step 608 is similar to step 302 described above, and will not be repeated here.
[0110] 610、acquire a received audio signal corresponding to the test audio signal through a feedback microphone.
[0111] 612、calculate a system correction parameter according to the test audio signal and the received audio signal.
[0112] 614、perform system frequency response correction on the initial audio signal according to the system correction parameter to obtain a corrected audio signal.
[0113] The steps 610, 612 and 614 are similar to the steps 304, 306 and 308 described above, and will not be described here.
[0114] As an optional implementation, the earphone can start the ANC function when acquiring the ambient sound through the step 602, so as to perform the subsequent hearing detection and audio signal compensation in the noise reduction environment. For example, when the earphone with the started ANC function acquires the ambient sound through the feed-forward microphone in response to the hearing detection instruction, the earphone can determine the reverse audio signal corresponding to the ambient sound according to the ambient sound, and then output the reverse audio signal through the loudspeaker to cancel the ambient sound and form an active noise reduction environment. On this basis, the earphone can perform system frequency response correction on the initial audio signal in the active noise reduction environment to obtain the corrected audio signal, and then output the corrected audio signal in the active noise reduction environment to reduce the interference of the ambient noise on the hearing detection process.
[0115] Optionally, after starting the ANC function, the earphone can further acquire the residual noise signal (i.e. the residual ambient sound) through the feedback microphone, and output the corresponding prompt information through the loudspeaker when the residual noise signal is still large, to remind the user to change to an environment with smaller ambient sound (especially smaller ambient noise), so as to further reduce the influence of the ambient sound on the subsequent hearing detection and other steps, and ensure the accuracy and reliability of the audio signal compensation according to the hearing detection result. For example, the earphone can calculate a residual noise parameter according to the residual noise signal, and output the second prompt information if the residual noise parameter is higher than a residual noise threshold, the second prompt information being used to guide the user to move to a quiet environment. On this basis, the earphone can re-respond to the hearing detection instruction, acquire the ambient sound through the feed-forward microphone, and continue the corresponding noise reduction processing until the residual noise parameter acquired through the feedback microphone is not higher than the residual noise threshold.
[0116] 616、output the corrected audio signal through the loudspeaker.
[0117] Step 616 is similar to step 204 described above, and thus is not described again.
[0118] 618. Obtain hearing detection information fed back for the corrected audio signal.
[0119] Step 618 is similar to step 206 described above. It should be noted that in some embodiments, if there are N frequency points to be detected (such as 500 Hz frequency point, 1000 Hz frequency point, 2000 Hz frequency point, etc.) in the hearing detection process, the earphone can obtain N pieces of hearing detection information corresponding to each frequency point to be detected. The N pieces of hearing detection information correspond to the N frequency points to be detected one by one, where N is a positive integer greater than or equal to 1.
[0120] For example, before the earphone performs system frequency response correction on the initial audio signal according to the system correction parameter, the earphone can first set N frequency points to be detected, and for each frequency point to be detected, generate N initial audio signals corresponding to the N frequency points to be detected one by one. On this basis, when the earphone performs system frequency response correction on each initial audio signal according to the system correction parameter to obtain N corrected audio signals corresponding to each initial audio signal, the earphone can obtain N pieces of hearing detection information fed back for each corrected audio signal. It can be understood that each frequency point to be detected can cover a certain frequency range, so as to comprehensively detect the hearing characteristics (i.e., sensitivity to audio signals of different frequency bands) of the user in different frequency bands, and also facilitate reducing the number of detections and saving detection time. For example, the frequency points to be detected can include 500 Hz, 1000 Hz, 2000 Hz, etc. low frequency points, and can also include 4000 Hz, 6000 Hz, 8000 Hz, etc. high frequency points.
[0121] In an embodiment, after generating the N initial audio signals, the earphone can further determine a reference sound intensity corresponding to each to-be-detected frequency point, and output a corrected audio signal with the corresponding reference sound intensity through the speaker according to the reference sound intensity corresponding to each to-be-detected frequency point, to obtain N hearing detection information fed back for each corrected audio signal. The reference sound intensity can be determined according to relevant medical standards, or specified according to experimental experience of hearing detection, so that the corrected audio signal can be output as close as possible to the critical sound intensity that the user can hear, to reduce the number of subsequent volume adjustments and improve the efficiency of hearing detection. For example, after determining the to-be-detected frequency point, the earphone can obtain the reference sound intensity corresponding to the to-be-detected frequency point by looking up a table. The reference sound intensity can include a sound pressure level (SPL). For example, for a to-be-detected frequency point of 500 Hz, the reference sound intensity can be determined to be 11.50 dB SPL by looking up a table; for a to-be-detected frequency point of 4000 Hz, the reference sound intensity can be determined to be 9.50 dB SPL by looking up a table, and so on.
[0122] Further, when the earphone outputs the corrected audio signal at a certain sound intensity (for example, the reference sound intensity), the earphone can gradually increase the sound intensity to the required sound intensity from low to high. For example, when the earphone needs to play a corrected audio signal corresponding to a to-be-detected frequency point through the speaker, if the reference sound intensity corresponding to the to-be-detected frequency point is x dB SPL, the earphone can first output a pure tone signal at a sound intensity lower than x dB SPL on the to-be-detected frequency point, and gradually increase the sound intensity to x dB SPL, so that the process of outputting the corrected audio signal is more natural and smooth, and the user's auditory experience is improved.
[0123] In an embodiment, when the earphone obtains the hearing detection information fed back for each corrected audio signal, the earphone can repeatedly adjust the sound intensity of the output corrected audio signal according to the hearing state of whether the user can hear the corrected audio signal, until the critical sound intensity at which the user can just hear the corrected audio signal is obtained.
[0124] Exemplarily, the earphone can first acquire a hearing state of feedback of the corrected audio signal corresponding to a first frequency point, where the first frequency point can be any one of the N to-be-detected frequency points. Then, the earphone can adjust the first sound intensity of the corrected audio signal according to the hearing state to determine a sound intensity threshold corresponding to the first frequency point, which is a critical sound intensity at which the user can hear the corrected audio signal. Specifically, if the hearing state indicates that the first sound intensity of the corrected audio signal does not meet a critical condition, the earphone can adjust the sound intensity of the corrected audio signal, output the adjusted corrected audio signal through the loudspeaker, and re-execute the step of acquiring the hearing state of feedback of the corrected audio signal corresponding to the first frequency point until the first sound intensity of the corrected audio signal obtained meets the critical condition. On this basis, the earphone can determine the first sound intensity of the corrected audio signal meeting the critical condition (i.e., the sound intensity threshold) as the hearing detection information corresponding to the first frequency point. The critical condition can refer to a situation in which the user can just hear the corrected audio signal.
[0125] Specifically, when adjusting the sound intensity of the corrected audio signal, if the hearing state indicates that the first sound intensity of the corrected audio signal does not belong to a hearable range, the earphone can increase the first sound intensity of the corrected audio signal by a first adjustment parameter; if the hearing state indicates that the first sound intensity of the corrected audio signal belongs to the hearable range, the earphone can decrease the first sound intensity of the corrected audio signal by a second adjustment parameter. Optionally, the first adjustment parameter can be greater than the second adjustment parameter. For example, if the first adjustment parameter is 24 dB and the second adjustment parameter is 8 dB, when the user feedbacks that the corrected audio signal cannot be heard, the sound intensity of the corrected audio signal can be increased by 24 dB; when the user feedbacks that the corrected audio signal can be heard, the sound intensity of the corrected audio signal can be decreased by 8 dB. Through repeated increase and decrease adjustment, the sound intensity range at which the user can hear the corrected audio signal at the frequency point can be finally narrowed to within ±8 dB of the sound intensity threshold at which the user can just hear the corrected audio signal, and thus the first sound intensity of the corrected audio signal meeting the critical condition or the sound intensity range can be determined as the hearing detection information of the user feedback of the corrected audio signal.
[0126] Further optionally, the sizes of the first adjustment parameter and the second adjustment parameter can be in a negative correlation with the number of times of adjusting the first sound intensity, that is, as the number of times of repeatedly adjusting the first sound intensity increases, the value of the first adjustment parameter or the second adjustment parameter used each time can decrease.
[0127] Exemplarily, the value of the first adjustment parameter or the second adjustment parameter employed each time of adjustment can be 1 / 2, 1 / 3, etc. of the value employed last time of adjustment, so as to gradually approach the sound intensity threshold at which the user can just hear the corrected audio signal. Specifically, the first sound intensity of the corrected audio signal can be represented by a gain when the earphone outputs the corrected audio signal, the reference sound intensity employed first time of output can be regarded as a reference gain (set as x dB SPL), and a corresponding upper limit gain PU and lower limit gain PD can be set. If the hearing status fed back by the user indicates that the user can hear the corrected audio signal under the current gain (the reference gain x dB SPL employed first time of output), the earphone can reduce the gain by PD / 2 t dB SPL based on the current gain, and output the corrected audio signal again according to the reduced gain; if the hearing status fed back by the user indicates that the user cannot hear the corrected audio signal, the earphone can increase the gain by PU / 2 t dB SPL based on the current gain, and output the corrected audio signal again according to the increased gain. Wherein, t represents the number of times of gain adjustment of the earphone, i.e. the number of times of interactive adjustment of the first sound intensity of the corrected audio signal output by the user. On this basis, since the method of halving adjustment of the gain is employed, the user can quickly determine the sound intensity threshold at which the user can hear the corrected audio signal at each to-be-detected frequency point through a limited number of interactive adjustments, so as to determine it as the hearing detection information fed back by the user for the corrected audio signal, and greatly improve the efficiency of hearing detection.
[0128] Optionally, the earphone can output the corrected audio signal actually based on the gain variation Un t of each time of adjustment, i.e. Un t = PD / 2 t or Un t = PU / 2 t , and the total gain Tn actually output can be represented as: Tn = P0 + Un + Cn. Wherein, P0 is the digital reference gain of the earphone; Un = ∑Un t may vary according to the number of interactive adjustments; and Cn is a constant.
[0129] By implementing the above method, hearing detection can be realized without the need of a special environment such as a soundproof room or an anechoic chamber through simple interactive operation, and a relatively accurate hearing detection result can be obtained, which is conducive to improving the flexibility and convenience of audio signal compensation according to the hearing detection result.
[0130] 620, determining a compensation level matched with the hearing detection information according to the hearing detection information.
[0131] In the embodiments of the present application, according to the hearing detection information, the earphone can determine a compensation level according to the hearing characteristics of the corresponding user, so as to determine the compensation level matched with the hearing detection information. It can be understood that for different compensation levels, the compensation degree of the earphone for audio signal compensation can be different. For example, in some embodiments, when the hearing detection information indicates that the hearing impairment of the user is large, the compensation level matched with the hearing detection information can be determined as a higher compensation level accordingly, so that a larger gain coefficient, a smaller quality factor, etc. can be provided when the target audio signal to be output is compensated subsequently. In another embodiment, when the hearing detection information indicates that the hearing impairment of the user is small, a lower compensation level can be determined accordingly, so that a smaller gain coefficient, a larger quality factor, etc. can be provided when the target audio signal to be output is compensated subsequently.
[0132] 622, based on the compensation level, the compensation filter parameter corresponding to the hearing detection information is calculated.
[0133] For example, the compensation filter parameter can include the gain coefficient Gain value, the quality factor Q value, etc. of the corresponding target compensation filter.
[0134] In an embodiment, different compensation levels can correspond to different compensation filter parameter calculation methods respectively, so that when the earphone determines the compensation level matched with the hearing detection information, the parameter calculation method corresponding to the compensation level can be called to calculate the compensation filter parameter corresponding to the hearing detection information.
[0135] In another embodiment, different compensation levels can correspond to different compensation filter parameters respectively, and the correspondence and the compensation filter parameter can be stored in the memory built in the earphone, so that when the earphone determines the compensation level matched with the hearing detection information, the compensation filter parameter corresponding to the compensation level can be directly called.
[0136] Optionally, the target compensation filter configured by the compensation filter parameter can include an IIR (infinite impulse response) filter, and for hearing detection information at a certain frequency point, the corresponding audio signal compensation can be realized by an IIR filter. For example, when a second-order IIR filter is used as the target compensation filter, the second-order IIR filter can be represented by the difference equation shown in formula 6 as follows:
[0137] Formula 6:
[0138]
[0139] wherein a0=1+ a / A, a1=-2cos(w0), a2=1-a / A, b0=1+aA, b1=-2cos(w0), b2=1-aA; further, w0=2pfo / f, A=10, a=sin(w0) / (2Q), wherein f0is a center frequency of the compensation filter, f is a sampling rate of the target audio signal to be output, Gain is a gain coefficient of the compensation filter, and Q is a quality factor of the compensation filter. s , A=10 Gain / 40 , a=sin(w0) / (2Q), wherein f0is a center frequency of the compensation filter, f is a sampling rate of the target audio signal to be output, Gain is a gain coefficient of the compensation filter, and Q is a quality factor of the compensation filter. s Optionally, different second-order IIR filters can be selected for different frequency points for compensation. For example, the second-order IIR filter can include a low shelf filter, a high shelf filter, a peaking filter, etc., which are not limited in the embodiments of the present application. For example, a low shelf filter can be used for a low frequency point such as 500 Hz, and a peaking filter can be used for a specific high frequency point such as 8000 Hz.
[0140] 624, configuring a target compensation filter based on the compensation filter parameters, the target compensation filter being used for filtering and compensating the target audio signal.
[0141] In the embodiments of the present application, the earphone can obtain a corresponding target compensation filter based on the compensation filter parameters. For example, when the earphone obtains the hearing detection information, the earphone can determine the center frequency f0of the target compensation filter according to the frequency point corresponding to the hearing detection information, and the sampling rate f of the target audio signal to be output by the loudspeaker. s On this basis, when the earphone determines the matching compensation level according to the hearing detection information, the earphone can further obtain the gain coefficient Gain and the quality factor Q of the target compensation filter corresponding to the compensation level, so as to configure a corresponding target compensation filter based on the compensation filter parameters, which is used for filtering and compensating the target audio signal to be output by the loudspeaker.
[0142] For example, referring to FIGS. 1 and 2, Figure 7 and Figure 8 the frequency response of the target compensation filter configured based on the compensation filter parameters can be as shown in FIG. 3, and the effect of compensating the target audio signal to be output by the earphone using the target compensation filter can be as shown in FIG. 4, wherein, Figure 7 Figure 8 Figure 8 The dashed line in FIG. 6 represents the system frequency response before the filter compensation, and the solid line represents the system frequency response after the filter compensation. As can be seen, the compensation at the frequency point A is small, and accordingly, the filter compensation effect near the frequency point A is not obvious. Figure 7 The compensation at the frequency point B is large, and accordingly, the filter compensation near the frequency point B is obvious. Figure 8 The compensation at the frequency point B is large, and accordingly, the filter compensation near the frequency point B is obvious. Figure 7 The compensation at the frequency point B is large, and accordingly, the filter compensation near the frequency point B is obvious. Figure 8 The compensation at the frequency point B is large, and accordingly, the filter compensation near the frequency point B is obvious.
[0143] As an optional implementation, for the case where there are multiple to-be-detected frequency points in the hearing detection process, the earphone can first obtain hearing detection information at each to-be-detected frequency point, and then can calculate multiple sets of compensation filter parameters corresponding to the above hearing detection information, and obtain multiple target compensation filters from the multiple sets of compensation filter parameters. For example, if there are M to-be-detected frequency points, the earphone can configure M target compensation filters according to the compensation filter parameters corresponding to each to-be-detected frequency point, and the M target compensation filters correspond one-to-one to the M to-be-detected frequency points, where M is a positive integer greater than or equal to 1. On this basis, the earphone can cascade the M target compensation filters, so that the M target compensation filters can jointly filter and compensate the target audio signal to be output.
[0144] As another optional implementation, the above filter compensation parameter can include a gain coefficient, and when the earphone configures a target compensation filter for different frequency points, it can determine different gain coefficients for each frequency point, and then configure a target compensation filter for each frequency point according to the gain coefficient, to achieve nonlinear gain compensation. For example, if there are P to-be-detected frequency points (P is a positive integer greater than or equal to 1), the earphone can determine a gain coefficient corresponding to the compensation level of each to-be-detected frequency point according to the compensation level of each to-be-detected frequency point. Wherein, for different to-be-detected frequency points, the gain coefficient corresponding to the same compensation level can be the same or different. On this basis, if the second frequency point is any frequency point in the P to-be-detected frequency points, the earphone can configure a target compensation filter corresponding to the second frequency point according to the gain coefficient corresponding to the second frequency point, and the target compensation filter is used to perform gain compensation on the signal component corresponding to the second frequency point in the target audio signal to be output according to the gain coefficient corresponding to the second frequency point. By implementing the above method, each frequency component (or signal component) in the target audio signal can be compensated accordingly, which helps to improve the flexibility of compensating the target audio signal.
[0145] Optionally, according to the hearing detection information fed back by the user, the earphone can also adjust the gain coefficients corresponding to different frequency points based on the difference in sensitivity of the user to audio signals of different frequencies. For example, the earphone can set the gain coefficient corresponding to the frequency point with better user hearing characteristics (i.e., higher user sensitivity) as an attenuative gain coefficient, such as taking a negative value, subtracting a specified gain adjustment coefficient, etc.; at the same time, it can also set the gain coefficient corresponding to the frequency point with poor user hearing characteristics (i.e., lower user sensitivity) as an enhancing gain coefficient, such as taking a positive value, adding a specified gain adjustment coefficient, etc. Thus, the earphone can not only flexibly adjust the target audio signal to be output, but also achieve overall audio signal processing, so that the compensated system frequency response curve is smoother and the sound quality is more comfortable. In some embodiments, even if the hearing detection information fed back by the user indicates that the user's sensitivity to audio signals of different frequencies is similar or the same, the earphone can still set a default gain coefficient to configure a target compensation filter based on the default gain coefficient to compensate the target audio signal to be output, so that the user can feel the effect of optimized compensation and improve the user experience.
[0146] In some embodiments, the earphone can also pre-process the above-mentioned hearing detection information by corresponding weighting for different frequency points, so that when the gain coefficient corresponding to each frequency point is determined based on the hearing detection information, similar effects to adjusting the gain coefficient can be achieved.
[0147] In other embodiments, if the gain coefficient corresponding to one or a plurality of consecutive frequency points is too large (e.g., greater than a specified gain threshold), the earphone can further determine an attenuation coefficient matched with the gain coefficient to configure a target compensation filter corresponding to the one or more frequency points according to the gain coefficient and the attenuation coefficient. Wherein, adding the above-mentioned attenuation coefficient is equivalent to connecting a corresponding attenuation filter (such as LowShelfFilter, HighShelf Filter, etc.) after the compensation filter configured by the above-mentioned gain coefficient, so as to avoid the overall gain of the target compensation filter from overflowing unexpectedly, and ensure the reliability of compensating the target audio signal.
[0148] In still other embodiments, after determining the gain coefficient corresponding to a certain frequency point, the earphone can further determine the gain coefficients corresponding to a plurality of frequency points adjacent to the frequency point. Wherein, the gain coefficient corresponding relationship of adjacent frequency points can be obtained by a specified function relationship operation, or can be obtained based on a large amount of data training, so as to facilitate reducing the detection times and saving the detection time.
[0149] As another optional implementation, the earphone can also analyze the historical audio output by the earphone, or trigger the terminal device connected with the earphone to analyze the historical audio output by the earphone, to obtain a target audio style matched with the user. Illustratively, the target audio style can include a user's favorite audio style, such as pure music, metal, rock, etc. On this basis, the earphone can determine a style adjustment parameter corresponding to the target audio style according to the target audio style, and further adjust the above-mentioned compensation filter parameter according to the style adjustment parameter, to obtain a new target compensation filter through the adjusted compensation filter parameter configuration. Through the implementation of the above-mentioned method, the corresponding compensation filtering can be performed based on the target audio style matched with the user, so that personalized sound compensation can be realized, and the flexibility of performing audio signal compensation is further improved. Optionally, the earphone can also determine the target audio style matched with the user according to the user's age, occupation, work and rest habits, etc., and then the above-mentioned steps of determining the style adjustment parameter corresponding to the target audio style and further adjusting the above-mentioned compensation filter parameter according to the style adjustment parameter can be performed, so that the pertinence and adaptability of audio signal compensation can be further improved, and the effect of compensating the target audio signal is improved.
[0150] It can be seen that the audio signal compensation method described in the above-mentioned embodiments can more accurately obtain the actual hearing detection information of the user, thereby improving the flexibility and accuracy of audio signal compensation according to the hearing detection result. In addition, by means of simple interactive operation, hearing detection can be realized without the need for a special environment such as a soundproof room or anechoic chamber, and a relatively accurate hearing detection result can be obtained, which is conducive to improving the flexibility and convenience of audio signal compensation according to the hearing detection result. In addition, through the filtering compensation method, the target audio signal to be output can be effectively compensated in real time, further improving the flexibility and accuracy of audio signal compensation according to the hearing detection result.
[0151] Please refer to Figure 9 , Figure 9 is a modular schematic diagram of an audio signal compensation device disclosed by the embodiments of the present application. The audio signal compensation device can be applied to the above-mentioned earphone, and the earphone can include a loudspeaker, a feedback microphone and a feed-forward microphone. As shown in Figure 9 , the audio signal compensation device can include a frequency response correction unit 901, an output unit 902, a detection information acquisition unit 903 and a compensation unit 904, wherein:
[0152] The frequency response correction unit 901 is configured to perform system frequency response correction on the initial audio signal to obtain a corrected audio signal.
[0153] The output unit 902 is configured to output the corrected audio signal through the loudspeaker.
[0154] The detection information acquisition unit 903 is configured to acquire hearing detection information for correcting the audio signal feedback;
[0155] The compensation unit 904 is configured to determine a compensation parameter according to the hearing detection information, the compensation parameter being used for compensating a target audio signal to be output.
[0156] In an embodiment, the audio signal compensation apparatus can further include a receiving unit and a calculation unit, which are not shown in the figure, wherein:
[0157] The output unit 902 can also be configured to output the test audio signal through the loudspeaker before the frequency response correction unit 901 performs system frequency response correction on the initial audio signal to obtain the corrected audio signal.
[0158] The receiving unit is configured to collect a received audio signal corresponding to the test audio signal through the feedback microphone.
[0159] The calculation unit is configured to calculate a system correction parameter according to the test audio signal and the received audio signal.
[0160] The frequency response correction unit 901 can be specifically configured to perform system frequency response correction on the initial audio signal according to the system correction parameter to obtain the corrected audio signal.
[0161] In an embodiment, the audio signal compensation apparatus can further include a determination unit, which is not shown in the figure, wherein:
[0162] The receiving unit can also be configured to collect the ambient sound through the feedforward microphone before the output unit 902 outputs the test audio signal through the loudspeaker.
[0163] The determination unit is configured to determine a test sound intensity at which the loudspeaker outputs the test audio signal according to an ambient sound intensity of the ambient sound.
[0164] The output unit 902 can be specifically configured to output the test audio signal with the test sound intensity through the loudspeaker.
[0165] For example, the test audio signal can include a white noise signal, and the test sound intensity of the white noise signal can be in a positive correlation with the ambient sound intensity of the ambient sound collected by the feedforward microphone.
[0166] In an embodiment, the system correction parameter can include a target equalizer parameter, and the calculation unit can be specifically configured to perform Fourier transform on the test audio signal and the received audio signal respectively; compare the received audio signal after Fourier transform with the test audio signal to obtain a system frequency response; and calculate the target equalizer parameter according to the system frequency response based on a least square criterion.
[0167] The frequency response correction unit 901 can specifically perform equalization correction on the initial audio signal by a target equalizer configured by the target equalizer parameter to obtain the corrected audio signal.
[0168] Exemplarily, the target equalizer can include an equalizer composed of a finite-length unit impulse response (FIR) filter.
[0169] In an embodiment, the receiving unit can also be configured to, in response to the hearing detection instruction, collect the ambient sound through the feed-forward microphone before the frequency response correction unit 901 performs system frequency response correction on the initial audio signal to obtain the corrected audio signal.
[0170] The computing unit can also be configured to calculate an ambient sound parameter based on the ambient sound, and trigger the frequency response correction unit 901 to perform the step of performing system frequency response correction on the initial audio signal to obtain the corrected audio signal if the ambient sound parameter is lower than an ambient sound threshold.
[0171] The computing unit can specifically perform windowed segmentation on the ambient sound according to a unit window length to obtain at least one frame of ambient sound sub-signal, calculate the short-time average energy of each frame of ambient sound sub-signal respectively, and perform smoothing processing on the short-time average energy of each frame of ambient sound sub-signal to obtain the ambient sound parameter corresponding to the ambient sound.
[0172] In an embodiment, the audio signal compensation device can further include a setting unit not shown in the figure, wherein:
[0173] The setting unit is configured to set N frequency points to be detected, and generate N initial audio signals corresponding to each frequency point to be detected respectively, the N initial audio signals corresponding to the N frequency points to be detected one by one, wherein N is a positive integer greater than or equal to 1.
[0174] The determining unit can also be configured to determine the reference sound intensity corresponding to each frequency point to be detected respectively.
[0175] The output unit 902 can specifically be configured to output the corrected audio signal with the corresponding reference sound intensity through the loudspeaker according to the reference sound intensity corresponding to each frequency point to be detected respectively.
[0176] In an embodiment, the detection information obtaining unit 903 can be specifically configured to obtain a hearing state corresponding to the feedback of the corrected audio signal at the first frequency point; adjust the first sound intensity of the corrected audio signal according to the hearing state to determine a sound intensity threshold corresponding to the first frequency point, the sound intensity threshold being a critical sound intensity at which the user can hear the corrected audio signal; and take the sound intensity threshold as the hearing detection information corresponding to the feedback of the corrected audio signal at the first frequency point.
[0177] If the hearing state indicates that the first sound intensity of the corrected audio signal is not within the audible range, the first sound intensity of the corrected audio signal can be increased by a first adjustment parameter; if the hearing state indicates that the first sound intensity of the corrected audio signal is within the audible range, the first sound intensity of the corrected audio signal can be decreased by a second adjustment parameter, the first adjustment parameter being greater than the second adjustment parameter.
[0178] In an embodiment, the compensation parameter can include a compensation filter parameter, and the compensation unit 904 can be specifically configured to determine a compensation level matched with the hearing detection information according to the hearing detection information; calculate a compensation filter parameter corresponding to the hearing detection information based on the compensation level; and configure a target compensation filter based on the compensation filter parameter to filter and compensate the target audio signal.
[0179] For example, the target compensation filter can include an infinite-length unit impulse response (IIR) filter.
[0180] In an embodiment, if there are M frequency points to be detected, the compensation unit 904 can configure M target compensation filters corresponding to the M frequency points to be detected according to the compensation filter parameters corresponding to each of the M frequency points to be detected, the M target compensation filters corresponding one-to-one to the M frequency points to be detected, where M is a positive integer greater than or equal to 1; and then, the M target compensation filters can be cascaded.
[0181] In an embodiment, the compensation unit 904 can be further configured to determine a style adjustment parameter corresponding to the target audio style according to the target audio style, adjust the compensation filter parameter according to the style adjustment parameter, and configure the target compensation filter based on the adjusted compensation filter parameter.
[0182] It can be seen that the audio signal compensation device described in the above embodiments can help the user to conveniently detect the hearing characteristics of the user by means of the earphone, and determine the appropriate detection audio signal through the environmental self-adaptive system frequency response correction, so as to eliminate the environmental influence that may occur in the audio signal transmission process as much as possible, thereby realizing relatively accurate hearing detection without the need of a special environment such as a soundproof room or an anechoic chamber, and more accurately obtaining the actual hearing detection information of the user. Further, through the corresponding audio signal compensation, it can be ensured that the user can hear the target audio signal output by the loudspeaker, thereby further improving the flexibility and accuracy of the audio signal compensation according to the hearing detection result.
[0183] Please refer to Figure 10 , Figure 10 is a modular schematic diagram of an earphone disclosed by the embodiments of the present application. As shown in Figure 10 , the earphone can include:
[0184] a memory 1001 storing executable program codes;
[0185] a processor 1002 coupled with the memory 1001;
[0186] The processor 1002 calls the executable program codes stored in the memory 1001, and can execute all or part of the steps in any of the audio signal compensation methods described in the above embodiments.
[0187] In addition, the embodiments of the present application further disclose a computer readable storage medium storing a computer program for electronic data exchange, wherein the computer program enables a computer to execute all or part of the steps in any of the audio signal compensation methods described in the above embodiments.
[0188] In addition, the embodiments of the present application further disclose a computer program product, which enables a computer to execute all or part of the steps in any of the audio signal compensation methods described in the above embodiments when the computer program product runs on the computer.
[0189] Those skilled in the art can understand that all or part of the steps of various methods in the above embodiments can be completed by instructing the relevant hardware through a program, and the program can be stored in a computer readable storage medium, including Read-Only Memory (ROM), Random Access Memory (RAM), Programmable Read-Only Memory (PROM), Erasable Programmable Read-Only Memory (EPROM), One-time Programmable Read-Only Memory (OTPROM), Electrically-Erasable Programmable Read-Only Memory (EEPROM), Compact Disc Read-Only Memory (CD-ROM) or other optical disk storage, magnetic disk storage, magnetic tape storage, or any other medium that can be used to carry or store data in a computer readable manner.
[0190] The above describes in detail the audio signal compensation method and device, earphone and storage medium disclosed in the embodiments of the present application, and the principles and implementation manners of the present application are described by applying specific examples; the above embodiment description is only used to help understand the method and core idea of the present application; meanwhile, for those skilled in the art, according to the idea of the present application, the specific implementation manner and application range will be changed, and the above description should not be understood as limiting the present application.
Claims
1. An audio signal compensation method, characterized by, Applied to a headset, the method comprises: performing system frequency response correction on an initial audio signal to obtain a corrected audio signal, the system frequency response correction being used to eliminate environmental influence on the initial audio signal in a transmission process; outputting the corrected audio signal through the speaker; obtaining hearing detection information fed back for the corrected audio signal; determining a compensation parameter according to the hearing detection information, the compensation parameter being used to compensate a target audio signal to be outputted; wherein the headset further comprises a feedback microphone, and before the performing system frequency response correction on the initial audio signal to obtain the corrected audio signal, the method further comprises: outputting a test audio signal through the speaker; acquiring a received audio signal corresponding to the test audio signal through the feedback microphone; calculating a system correction parameter according to the test audio signal and the received audio signal; the performing system frequency response correction on the initial audio signal to obtain the corrected audio signal comprises: performing system frequency response correction on the initial audio signal according to the system correction parameter to obtain the corrected audio signal.
2. The method of claim 1, wherein, The headset further comprises a feed-forward microphone, and before the outputting the test audio signal through the speaker, the method further comprises: acquiring environmental sound through the feed-forward microphone; determining a test sound intensity of the test audio signal outputted by the speaker according to an environmental sound intensity of the environmental sound; the outputting the test audio signal through the speaker comprises: outputting the test audio signal with the test sound intensity through the speaker.
3. The method of claim 2, wherein, The test audio signal comprises a white noise signal, and a test sound intensity of the white noise signal is in a positive correlation with the environmental sound intensity of the environmental sound acquired by the feed-forward microphone.
4. The method of claim 1, wherein, The system correction parameter comprises a target equalizer parameter, and the calculating the system correction parameter according to the test audio signal and the received audio signal comprises: respectively performing Fourier transform on the test audio signal and the received audio signal; comparing the received audio signal after Fourier transform with the test audio signal to obtain a system frequency response; calculating the target equalizer parameter according to the system frequency response based on a least square criterion; the performing system frequency response correction on the initial audio signal according to the system correction parameter to obtain the corrected audio signal comprises: performing equalization correction on the initial audio signal through a target equalizer configured by the target equalizer parameter to obtain the corrected audio signal.
5. The method of claim 4, wherein, The target equalizer comprises an equalizer composed of a finite-length unit impulse response (FIR) filter.
6. The method of claim 1, wherein, Before the performing system frequency response correction on the initial audio signal to obtain the corrected audio signal, the method further comprises: acquiring a pre-stored system correction parameter from a storage module of the headset; the performing system frequency response correction on the initial audio signal to obtain the corrected audio signal comprises: performing system frequency response correction on the initial audio signal according to the system correction parameter to obtain the corrected audio signal.
7. The method of claim 1, wherein, The earphone further comprises a feed-forward microphone, and before the step of performing system frequency response correction on the initial audio signal to obtain the corrected audio signal, the method further comprises: in response to a hearing detection instruction, collecting an ambient sound through the feed-forward microphone; calculating an ambient sound parameter according to the ambient sound; if the ambient sound parameter is lower than an ambient sound threshold, performing the step of performing system frequency response correction on the initial audio signal to obtain the corrected audio signal.
8. The method of claim 7, wherein, The step of calculating the ambient sound parameter according to the ambient sound comprises: windowing and dividing the ambient sound according to a unit window length to obtain at least one frame of ambient sound sub-signal; calculating a short-time average energy of each frame of ambient sound sub-signal respectively; performing smoothing processing on the short-time average energy of each frame of ambient sound sub-signal to obtain the ambient sound parameter corresponding to the ambient sound.
9. The method of claim 7, wherein, After the step of calculating the ambient sound parameter according to the ambient sound, the method further comprises: if the ambient sound parameter is higher than the ambient sound threshold, outputting a first prompt information, the first prompt information being used to guide a user to move to a quiet environment and re-perform the step of collecting the ambient sound through the feed-forward microphone in response to the hearing detection instruction until the ambient sound parameter is not higher than the ambient sound threshold.
10. The method of claim 1, wherein, The earphone further comprises a feed-forward microphone, and before the step of performing system frequency response correction on the initial audio signal to obtain the corrected audio signal, the method further comprises: in response to a hearing detection instruction, collecting an ambient sound through the feed-forward microphone; determining a reverse audio signal corresponding to the ambient sound according to the ambient sound; outputting the reverse audio signal through the loudspeaker, the reverse audio signal being used to cancel the ambient sound to form an active noise reduction environment; The step of performing system frequency response correction on the initial audio signal to obtain the corrected audio signal comprises: performing system frequency response correction on the initial audio signal in the active noise reduction environment to obtain the corrected audio signal.
11. The method of claim 10, wherein, The earphone further comprises a feedback microphone, and after the step of outputting the reverse audio signal through the loudspeaker, the method further comprises: collecting a residual noise signal after active noise reduction through the feedback microphone; calculating a residual noise parameter according to the residual noise signal; if the residual noise parameter is higher than a residual noise threshold, outputting a second prompt information, the second prompt information being used to guide a user to move to a quiet environment and re-perform the step of collecting the ambient sound through the feed-forward microphone in response to the hearing detection instruction until the residual noise parameter is not higher than the residual noise threshold.
12. The method according to any one of claims 1 to 11, characterized in that, Before the step of performing system frequency response correction on the initial audio signal to obtain the corrected audio signal, the method further comprises: setting N to-be-detected frequency points, generating N initial audio signals corresponding to each to-be-detected frequency point respectively, the N initial audio signals corresponding to the N to-be-detected frequency points one by one, wherein N is a positive integer greater than or equal to 1; determining a reference sound intensity corresponding to each to-be-detected frequency point respectively; The step of outputting the corrected audio signal through the loudspeaker comprises: Output, through the loudspeaker, a correction audio signal with a corresponding reference sound intensity according to a reference sound intensity corresponding to each of the to-be-detected frequency points.
13. The method according to any one of claims 1 to 11, characterized in that, The method further includes: Obtaining hearing detection information fed back for the correction audio signal corresponding to the first frequency point; Adjusting the first sound intensity of the correction audio signal according to the hearing state to determine a sound intensity threshold corresponding to the first frequency point, the sound intensity threshold being a critical sound intensity at which the user can hear the correction audio signal; Taking the sound intensity threshold as the hearing detection information fed back for the correction audio signal corresponding to the first frequency point.
14. The method of claim 13, wherein, The method further includes: If the hearing state indicates that the first sound intensity of the correction audio signal does not belong to the audible range, increasing the first sound intensity of the correction audio signal by a first adjustment parameter; If the hearing state indicates that the first sound intensity of the correction audio signal belongs to the audible range, decreasing the first sound intensity of the correction audio signal by a second adjustment parameter, the first adjustment parameter being greater than the second adjustment parameter.
15. The method of claim 14, wherein, The sizes of the first adjustment parameter and the second adjustment parameter are in a negative correlation with the number of times of adjusting the first sound intensity.
16. The method according to any one of claims 1 to 11, characterized in that, The compensation parameter includes a compensation filter parameter, and the method further includes: Determining a compensation level matched with the hearing detection information according to the hearing detection information; Calculating a compensation filter parameter corresponding to the hearing detection information based on the compensation level; The method further includes: Configuring a target compensation filter by using the compensation filter parameter, the target compensation filter being used to filter and compensate a target audio signal to be output.
17. The method of claim 16, wherein, The target compensation filter includes an infinite-length unit impulse response (IIR) filter.
18. The method of claim 16, wherein, The method further includes: If there are M to-be-detected frequency points, configuring M target compensation filters corresponding to the M to-be-detected frequency points according to the compensation filter parameters corresponding to the to-be-detected frequency points, the M target compensation filters corresponding to the M to-be-detected frequency points one by one, where M is a positive integer greater than or equal to 1; Cascading the M target compensation filters.
19. The method of claim 16, wherein, The compensation filter parameter includes a gain coefficient, and the method further includes: If there are P to-be-detected frequency points, determining a gain coefficient corresponding to the compensation level according to the compensation level corresponding to each to-be-detected frequency point, where P is a positive integer greater than or equal to 1; The method further includes: According to the gain coefficient corresponding to the second frequency point, a target compensation filter corresponding to the second frequency point is configured, the target compensation filter being used for gain compensation on a signal component corresponding to the second frequency point in a target audio signal to be output according to the gain coefficient corresponding to the second frequency point, wherein the second frequency point is any frequency point in the P frequency points to be detected.
20. The method of claim 19, wherein, The configuring of the target compensation filter corresponding to the second frequency point according to the gain coefficient corresponding to the second frequency point comprises: If the gain coefficient corresponding to the second frequency point is greater than a gain threshold, an attenuation coefficient matching the gain coefficient is determined, and the target compensation filter corresponding to the second frequency point is configured according to the gain coefficient corresponding to the second frequency point and the attenuation coefficient.
21. The method of claim 16, wherein, After the compensation filter parameter corresponding to the hearing detection information is calculated based on the compensation level, the method further comprises: According to a target audio style, a style adjustment parameter corresponding to the target audio style is determined, and the compensation filter parameter is adjusted according to the style adjustment parameter; The configuring of the target compensation filter through the compensation filter parameter comprises: The target compensation filter is configured through the adjusted compensation filter parameter.
22. An audio signal compensation apparatus, characterized by, The audio signal compensation device is applied to a headset, and the headset comprises a loudspeaker. A frequency response correction unit is configured to perform system frequency response correction on an initial audio signal to obtain a corrected audio signal, wherein the system frequency response correction is used to eliminate environmental influences on the initial audio signal in a transmission process. An output unit is configured to output the corrected audio signal through the loudspeaker. A detection information acquisition unit is configured to acquire hearing detection information fed back for the corrected audio signal. A compensation unit is configured to determine a compensation parameter according to the hearing detection information, wherein the compensation parameter is used to compensate a target audio signal to be output. The headset further comprises a feedback microphone, and the audio signal compensation device further comprises a receiving unit and a calculation unit. The output unit is further configured to output a test audio signal through the loudspeaker before the system frequency response correction on the initial audio signal is performed to obtain the corrected audio signal. The receiving unit is configured to collect a received audio signal corresponding to the test audio signal through the feedback microphone. The calculation unit is configured to calculate a system correction parameter according to the test audio signal and the received audio signal.
23. An earphone, characterized by The frequency response correction unit is specifically configured to perform system frequency response correction on the initial audio signal according to the system correction parameter to obtain the corrected audio signal.
24. A computer readable storage medium having stored thereon a computer program, characterized in that, The computer program is executed by the processor to implement the method according to any one of claims 1 to 21. The computer program is executed by the processor to implement the method according to any one of claims 1 to 21.
Citation Information
Patent Citations
Methods, devices and system for a compensated hearing test
WO2020127939A1