Filter parameter determination method, audio signal processing method and device

By obtaining the audio signal and frequency domain transfer function of the speaker, and using the target loss function iteratively updates the filter parameters, the problem of complex and inefficient adjustment of filter parameters in the existing technology is solved, and adaptive filter parameter determination is realized, which improves the Accuracy and efficiency of audio signal processing.

CN119070780APending Publication Date: 2024-12-03XIAOMI EV TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202310629292.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-05-30
Publication Date
2024-12-03

AI Technical Summary

Technical Problem

In the prior art, filter parameter adjustment is usually manually set, debugging is complicated and inefficient, making it difficult to realize adaptive filter parameter adjustment to meet target needs.

Method used

By obtaining the audio signals played by multiple speakers, the frequency domain transfer function and frequency domain target audio signal corresponding to the speaker are determined, and the initial parameters of the filter iteratively updates according to the target loss function, and the target filter parameters are automatically determined.

Benefits of technology

The accuracy and efficiency of filter parameter determination are improved, and the filter parameters are automatically determined based on the set goals are realized, which simplifies the manual debugging process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119070780A_ABST
    Figure CN119070780A_ABST
Patent Text Reader

Abstract

The invention provides a filter parameter determination method and device and a signal processing method and device, and the method comprises the steps: obtaining audio signals played by a plurality of loudspeakers in an electronic device, determining a frequency domain transfer function corresponding to the transmission of the audio signals played by each loudspeaker to a target region, and receiving a frequency domain target audio signal of the audio signal sent by each loudspeaker in the target area, and determining a target loss function corresponding to the audio signal played by the plurality of loudspeakers received by the target area according to the frequency domain transfer functions corresponding to the plurality of loudspeakers, the initial parameters of the plurality of filters and the plurality of frequency domain target audio signals, and iteratively updating the initial parameters of the plurality of filters according to the target loss function to obtain the target parameters of the plurality of filters, so that the target parameters of the filters are automatically determined based on the set target, and the accuracy and efficiency of determining the parameters of the filters are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of audio processing technology, and in particular to a filter parameter determination method, an audio signal processing method and device. Background Art

[0002] With the development of vehicle technology, the sound quality of intelligent cockpit sound systems has attracted much attention and has become an important influencing factor in users' car selection.

[0003] The width and transient effect of the sound field are important factors that affect the listening experience of the entire vehicle. For a playback system with multiple speakers, filter calibration technology is usually used to achieve sound field reconstruction and improve the listening experience. In related technologies, filter parameter adjustment is usually done manually, which is complex and inefficient. Summary of the invention

[0004] The present application aims to solve one of the technical problems in the related art at least to some extent.

[0005] To this end, the present application proposes a filter parameter determination method, an audio signal processing method and an apparatus to achieve adaptive adjustment of the filter parameters to obtain target parameters of the filter that meet target requirements.

[0006] In one aspect, an embodiment of the present application provides a method for determining filter parameters, including:

[0007] Acquire audio signals played by multiple speakers in an electronic device;

[0008] Determine a frequency domain transfer function corresponding to the transmission of the audio signal played by each of the loudspeakers to the target area, and receive a frequency domain target audio signal of the audio signal emitted by each of the loudspeakers in the target area;

[0009] Determine a target loss function corresponding to the audio signals played by the multiple speakers received by the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, as well as the multiple frequency domain target audio signals; wherein the speakers and the filters correspond one to one;

[0010] According to the target loss function, the initial parameters of the multiple filters are iteratively updated to obtain the target parameters of the multiple filters.

[0011] Another aspect of the present application provides an audio signal processing method, including:

[0012] Acquire target parameters of multiple filters in the electronic device; wherein the target parameters of each filter are determined by using the filter parameter determination method described in the above embodiment;

[0013] The audio signals emitted by the multiple speakers in the electronic device are processed based on the target parameters of the multiple filters to obtain the target audio signals collected in the target area; wherein the filters and the speakers have a one-to-one correspondence.

[0014] Another aspect of the present application provides a filter parameter determination device, including:

[0015] An acquisition module, used to acquire audio signals played by multiple speakers in an electronic device;

[0016] A first determination module is used to determine a frequency domain transfer function corresponding to the transmission of the audio signal played by each of the loudspeakers to the target area, and to receive a frequency domain target audio signal of the audio signal emitted by each of the loudspeakers in the target area;

[0017] A second determination module is used to determine a target loss function corresponding to the audio signals played by the multiple speakers received by the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, and the multiple frequency domain target audio signals; wherein the speakers and the filters correspond one to one;

[0018] An updating module is used to iteratively update the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters.

[0019] Another aspect of the present application provides an audio signal processing device, including:

[0020] An acquisition module, used for acquiring target parameters of a plurality of filters in the electronic device; wherein the target parameters of each of the filters are determined by using the filter parameter determination device described in the above embodiment;

[0021] A processing module is used to process the audio signals emitted by the multiple speakers in the electronic device based on the target parameters of the multiple filters to obtain the target audio signals collected in the target area; wherein the filters and the speakers have a one-to-one correspondence.

[0022] Another aspect of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method described in the aforementioned method embodiment is implemented.

[0023] Another aspect of the present application is a non-temporary computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a processor, the method described in the foregoing method embodiment is implemented.

[0024] Another aspect of the present application provides a computer program product having a computer program stored thereon, which implements the method described in the aforementioned method embodiment when the program is executed by a processor.

[0025] The filter parameter determination method, audio signal processing method and device proposed in the present application obtain audio signals played by multiple speakers in an electronic device, determine the frequency domain transfer function corresponding to the audio signals played by each speaker transmitted to the target area, and the frequency domain target audio signal of the audio signal emitted by each speaker received in the target area, and determine the target loss function corresponding to the audio signal played by the multiple speakers received in the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, as well as the multiple frequency domain target audio signals, and iteratively update the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters, thereby realizing the automatic determination of the target parameters of the filters based on the set targets and improving the accuracy and efficiency of the filter parameter determination.

[0026] Additional aspects and advantages of the present application will be given in part in the description below, and in part will become apparent from the description below, or will be learned through the practice of the present application. BRIEF DESCRIPTION OF THE DRAWINGS

[0027] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:

[0028] Figure 1 A flowchart of a filter parameter determination method provided in an embodiment of the present application;

[0029] Figure 2 A flowchart of another filter parameter determination method provided in an embodiment of the present application;

[0030] Figure 3 A schematic diagram of first frequency sweep data and impulse response provided in an embodiment of the present application;

[0031] Figure 4 A schematic diagram of a scenario provided for an embodiment of the present application;

[0032] Figure 5 A flowchart of an audio signal processing method provided in an embodiment of the present application;

[0033] Figure 6 A schematic diagram of the structure of a filter parameter determination device provided in an embodiment of the present application;

[0034] Figure 7 A schematic diagram of the structure of an audio signal processing device provided in an embodiment of the present application;

[0035] Figure 8 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0036] Embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present application, and should not be construed as limiting the present application.

[0037] The filter parameter determination method, audio signal processing method and device according to the embodiments of the present application are described below with reference to the accompanying drawings.

[0038] Figure 1 A flowchart of a filter parameter determination method provided in an embodiment of the present application.

[0039] The execution subject of the filter parameter determination method in the embodiment of the present application is a filter parameter determination device, which can be set in an electronic device. The electronic device can be a vehicle-mounted device or a household appliance, etc., which is not limited in this embodiment.

[0040] like Figure 1 As shown, the method may include the following steps:

[0041] Step 101: Acquire audio signals played by multiple speakers in an electronic device.

[0042] In the embodiment of the present application, there are usually multiple speakers in the terminal device. For each speaker, an audio signal played by the speaker is obtained, and the audio signal is the audio signal that needs to be played by the speaker. The audio signal can be voice data, multimedia music data, etc., which is not limited in this embodiment.

[0043] Step 102 : determining a frequency domain transfer function corresponding to the audio signal played by each loudspeaker being transmitted to the target area, and receiving a frequency domain target audio signal of the audio signal emitted by each loudspeaker in the target area.

[0044] Among them, the frequency domain transfer function is the representation of the transfer function in the frequency domain. The transfer function is an acoustic transfer function, which is a transfer function from a sound source (speaker) to a reproduction area (target area). In an embodiment of the present application, the transfer function between the speaker and the target area, that is, the transfer function from the output sound source of the audio device (i.e., the speaker, also known as the horn) to the target area, is used to reflect the changes in the output signal generated during the transmission of the output signal of the audio device to the target area. Among them, the target area is obtained by dividing according to the needs of the scene. For example, in the cockpit of a vehicle, the cockpit can be divided into at least one target area, taking the division into two target areas as an example, for example, the area of ​​the column corresponding to the driver's seat is a target area, and the area of ​​the column corresponding to the co-pilot's seat is another target area. Alternatively, the cockpit contains two rows of seats, the first row of seats is used as a target area, and the other row of seats is used as another target area.

[0045] In one implementation method of an embodiment of the present application, based on the characteristics of the speaker of the present application and the characteristics of the transmission environment, a frequency domain transfer function for audio signal transmission by other speakers that match the characteristics of the speaker of the present application and the characteristics of the transmission environment is obtained, as the frequency domain transfer function for transmitting the audio signal emitted by the speaker of the present application to the target area.

[0046] Among them, the frequency domain target audio signal is the target audio signal converted to the frequency domain through Fourier transform, which is set based on the needs of the actual scene. The audio signal played by each speaker is transmitted to the target area, and different audio signal receiving targets are set. In other words, the receiving target of the audio signal emitted by each speaker in each target area can be set based on the needs. This receiving target is the frequency domain target audio signal, which is expressed in the form of a function.

[0047] As an example, if there are two speakers, speaker 1 and speaker 2, at the target position 1, it is hoped to receive only the audio signal of speaker 1 and not the audio signal of speaker 2, then the frequency domain target audio signal of the audio signal of speaker 1 corresponding to the target position 1 is a unit impulse response, and the frequency domain target audio signal of the audio signal of speaker 2 corresponding to the target position 1 is 0, that is, the target position 1 hopes to receive only the audio signal of speaker 1, and at the same time, it is expected that the received frequency domain target audio signal is as similar as possible to the audio signal played by the speaker.

[0048] Step 103 : determining a target loss function corresponding to the audio signals played by the multiple speakers in the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, as well as the multiple frequency domain target audio signals.

[0049] There may be one or more target areas.

[0050] Each speaker has a corresponding filter, that is, the speaker and the filter have a one-to-one correspondence, that is, the audio signal emitted by each speaker is filtered through the corresponding filter. The filter parameters are used to filter the audio signal played by the speaker.

[0051] In an embodiment of the present application, when there is only one target area, the first loss function of the audio signal played by each loudspeaker received by the target area is determined, and then the first loss functions of the audio signals played by each loudspeaker received by the target area are summed to obtain the target loss function corresponding to the audio signal played by multiple loudspeakers received by the target area. Among them, the method for determining the first loss function, as an implementation method, for the target area, determines the first loss function corresponding to the audio signal emitted by the j-th loudspeaker received in the target area according to the frequency domain transfer function corresponding to the transmission of the audio signal emitted by the j-th loudspeaker among the multiple loudspeakers to the target area, the initial parameters of the filter corresponding to the j-th loudspeaker, and the frequency domain target audio signal of the audio signal emitted by the j-th loudspeaker received in the target area. Similarly, the first loss function corresponding to the audio signal emitted by each other loudspeaker received by the target area can be determined.

[0052] In the embodiment of the present application, when there are multiple target areas, for each target area, the first loss function of the audio signal played by each loudspeaker received by the target area is determined, and then, the first loss functions of the audio signals played by each loudspeaker received by the multiple target areas are summed to obtain the target loss function corresponding to the audio signal played by the multiple loudspeakers received by the target area. Among them, the method for determining the first loss function, as an implementation method, for the i-th target area among the multiple target areas, according to the frequency domain transfer function corresponding to the audio signal emitted by the j-th loudspeaker among the multiple loudspeakers transmitted to the i-th target area, the initial parameters of the filter corresponding to the j-th loudspeaker, and the frequency domain target audio signal of the audio signal emitted by the j-th loudspeaker received in the i-th target area, determines the first loss function corresponding to the audio signal emitted by the j-th loudspeaker received in the i-th target area, wherein i and j are both positive integers greater than 2. Similarly, the first loss function corresponding to the audio signal emitted by any loudspeaker received by any target area can be determined, which will not be repeated here.

[0053] Step 104, iteratively updating the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters.

[0054] In one implementation of the embodiment of the present application, according to the target loss function, the number of iterations is set, and in response to the iteration to the set number of iterations, the parameters of each filter updated in the last iteration are used as the target parameters of each filter, wherein the filter parameters can be the coefficients of the filter, and the filter parameters that meet the set target are determined through continuous iterations, thereby realizing automatic determination of the target parameters of the filter based on the set target, and improving the accuracy and efficiency of determining the filter parameters. The set number of rounds can be determined based on prior experience.

[0055] Another implementation method of the embodiment of the present application is to continuously iterate according to the target loss function. In response to the iteration to the Nth round, the value of the target loss function obtained in the Nth round of iteration is less than the set value. The parameters of each filter obtained in the Nth round of iteration are used as the target parameters of each filter. The target parameters of the filter are automatically determined based on the set targets, which improves the accuracy and efficiency of the filter parameter determination. At the same time, by setting different targets, that is, the frequency domain target audio signal of the audio signal emitted by each loudspeaker in the target area, the target parameters of the filter that match the target can be determined. This has scalability and increases the different requirements of audio signal acquisition scenarios.

[0056] It should be noted that, in the above iterative process, the parameters of the filter can be continuously adjusted by using the gradient descent method to obtain the target parameters of the filter.

[0057] The filter parameter determination method of the embodiment of the present application obtains audio signals played by multiple speakers in an electronic device, determines the frequency domain transfer function corresponding to the audio signals played by each speaker transmitted to the target area, and the frequency domain target audio signal of the audio signal emitted by each speaker received in the target area, and determines the target loss function corresponding to the audio signal played by the multiple speakers received in the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, as well as the multiple frequency domain target audio signals, and iteratively updates the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters, thereby realizing automatic determination of the target parameters of the filters based on the set targets and improving the accuracy and efficiency of the filter parameter determination.

[0058] Based on the above embodiments, Figure 2 A flow chart of another filter parameter determination method provided in an embodiment of the present application is shown as follows: Figure 2 As shown, the method comprises the following steps:

[0059] Step 201: Acquire audio signals played by multiple speakers in an electronic device.

[0060] Step 202 : determining a frequency domain transfer function corresponding to the audio signal played by each loudspeaker being transmitted to the target area, and receiving a frequency domain target audio signal of the audio signal emitted by each loudspeaker in the target area.

[0061] Among them, the explanations of the aforementioned embodiment are also applicable to step 201 and step 202 of the embodiment of the present application. The principles are the same and will not be repeated here.

[0062] As for the frequency domain transfer function, in one implementation of the embodiment of the present application, by controlling the speaker to play a set sweep signal, the transmission characteristics from the speaker to the target area are measured, that is, the frequency domain transfer function from the speaker to the target area is determined. As an implementation method, a first sweep signal played by multiple speakers is obtained, and for each first sweep signal played by a speaker, the first sweep signal emitted by the speaker is collected in the target area to obtain a second sweep signal, and based on the first sweep signal and the second sweep signal, the time domain transfer function corresponding to the first sweep signal transmitted to the target area is determined, and the time domain transfer function is converted to the frequency domain to obtain the frequency domain transfer function corresponding to the first sweep signal emitted by the speaker to the target area.

[0063] The transfer function satisfies the following relationship:

[0064] x(t)*h(t-1)=y(t);

[0065] x(t)*f(t)=δ(t)

[0066] y(t)*f(t)=h(t)

[0067] Among them, x(t) is the first sweep signal of the input logarithm; y(t) is the second sweep signal collected by the microphone in the target area; δ(t) is the unit impulse response. In the embodiment of the present application, the unit impulse response can be used as the target audio signal for collecting the audio signals played by each speaker in the target area; h(t) is the current time domain transfer function, h(t-1) is the previous transfer function; f(t) is the inverse operation of x(t). Then, the time domain transfer function is converted to the frequency domain through Fourier transform to obtain the frequency domain transfer function. As an example, Figure 3 A schematic diagram of the first frequency sweep data and impulse response provided in an embodiment of the present application.

[0068] Step 203 , for the i th target area among the multiple target areas, determine the product of the frequency domain transfer function corresponding to the audio signal transmitted from the j th speaker among the multiple speakers to the i th target area and the initial parameters of the filter corresponding to the j th speaker.

[0069] Among them, i is the identifier of the target area, j is the identifier of the speaker, and both i and j are positive integers greater than 2, corresponding to the scenario where there are multiple speakers and target areas.

[0070] As an example, Figure 4 A schematic diagram of a scenario provided in an embodiment of the present application, such as Figure 4 As shown, there are two speakers, namely Figure 4 In the example, speaker1 and speaker2 have two target zones, zone1 and zone2. h11 is the time domain transfer function corresponding to the transmission from speaker 1 to target zone 1, h12 is the time domain transfer function corresponding to the transmission from speaker 1 to target zone 2, h21 is the time domain transfer function corresponding to the transmission from speaker 2 to target zone 1, and h22 is the time domain transfer function corresponding to the transmission from speaker 2 to target zone 2. Fourier transform is performed on the above time domain transfer functions to obtain the corresponding frequency domain transfer functions, which are H11, H12, H21 and H22 respectively.

[0071] For example: H11 = FFT[h11];

[0072] So in the frequency domain we satisfy:

[0073] X1*H11*G1+X2*H21*G2=Y1;

[0074] X2*H22*G2+X1*H12*G1=Y2;

[0075] Among them, X1 is the audio signal played by speaker 1, X2 is the audio signal played by speaker 2, Y1 is the audio signal received in target area 1, and Y2 is the audio signal received in target area 2.

[0076] In one scenario, in order to eliminate the crosstalk between the two speakers, let Y1 be infinitely close to X1, and Y2 be infinitely close to X2, then determine H11*G1=D1, H21*G2=D2 (D2=0), H22*G2=D4, H12*G1=D3 (D3=0), optionally, the sum of D1 and D2 can be δ, that is, the unit impulse response.

[0077] Thus, it can be determined that the product of multiplying the frequency domain transfer function corresponding to the speaker transmitted to the target area and the initial parameters of the filter corresponding to the speaker can be used to indicate the actual frequency domain audio signal received when the audio signal emitted by the speaker is received in the target area.

[0078] For example, for the target area 1, the frequency domain transfer function H11 transmitted by the speaker 1 to the target area 1 and the frequency domain representation G1 of the initial parameters of the filter 1 corresponding to the speaker 1 are multiplied to obtain a product, which indicates the actual frequency domain audio signal received in the target area 1 corresponding to the audio signal emitted by the speaker 1.

[0079] Step 204 , determining a first loss function corresponding to the audio signal emitted by the jth speaker received in the ith target area according to the product and the difference between the frequency domain target audio signal emitted by the jth speaker received in the ith target area.

[0080] In the embodiment of the present application, the difference between the frequency domain target audio signal D1 corresponding to the audio signal emitted by the loudspeaker 1 received in the target area 1 and the actual frequency domain audio signal is used as the first loss function corresponding to the audio signal emitted by the loudspeaker 1 received in the target area 1. Similarly, the first loss function corresponding to the audio signal emitted by each loudspeaker received in each target area can be determined.

[0081] As an example, Figure 4 For example, the first loss function corresponding to the audio signal emitted by speaker 1 received in target area 1 is Loss1 = H11*G1-D1;

[0082] A first loss function corresponding to the audio signal emitted by the loudspeaker 2 received in the target area 1, that is, Loss2 = H21*G2-D2, wherein D2 is the frequency domain target audio signal corresponding to the audio signal emitted by the loudspeaker 2 received in the target area 1;

[0083] A first loss function corresponding to the audio signal emitted by the loudspeaker 1 received in the target area 2, that is, Loss3 = H12*G1-D3, wherein D3 is the frequency domain target audio signal corresponding to the audio signal emitted by the loudspeaker 1 received in the target area 2;

[0084] The first loss function corresponding to the audio signal emitted by the loudspeaker 2 received in the target area 2 is Loss4=H22*G2-D4; wherein D4 is the frequency domain target audio signal corresponding to the audio signal emitted by the loudspeaker 2 received in the target area 2.

[0085] In one scenario, in a smart cockpit of a vehicle, the sound playback system of the smart cockpit includes multiple speakers. When multiple speakers play audio data at the same time, there is a problem of crosstalk. For example, to avoid crosstalk, the set target is to only receive the audio signal played by speaker 1 in target area 1, and the audio signal played by speaker 2 is 0, that is, the frequency domain target audio signal corresponding to the audio signal played by speaker 1 received by target area 1 is a unit impulse response, while the frequency domain target audio signal corresponding to the audio signal played by speaker 2 is 0; in target area 2, only the audio signal played by speaker 2 is received, and the audio signal played by speaker 1 is 0, that is, the frequency domain target audio signal corresponding to the audio signal played by speaker 2 received by target area 2 is a unit impulse response, while the frequency domain target audio signal corresponding to the audio signal played by speaker 1 is 0, thereby achieving crosstalk between multiple speakers when receiving audio signals in each target area, increasing the width of the sound field in the smart cockpit and improving the transient effect.

[0086] Step 205 , determining a target loss function according to first loss functions corresponding to audio signals emitted by respective loudspeakers received in a plurality of target areas.

[0087] In one implementation of the embodiment of the present application, the weights of the audio signals emitted by each speaker received by each target area are obtained, and the first loss function corresponding to the audio signals emitted by each speaker received by each target area is weightedly calculated using the corresponding weights to obtain the target loss function.

[0088] As an example, Figure 4 For example, the weight of receiving the audio signal emitted by speaker 1 in target area 1 is α, the weight of receiving the audio signal emitted by speaker 2 in target area 1 is β, the weight of receiving the audio signal emitted by speaker 1 in target area 2 is γ, and the weight of receiving the audio signal emitted by speaker 1 in target area 2 is ε;

[0089] Then the target loss function is Loss = α*Loss1+β*Loss2+γ*Loss3+ε*Loss4;

[0090] The value of each weight can be set according to the requirements. As an example, α, β, γ and ε are all 0.25.

[0091] Step 206, iteratively updating the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters.

[0092] One implementation method of the embodiment of the present application is to obtain the initial parameters of each filter for the first round of iteration, wherein the initial parameters can be randomly determined values, determine the target loss function of the first round of iteration according to the initial parameters of each filter, and then update the initial parameters of each filter to obtain the parameters of each filter obtained in the first round of iteration. For any round of iteration after the first round of iteration, obtain the parameters of each filter updated in the previous round of iteration, obtain the target loss function of this round according to the parameters of each filter updated in the previous round of iteration, and continue to update the parameters of each filter according to the updated target loss function to obtain the parameters of each filter updated in any round of iteration. As an implementation method, iterate a set number of rounds, and in response to iterating to the set number of rounds, use the parameters of each filter updated in the last round of iteration as the target parameters of each filter. As a second implementation method, in response to iterating to the Nth round, if the value of the target loss function obtained in the Nth round of iteration is less than the set value, use the parameters of each filter obtained in the Nth round of iteration as the target parameters of each filter.

[0093] In the filter parameter determination method of the embodiment of the present application, the audio signals played by multiple speakers in the electronic device are obtained, the frequency domain transfer function corresponding to the audio signals played by each speaker transmitted to the target area, and the frequency domain target audio signal of the audio signals emitted by each speaker received in the target area are determined, and the target loss function corresponding to the audio signals played by the multiple speakers received in the target area is determined according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, as well as the multiple frequency domain target audio signals, and the target loss function is determined according to the target loss function, the initial parameters of the multiple filters are iteratively updated to obtain the target parameters of the multiple filters, thereby realizing automatic determination of the target parameters of the filter based on the set targets, improving the accuracy and efficiency of the filter parameter determination, and at the same time, the determination of the filter parameters does not need to consider the influence of the wide frequency band, and the filter is directly designed to maximize the effect requirements, reduce the tailing nonlinear distortion, and improve the transient response of the system, so that users can enjoy high-quality music under the existing hardware conditions (number and configuration of speakers).

[0094] Based on the above embodiments, the present application provides an audio signal processing method. Figure 5 A flowchart of an audio signal processing method provided in an embodiment of the present application is shown in FIG. Figure 5 As shown, the method comprises the following steps:

[0095] Step 501: Obtain target parameters of multiple filters in an electronic device.

[0096] Among them, the parameters of each filter are determined by the filter parameter determination method described in the aforementioned method embodiment. For details, please refer to the explanation of the aforementioned embodiment. The principle is the same and will not be repeated here.

[0097] Step 502: Process the audio signals emitted by multiple speakers in the electronic device based on the target parameters of multiple filters to obtain target audio signals collected in the target area.

[0098] Among them, the filter and the speaker have a one-to-one correspondence.

[0099] In an embodiment of the present application, the electronic device includes a signal processing device, and the audio signals emitted by multiple speakers are processed through the target parameters of each filter in the signal processing device in the electronic device to obtain a target audio signal collected in a target area, wherein the target audio signal is related to the parameter settings of each filter. In one scenario, in response to the parameters of each filter being set for the purpose of eliminating crosstalk, the target audio signal received in the target area is the target audio signal with crosstalk eliminated, thereby increasing the width of the sound field and improving the transient effect, increasing the sense of hearing, and reducing nonlinearity.

[0100] In the audio signal processing method of the embodiment of the present application, the target parameters of the filter are calculated in advance through a network method and can be directly imported into the signal processing device for application, thereby meeting the pre-set audio signal acquisition requirements. Different acquisition requirement targets can be set, expanding the different requirements of audio signal acquisition scenarios, and improving the efficiency and accuracy of audio recognition.

[0101] In order to implement the above embodiment, the embodiment of the present application also proposes a filter parameter determination device.

[0102] Figure 6 A schematic diagram of the structure of a filter parameter determination device provided in an embodiment of the present application.

[0103] like Figure 6 As shown, the device may include:

[0104] The acquisition module 61 is used to acquire audio signals played by multiple speakers in the electronic device.

[0105] The first determination module 62 is used to determine a frequency domain transfer function corresponding to the audio signal played by each of the speakers being transmitted to a target area, and to receive a frequency domain target audio signal of the audio signal emitted by each of the speakers in the target area.

[0106] The second determination module 63 is used to determine the target loss function corresponding to the audio signal played by the multiple speakers received by the target area based on the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, as well as the multiple frequency domain target audio signals; wherein the speakers and filters correspond one to one.

[0107] The updating module 64 is used to iteratively update the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters.

[0108] Further, in an implementation of the embodiment of the present application, the audio signal is a first frequency sweep signal, and the first determination module 62 is specifically configured to:

[0109] For each first frequency sweep signal played by the loudspeaker, the first frequency sweep signal emitted by the loudspeaker is collected in the target area to obtain a second frequency sweep signal; based on the first frequency sweep signal and the second frequency sweep signal, a time domain transfer function corresponding to the first frequency sweep signal transmitted to the target area is determined; the time domain transfer function is converted to the frequency domain to obtain a frequency domain transfer function corresponding to the first frequency sweep signal emitted by the loudspeaker transmitted to the target area.

[0110] In an implementation of the embodiment of the present application, there are multiple target areas, and the second determination module 63 is specifically configured to:

[0111] For the i-th target area among the multiple target areas, determine the first loss function corresponding to the audio signal emitted by the j-th speaker among the multiple speakers transmitted to the i-th target area according to the frequency domain transfer function corresponding to the audio signal emitted by the j-th speaker and the frequency domain target audio signal of the audio signal emitted by the j-th speaker received in the i-th target area; wherein i and j are both positive integers greater than 2; determine the target loss function according to the first loss function corresponding to the audio signal emitted by each of the speakers received in the multiple target areas.

[0112] In an implementation of the embodiment of the present application, the second determining module 63 is specifically configured to:

[0113] Determine the product of a frequency domain transfer function corresponding to the audio signal emitted by a j-th speaker among the multiple speakers and transmitted to the i-th target area, and an initial parameter of a filter corresponding to the j-th speaker;

[0114] A first loss function corresponding to the audio signal emitted by the jth speaker received in the i-th target area is determined according to the difference between the product and the frequency domain target audio signal of the audio signal emitted by the j-th speaker received in the i-th target area.

[0115] In an implementation of the embodiment of the present application, the second determining module 63 is specifically configured to:

[0116] Obtaining weights of receiving audio signals emitted by each of the loudspeakers in each of the target areas;

[0117] The first loss function corresponding to the audio signal emitted by each of the loudspeakers and received in each of the target areas is weightedly calculated using the corresponding weights to obtain the target loss function.

[0118] In one implementation of the embodiment of the present application, the update module 64 is specifically configured to:

[0119] In response to the iteration reaching a set number of rounds, the parameters of each of the filters updated in the last round of iteration are used as target parameters of each of the filters;

[0120] or,

[0121] In response to the value of the target loss function obtained after the Nth round of iteration being less than a set value, the parameters of each of the filters obtained after the Nth round of iteration are used as the target parameters of each of the filters.

[0122] It should be noted that the above explanation of the method embodiment is also applicable to the device of this embodiment and will not be repeated here.

[0123] The filter parameter determination device of the embodiment of the present application obtains audio signals played by multiple speakers in an electronic device, determines the frequency domain transfer function corresponding to the audio signals played by each speaker transmitted to the target area, and the frequency domain target audio signal of the audio signal emitted by each speaker received in the target area, and determines the target loss function corresponding to the audio signals played by the multiple speakers received in the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, as well as the multiple frequency domain target audio signals, and iteratively updates the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters, thereby realizing automatic determination of the target parameters of the filters based on the set targets, and improving the accuracy and efficiency of the filter parameter determination.

[0124] In order to implement the above embodiment, the embodiment of the present application further proposes an audio signal processing device.

[0125] Figure 7 A schematic diagram of the structure of an audio signal processing device provided in an embodiment of the present application.

[0126] like Figure 7 As shown, the device may include:

[0127] The acquisition module 71 is used to acquire target parameters of multiple filters in the electronic device.

[0128] The processing module 72 is used to process the audio signals emitted by the multiple speakers in the electronic device based on the target parameters of the multiple filters to obtain the target audio signals collected in the target area; wherein the filters and the speakers have a one-to-one correspondence.

[0129] The target parameters of each of the filters are determined by using the filter processing device of the aforementioned embodiment.

[0130] It should be noted that the above explanation of the method embodiment is also applicable to the device of this embodiment, and will not be repeated here.

[0131] In the audio signal processing device of the embodiment of the present application, the target parameters of the filter are calculated in advance through a network method and can be directly imported into the signal processing device application, thereby meeting the pre-set audio signal acquisition requirements. Different acquisition requirement targets can be set, expanding the different requirements of audio signal acquisition scenarios, and improving the efficiency and accuracy of audio recognition.

[0132] In order to implement the above embodiments, the present application also proposes an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method described in the above method embodiments is implemented.

[0133] In order to implement the above embodiments, the present application also proposes a non-temporary computer-readable storage medium on which a computer program is stored. When the program is executed by a processor, the method described in the above method embodiments is implemented.

[0134] In order to implement the above embodiments, the present application also proposes a computer program product on which a computer program is stored. When the computer program is executed by a processor, the method described in the above method embodiments is implemented.

[0135] Figure 8 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a message transceiver device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0136] Reference Figure 8, the electronic device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input / output (I / O) interface 812 , a sensor component 814 , and a communication component 816 .

[0137] The processing component 802 generally controls the overall operation of the electronic device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.

[0138] The memory 804 is configured to store various types of data to support operations on the electronic device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, pictures, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0139] The power component 806 provides power to the various components of the electronic device 800. The power component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the electronic device 800.

[0140] The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and / or a rear camera. When the electronic device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0141] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.

[0142] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: home button, volume button, start button, and lock button.

[0143] The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the electronic device 800. For example, the sensor assembly 814 can detect the open / closed state of the electronic device 800, the relative positioning of the components, such as the display and keypad of the electronic device 800, and the sensor assembly 814 can also detect the position change of the electronic device 800 or a component of the electronic device 800, the presence or absence of contact between the user and the electronic device 800, the orientation or acceleration / deceleration of the electronic device 800, and the temperature change of the electronic device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 814 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0144] The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 can access a wireless network based on a communication standard, such as WiFi, 4G or 5G, or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0145] In an exemplary embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to perform the above methods.

[0146] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 804 including instructions, and the instructions can be executed by a processor 820 of an electronic device 800 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0147] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.

[0148] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.

[0149] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, fragment or portion of code comprising one or more executable instructions for implementing the steps of a custom logical function or process, and the scope of the preferred embodiments of the present application includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by technicians in the technical field to which the embodiments of the present application belong.

[0150] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as an ordered list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by an instruction execution system, device or apparatus (such as a computer-based system, a system including a processor, or other system that can fetch instructions from an instruction execution system, device or apparatus and execute the instructions), or in combination with these instruction execution systems, devices or apparatuses. For the purpose of this specification, "computer-readable medium" can be any device that can contain, store, communicate, propagate or transmit a program for use by an instruction execution system, device or apparatus, or in combination with these instruction execution systems, devices or apparatuses. More specific examples of computer-readable media (a non-exhaustive list) include the following: an electrical connection with one or more wires (electronic device), a portable computer disk box (magnetic device), a random access memory (RAM), a read-only memory (ROM), an erasable and programmable read-only memory (EPROM or flash memory), a fiber optic device, and a portable compact disk read-only memory (CDROM). In addition, the computer-readable medium may even be paper or other suitable medium on which the program is printed, since the program may be obtained electronically, for example, by optically scanning the paper or other medium and then editing, interpreting or processing in other suitable ways if necessary, and then stored in a computer memory.

[0151] It should be understood that the various parts of the present application can be implemented by hardware, software, firmware or a combination thereof. In the above-mentioned embodiments, multiple steps or methods can be implemented by software or firmware stored in a memory and executed by a suitable instruction execution system. For example, if implemented by hardware, as in another embodiment, it can be implemented by any one of the following technologies known in the art or their combination: a discrete logic circuit having a logic gate circuit for implementing a logic function for a data signal, a dedicated integrated circuit having a suitable combination of logic gate circuits, a programmable gate array (PGA), a field programmable gate array (FPGA), etc.

[0152] A person skilled in the art may understand that all or part of the steps in the method for implementing the above-mentioned embodiment may be completed by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, which, when executed, includes one or a combination of the steps of the method embodiment.

[0153] In addition, each functional unit in each embodiment of the present application may be integrated into a processing module, or each unit may exist physically separately, or two or more units may be integrated into one module. The above-mentioned integrated module may be implemented in the form of hardware or in the form of a software functional module. If the integrated module is implemented in the form of a software functional module and sold or used as an independent product, it may also be stored in a computer-readable storage medium.

[0154] The storage medium mentioned above may be a read-only memory, a magnetic disk or an optical disk, etc. Although the embodiments of the present application have been shown and described above, it can be understood that the above embodiments are exemplary and cannot be understood as limiting the present application. A person of ordinary skill in the art may change, modify, replace and modify the above embodiments within the scope of the present application.

Claims

1. A method for determining filter parameters, characterized in that: include: Acquire audio signals played by multiple speakers in an electronic device; Determine a frequency domain transfer function corresponding to the transmission of the audio signal played by each of the loudspeakers to the target area, and receive a frequency domain target audio signal of the audio signal emitted by each of the loudspeakers in the target area; Determine a target loss function corresponding to the audio signals played by the multiple speakers in the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, and the multiple frequency domain target audio signals; wherein the filters and the speakers have a one-to-one correspondence; According to the target loss function, the initial parameters of the multiple filters are iteratively updated to obtain the target parameters of the multiple filters.

2. The method according to claim 1, characterized in that The audio signal is a first frequency sweep signal, and the step of determining a frequency domain transfer function corresponding to the audio signal played by each of the speakers being transmitted to the target area includes: For each first frequency sweep signal played by the loudspeaker, collecting the first frequency sweep signal emitted by the loudspeaker in the target area to obtain a second frequency sweep signal; Determining a time domain transfer function corresponding to the first frequency sweep signal being transmitted to the target area according to the first frequency sweep signal and the second frequency sweep signal; The time domain transfer function is converted into the frequency domain to obtain a frequency domain transfer function corresponding to the first frequency sweep signal emitted by the loudspeaker being transmitted to the target area.

3. The method according to claim 1, characterized in that There are multiple target areas, and determining a target loss function corresponding to the audio signals played by the multiple speakers in the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, and the multiple frequency domain target audio signals, includes: For an i-th target area among the multiple target areas, a first loss function corresponding to the audio signal emitted by the j-th speaker among the multiple speakers is determined for receiving the audio signal emitted by the j-th speaker in the i-th target area according to a frequency domain transfer function corresponding to the transmission of the audio signal emitted by the j-th speaker to the i-th target area, an initial parameter of a filter corresponding to the j-th speaker, and a frequency domain target audio signal of the audio signal emitted by the j-th speaker in the i-th target area; wherein i and j are both positive integers greater than 2; The target loss function is determined according to a first loss function corresponding to the audio signals emitted by each of the loudspeakers and received in the plurality of target areas.

4. The method according to claim 3, characterized in that The method comprises: determining a first loss function corresponding to the audio signal emitted by the j-th speaker among the multiple speakers and transmitted to the i-th target area according to a frequency domain transfer function corresponding to the audio signal emitted by the j-th speaker, an initial parameter of a filter corresponding to the j-th speaker, and a frequency domain target audio signal of the audio signal emitted by the j-th speaker received in the i-th target area, comprising: Determine the product of a frequency domain transfer function corresponding to the audio signal emitted by a j-th speaker among the multiple speakers and transmitted to the i-th target area, and an initial parameter of a filter corresponding to the j-th speaker; A first loss function corresponding to the audio signal emitted by the jth speaker received in the i-th target area is determined according to the difference between the product and the frequency domain target audio signal emitted by the jth speaker received in the i-th target area.

5. The method according to claim 3, characterized in that The determining the target loss function according to the first loss function corresponding to the audio signals emitted by each of the loudspeakers received by the multiple target areas comprises: Obtaining weights of receiving audio signals emitted by each of the loudspeakers in each of the target areas; The first loss function corresponding to the audio signal emitted by each of the loudspeakers and received in each of the target areas is weightedly calculated using the corresponding weights to obtain the target loss function.

6. The method according to any one of claims 1 to 5, characterized in that: in, The method of iteratively updating the initial parameters of multiple filters in the signal processing device according to the target loss function to obtain target parameters of the multiple filters includes: In response to the iteration reaching a set number of rounds, the parameters of each of the filters updated in the last round of iteration are used as target parameters of each of the filters; or, In response to the value of the target loss function obtained after the Nth round of iteration being less than a set value, the parameters of each of the filters obtained after the Nth round of iteration are used as the target parameters of each of the filters.

7. An audio signal processing method, characterized in that: include: Obtaining target parameters of multiple filters in an electronic device; wherein the target parameters of each of the filters are determined by using any method described in claims 1-6; The audio signals emitted by the multiple speakers in the electronic device are processed based on the target parameters of the multiple filters to obtain the target audio signals collected in the target area; wherein the filters and the speakers have a one-to-one correspondence.

8. A filter parameter determination device, characterized in that: include: An acquisition module, used to acquire audio signals played by multiple speakers in an electronic device; A first determination module is used to determine a frequency domain transfer function corresponding to the transmission of the audio signal played by each of the loudspeakers to the target area, and to receive a frequency domain target audio signal of the audio signal emitted by each of the loudspeakers in the target area; A second determination module is used to determine a target loss function corresponding to the audio signals played by the multiple speakers received by the target area according to the frequency domain transfer functions corresponding to the multiple speakers and the initial parameters of the multiple filters, and the multiple frequency domain target audio signals; wherein the speakers and the filters correspond one to one; An updating module is used to iteratively update the initial parameters of the multiple filters according to the target loss function to obtain the target parameters of the multiple filters.

9. An audio signal processing device, characterized in that: include: An acquisition module, used for acquiring target parameters of a plurality of filters in an electronic device; wherein the target parameters of each of the filters are determined by using the apparatus according to claim 8; A processing module is used to process the audio signals emitted by the multiple speakers in the electronic device based on the target parameters of the multiple filters to obtain the target audio signals collected in the target area; wherein the filters and the speakers have a one-to-one correspondence.

10. An electronic device, characterized in that: The method comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the method according to any one of claims 1 to 6 is implemented, or the method according to claim 7 is implemented.

11. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, it implements the method according to any one of claims 1 to 6, or implements the method according to claim 7.