Echo cancellation method, device, computer equipment and storage medium
By filtering the echo processing signal and synchronizing the reference signal in a non-real-time system, the problem of echo cancellation failure is solved, and the effective echo cancellation and the improvement of vocal clarity are achieved.
Patent Information
- Application Number
- CN202111386014.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-22
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2041-11-22
AI Technical Summary
In non-real-time systems, such as Android, Linux and Windows platforms, the delays of the echo processing signals and reference signals are inconsistent, resulting in the echo cancellation failure and even destroying the echo processing signals, which is difficult to distinguish.
By filtering the to-process signal, the echo processing signal is obtained, and the audio signal output by the audio device to the speaker is used as a reference signal, the reference signal is synchronized based on the echo processing signal, and the synchronized reference signal is obtained, and then the echo processing signal is echo cancelled based on the echo cancellation algorithm and the synchronization reference signal.
By synchronously processing the reference signal, the time difference is eliminated, the echo processing signal is prevented from being destroyed, the synchronization problem of echo cancellation in non-real-time systems is solved, and the echo cancellation is effectively eliminated, improving the clarity of the output vocals.
Smart Images

Figure CN114141261B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of speech signal processing, and in particular to an echo elimination method, apparatus, computer equipment and storage medium. Background Art
[0002] With the development of speech signal processing technology, echo cancellation technology has emerged. Echo cancellation technology can be applied in many fields. At present, the latest application field of echo cancellation technology is mobile terminals such as mobile phones and Windows platforms. For example, it can be used for live broadcasting, video conferencing, VoIP software phones, etc. In related technologies, two audio signals need to be transmitted to the echo cancellation algorithm when performing echo cancellation, namely the echo processing signal and the reference signal, and these two audio signals must be very synchronized.
[0003] However, the systems used by mobile terminals such as mobile phones and platforms such as Windows are mainly Android, Linux and Windows, etc., and these systems are non-real-time systems, which makes the delay of the collected echo processing signal and the reference signal inconsistent. Therefore, in the process of echo cancellation, due to the loss of synchronization, the echo cancellation cannot be performed, and the collected echo processing signal may even be destroyed, making the echo processing signal difficult to distinguish. In addition, there are many types of audio processing chips used in the devices in these systems, and the audio signals output by various audio chips will further increase the complexity of the synchronization problem. Therefore, there is an urgent need for an echo cancellation method. Summary of the invention
[0004] Based on this, it is necessary to provide an echo cancellation method, apparatus, computer device, computer-readable storage medium and computer program product capable of eliminating echoes in order to solve the above technical problems.
[0005] In a first aspect, the present application provides an echo cancellation method. The method comprises:
[0006] The signal to be processed is filtered to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0007] Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0008] Based on the echo cancellation algorithm and the synchronization reference signal, echo cancellation is performed on the echo processing signal.
[0009] In one embodiment, filtering the signal to be processed to obtain the echo processing signal includes:
[0010] The audio signal outside the preset frequency range in the signal to be processed is filtered out, wherein the preset frequency range is 20 Hz to 20 kHz.
[0011] In one embodiment, synchronizing the reference signal based on the echo processing signal includes:
[0012] extracting an audio signal with a frequency range of 4kHz to 20kHz from the echo processing signal as a synchronous comparison signal;
[0013] Determine a first reference time set according to a time period corresponding to the reference signal, and determine a second reference time set according to a time period corresponding to the synchronous comparison signal;
[0014] Determine the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set;
[0015] According to the time difference, the starting time point and the ending time point of the reference signal are adjusted.
[0016] In one embodiment, determining the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set includes:
[0017] Select any first reference time from the first reference time set as the first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to the frequency distribution of the signal amount of the reference signal at the first target reference time;
[0018] Select a second reference time that has not been selected from the second reference time set and use it as the comparison time; determine a second preset number of second reference frequency points corresponding to the comparison time according to the frequency distribution of the signal amount of the synchronous comparison signal at the comparison time and a first preset number of first reference frequency points corresponding to the first target reference time; and judge whether a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points; if not, repeat the above process of selecting the second reference time, determining the second reference frequency points corresponding to the comparison time, and judging until a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points; and use the second reference time selected when the matching condition is satisfied as the second target reference time;
[0019] A time difference between the echo processing signal and the reference signal is determined according to the first target reference time and the second target reference time.
[0020] In one embodiment, the first preset number is the same as the second preset number and both are not less than 2; for any first reference frequency point in the first preset number of first reference frequency points, there is a second reference frequency point with the same frequency value in the second preset number of second reference frequency points; accordingly, determining whether the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition includes:
[0021] The first reference frequency point and the second reference frequency point with the same frequency value form a reference frequency point group, and calculate the amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group;
[0022] Determine whether the amplitude ratio corresponding to each reference frequency point group is within a preset range, and obtain the total number of reference frequency point groups whose amplitude ratios are within the preset range;
[0023] If the total number is not less than the preset threshold, it is determined that a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points.
[0024] In one embodiment, based on the echo cancellation algorithm and the synchronization reference signal, before performing echo cancellation on the echo processing signal, the method includes:
[0025] The amplitude of the synchronization reference signal is adjusted according to the amplitude ratio when the matching condition is met.
[0026] In a second aspect, the present application also provides an echo cancellation device. The device comprises:
[0027] A first acquisition module is used to filter the signal to be processed and obtain an echo processing signal, wherein the signal to be processed is the sound generated by the audio signal output by the audio device to the speaker after being played by the speaker and the sound emitted by a person after being collected by the microphone at the same time;
[0028] A synchronization module, used to use the audio signal output by the audio device to the speaker as a reference signal, synchronize the reference signal based on the echo processing signal, and obtain a synchronization reference signal;
[0029] The echo cancellation module is used to perform echo cancellation on the echo processing signal based on the echo cancellation algorithm and the synchronization reference signal.
[0030] In a third aspect, the present application further provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
[0031] The signal to be processed is filtered to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0032] Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0033] Based on the echo cancellation algorithm and the synchronization reference signal, echo cancellation is performed on the echo processing signal.
[0034] In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0035] The signal to be processed is filtered to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0036] Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0037] Based on the echo cancellation algorithm and the synchronization reference signal, echo cancellation is performed on the echo processing signal.
[0038] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0039] The signal to be processed is filtered to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0040] Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0041] Based on the echo cancellation algorithm and the synchronization reference signal, echo cancellation is performed on the echo processing signal.
[0042] The above-mentioned echo cancellation method, device, computer equipment, storage medium and computer program product filter the signal to be processed to obtain the echo processing signal, wherein the signal to be processed is the sound generated by the audio signal output by the audio device to the speaker after being played by the speaker and the sound emitted by the person collected by the microphone at the same time; the audio signal output by the audio device to the speaker is used as a reference signal, and the reference signal is synchronized based on the echo processing signal to obtain a synchronization reference signal; based on the echo cancellation algorithm and the synchronization reference signal, the echo processing signal is echo-cancelled. Compared with the related art of directly subtracting the reference signal from the echo processing signal to obtain the echo cancellation signal, since the reference signal is synchronously processed and the time difference is eliminated, the echo processing signal can be avoided from being destroyed, thereby solving the synchronization problem of echo cancellation in non-real-time systems, and eliminating the echo, thereby improving the clarity of the output human voice. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] Figure 1 A diagram showing an application environment of an echo cancellation method in an embodiment;
[0044] Figure 2 is a schematic flow chart of an echo cancellation method in one embodiment;
[0045] Figure 3 is a structural block diagram of an echo cancellation device in an embodiment;
[0046] Figure 4 A schematic diagram of a layered architecture of an echo cancellation device in another embodiment;
[0047] Figure 5 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0048] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0049] At present, the systems used by mobile terminals such as mobile phones and platforms such as Windows are mainly Android, Linux and Windows, etc., and these systems are non-real-time systems, which makes the delay of the collected echo processing signal and the reference signal inconsistent. Therefore, in the process of echo cancellation, due to the loss of synchronization, the echo cancellation cannot be performed, and the collected echo processing signal may even be destroyed, making the echo processing signal difficult to distinguish. In addition, there are many types of audio processing chips used in the devices in these systems, and the audio signals output by various audio chips will further increase the complexity of the synchronization problem. Therefore, there is an urgent need for an echo cancellation method.
[0050] The echo cancellation method provided in the embodiment of the present application can be applied to Figure 1 In the application environment shown. Among them, the terminal 101 communicates with the server 102 through the network. The data storage system can store the data that the server 102 needs to process. The data storage system can be integrated on the server 102, or it can be placed on the cloud or other network servers. Among them, the terminal 101 is used to obtain the signal to be processed and the reference signal, and transmit the signal to be processed and the reference signal to the server 102, and the server 102 processes the signal to be processed and the reference signal.
[0051] The terminal 101 may be, but is not limited to, various personal computers, laptops, smart phones, tablet computers, IoT devices and portable wearable devices. The IoT devices may be smart speakers, smart TVs, smart air conditioners, smart car-mounted devices, etc. The portable wearable devices may be smart watches, smart bracelets, head-mounted devices, etc. The server 104 may be implemented as an independent server or a server cluster consisting of multiple servers.
[0052] In one embodiment, Figure 2 As shown, an echo cancellation method is provided, which is applied to Figure 1 Taking the server 102 in the example as an example, the following steps are included:
[0053] 201. Filter the signal to be processed to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0054] 202. Using the audio signal output by the audio device to the speaker as a reference signal, and synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0055] 203. Perform echo cancellation on the echo processing signal based on the echo cancellation algorithm and the synchronization reference signal.
[0056] In the above step 201, the audio device refers to a device that can output audio. The audio devices in different application scenarios may be different. For example, in a live broadcast scenario, the audio device may be a sound card that plays music from a music player. For another example, in a video conferencing scenario, the audio device may be a microphone that outputs human voice. The embodiment of the present invention does not specifically limit this.
[0057] A speaker refers to a device that can amplify sound. The embodiment of the present invention does not specifically limit the type of speaker. In addition, based on different application scenarios, a speaker can be combined with an audio device to appear as a device that can amplify the audio signal while playing it. Filtering refers to the operation of filtering out a specific frequency band in an audio signal.
[0058] Specifically, when the microphone collects the sound emitted by people, it also collects the audio signal output by the audio device through the amplifier. At this time, the sound collected by the microphone is not pure human voice, but may include audio signals generated by other devices. Before processing the signal to be processed collected by the microphone, it will be preprocessed. This preprocessing process is to filter the signal to be processed. The purpose of filtering is to first filter out the audio signal that has little impact on the subsequent processing process and obtain the echo processing signal.
[0059] In the above step 202, synchronization refers to adjusting the time of the reference signal and the time of the echo processing signal to a common time. Specifically, it is necessary to determine which signal time is used as the synchronization time according to actual needs, and the time of the other signal needs to be synchronized with the time of the signal. In this embodiment, the reference signal and the echo processing signal are transmitted through different transmission paths, so the time points at which they arrive at the device that can perform echo cancellation are also different. In order to synchronize the time when the reference signal and the echo processing signal are processed, it is necessary to synchronize the reference signal.
[0060] In the above step 203, according to the cause of the communication echo, the echo can be divided into two types, namely acoustic echo and line echo. In the present embodiment, the processed echo is an acoustic echo. Acoustic echo refers to the sound of the speaker being fed back to the microphone in hands-free, conference, live broadcast or other application scenarios. What the echo cancellation algorithm needs to achieve is to eliminate these echoes. Common echo cancellation algorithms include LSM (Log Structured Merge Trees) algorithm, NLMS (normalized LMS) algorithm and NSAF (Normalized Sub-band Adaptive Filter) algorithm, etc. For the echo cancellation algorithm, the embodiment of the present invention does not specifically limit it. Depending on the actual application, the choice of echo cancellation algorithm may be different.
[0061] From the above content, it can be known that when performing echo cancellation on the echo processing signal, it is necessary to ensure that the echo processing signal and the reference signal are synchronized in time so that the echo algorithm will not damage the echo processing signal and the output human voice is clearer without other interference.
[0062] The method provided in the embodiment of the present invention can eliminate the time difference by synchronously processing the reference signal, thereby avoiding the destruction of the echo processing signal, thereby solving the synchronization problem of echo cancellation in a non-real-time system, eliminating the echo, and further improving the clarity of the output human voice.
[0063] In combination with the content of the above embodiments, in one embodiment, filtering the signal to be processed to obtain the echo processing signal includes:
[0064] The audio signal outside the preset frequency range in the signal to be processed is filtered out, wherein the preset frequency range is 20 Hz to 20 kHz.
[0065] Specifically, the signal to be processed is mainly composed of a human voice signal and a signal output by a loudspeaker, but the microphone may collect other signals while collecting these signals, and the frequency range of human hearing is from 20Hz to 20kHz. Therefore, the signal to be processed is first filtered to filter out audio signals of other frequency bands irrelevant to this embodiment, and an echo processing signal is obtained, so that the echo processing can be targeted later. The embodiment of the present invention does not specifically limit the selection of the filtering method, including but not limited to: Chebyshev response filtering, Butterworth response and Bessel response, etc.
[0066] The method provided by the embodiment of the present invention can remove a part of the interference signal from the echo processing signal before the echo processing by filtering the signal to be processed and filtering out the audio signals in other frequency ranges irrelevant to the present embodiment, thereby avoiding the interference of redundant signals on the synchronization process and improving the clarity of the human voice output finally.
[0067] In combination with the content of the above embodiments, in one embodiment, synchronizing the reference signal based on the echo processing signal includes:
[0068] 301. Extract an audio signal with a frequency range of 4 kHz to 20 kHz from the echo processing signal as a synchronous comparison signal;
[0069] 302. Determine a first reference time set according to a time period corresponding to the reference signal, and determine a second reference time set according to a time period corresponding to the synchronous comparison signal;
[0070] 303. Determine the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set;
[0071] 304. Adjust the starting time point and the ending time point of the reference signal according to the time difference.
[0072] In the above step 301, since the frequency range of the sound emitted by a person is between 20 Hz and 4 kHz, that is, the frequency of the frequency signal finally output should be between 20 Hz and 4 kHz, and the reference signal output by the audio device does not include the sound signal that needs to be obtained in this embodiment, when the reference signal is synchronized using the echo processing signal, it is only necessary to extract the audio signal with a frequency range of 4 kHz to 20 kHz in the echo processing signal as the synchronization comparison signal.
[0073] In the above step 302, since the reference signal and the echo processing signal pass through different paths, the time when the two signals arrive at the echo cancellation device will also be inconsistent, resulting in loss of synchronization. Usually, the reference signal will arrive at the echo cancellation device earlier than the echo processing signal. Therefore, it is necessary to adjust the time of the reference signal to synchronize it with the time of the echo processing signal.
[0074] The first reference time set refers to a set consisting of multiple different time periods selected from the time period corresponding to the reference signal, and the second reference time set refers to a set consisting of multiple different time periods selected from the time period corresponding to the synchronous comparison signal.
[0075] In the above step 303, the time difference refers to the period of time that the reference signal arrives at the echo cancellation device earlier or later than the echo processing signal. The reference signal will adjust the start time and end time of the reference signal according to the time difference to make it consistent with the start time and end time of the echo processing signal.
[0076] The method provided by the embodiment of the present invention can adjust the starting time point and the ending time point of the reference signal by determining the time difference between the echo processing signal and the reference signal, so that the reference signal and the echo processing signal are synchronized in time, thereby achieving echo cancellation.
[0077] In combination with the contents of the above embodiments, in one embodiment, determining the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set includes:
[0078] 401. Select any first reference time from the first reference time set as a first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to a frequency distribution of a signal amount of a reference signal at the first target reference time;
[0079] 402. Select a second reference time that has not been selected from the second reference time set and use it as the comparison time. Determine a second preset number of second reference frequency points corresponding to the comparison time according to the frequency distribution of the signal amount of the synchronous comparison signal at the comparison time and a first preset number of first reference frequency points corresponding to the first target reference time. Judge whether the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition. If not, repeat the above process of selecting the second reference time, determining the second reference frequency points corresponding to the comparison time, and judging until the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition. Use the second reference time selected when the matching condition is met as the second target reference time.
[0080] 403. Determine a time difference between the echo processing signal and the reference signal according to the first target reference time and the second target reference time.
[0081] In addition, the method for determining the time difference is not limited to the method described in the above steps 401 to 403, and the echo processing signal can also be used as a control group to determine the time difference between the reference signal and the echo processing signal. The implementation process is:
[0082] Select any second reference time from the second reference time set as the first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to the frequency distribution of the signal amount of the synchronous comparison signal at the first target reference time;
[0083] Select a first reference time that has not been selected from the first reference time set and use it as the comparison time; determine a second preset number of second reference frequency points corresponding to the comparison time according to the frequency distribution of the signal amount of the reference signal at the comparison time and a first preset number of first reference frequency points corresponding to the first target reference time; and judge whether the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition; if not, repeat the above process of selecting the first reference time, determining the second reference frequency points corresponding to the comparison time, and judging until the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition, and use the second reference time selected when the matching condition is met as the second target reference time;
[0084] According to the time difference, the starting time point and the ending time point of the reference signal are adjusted.
[0085] The method provided by the embodiment of the present invention can determine the time difference between the echo processing signal and the reference signal by determining the first target reference time and the second target reference time, and further can adjust the time of the reference signal to be synchronized with the time of the echo processing signal.
[0086] In combination with the content of the above embodiment, in one embodiment, the first preset number is the same as the second preset number and both are not less than 2; for any first reference frequency point in the first preset number of first reference frequency points, there is a second reference frequency point with the same frequency value in the second preset number of second reference frequency points; accordingly, determining whether the first preset number of first reference frequency points and the second preset number of second reference frequency points meet the matching condition includes:
[0087] 501. Grouping a first reference frequency point and a second reference frequency point having the same frequency value into a reference frequency point group, and calculating an amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group;
[0088] 502. Determine whether the amplitude ratio corresponding to each reference frequency point group is within a preset range, and obtain the total number of reference frequency point groups whose amplitude ratios are within the preset range;
[0089] 503. If the total number is not less than the preset threshold, determine that a matching condition is satisfied between a first preset number of first reference frequency points and a second preset number of second reference frequency points.
[0090] In the above step 501, the same frequency value means that after the first reference frequency point is determined, the second reference frequency point also corresponds to it one by one and is the same, and the same frequency points in the first reference frequency point and the second reference frequency point are a group of reference frequency point groups, and the amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group is calculated respectively. For example, the first reference frequency point is determined to be 5kHz, 10kHz and 15kHz, and the amplitudes corresponding to the three frequency points 5kHz, 10kHz and 15kHz are A, B and C respectively. The second reference frequency point should also be 5kHz, 10kHz and 15kHz, and the amplitudes corresponding to the three frequency points 5kHz, 10kHz and 15kHz are D, E and F respectively. The 5kHz of the first reference frequency point and the second reference frequency point are a group of reference frequency point groups, and the 10kHz of the first reference frequency point and the second reference frequency point are another group of reference frequency point groups, and so on, 3 groups of reference frequency point groups can be formed. The amplitude ratios of the 3 groups of reference frequency point groups are A / D, B / E, and C / F respectively.
[0091] In the above step 502, this embodiment does not specifically limit the preset range, and the preset range can be adjusted accordingly according to the actual test requirements. Specifically, the amplitude ratios corresponding to each group of reference frequency point groups may not be equal, but it is necessary to determine whether the amplitude ratios corresponding to each group of reference frequency point groups are within the preset range.
[0092] In the above step 503, the preset threshold should not be greater than the number of reference frequency point groups. For example, if the reference frequency point groups are set to 5, the preset threshold can be 5 or 4. The implementation of the present invention does not specifically limit the preset threshold, and the preset threshold can be adjusted accordingly according to the actual test requirements.
[0093] The method provided by the embodiment of the present invention can determine the total number of reference frequency point groups within the preset range by judging whether the amplitude ratio corresponding to each reference frequency point group is within the preset range, and then judge whether a matching condition is satisfied between a first preset number of first reference frequency points and a second preset number of second reference frequency points.
[0094] In combination with the contents of the above embodiments, in one embodiment, before performing echo cancellation on the echo processed signal based on the echo cancellation algorithm and the synchronization reference signal, the method includes:
[0095] The amplitude of the synchronization reference signal is adjusted according to the amplitude ratio that meets the matching condition.
[0096] Specifically, based on the echo cancellation algorithm and the synchronization reference signal, before performing echo cancellation on the echo processing signal, it is also necessary to amplify or reduce the amplitude of the synchronization reference signal according to the amplitude ratio that meets the matching condition.
[0097] The method provided in the embodiment of the present invention can adjust the amplitude of the synchronization reference signal so that after the echo processing signal is echo-cancelled based on the echo cancellation algorithm and the synchronization reference signal, the obtained human voice is clearer and has no redundant interference signals.
[0098] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0099] It should be noted that the technical solutions described above can be implemented as independent embodiments in the actual implementation process, or they can be combined with each other and implemented as combined embodiments. In addition, when describing the contents of the above embodiments of the present invention, different embodiments are described in a corresponding order based on the idea of convenient description, such as the order of data flow, but the execution order between different embodiments is not limited, nor is the execution order of the steps within the embodiments limited. Accordingly, in the actual implementation process, if it is necessary to implement multiple embodiments provided by the present invention, it is not necessarily necessary to follow the execution order provided when the embodiments of the present invention are described, but the execution order between different embodiments can be arranged according to the needs.
[0100] Based on the same inventive concept, the embodiment of the present application also provides an echo cancellation device for implementing the echo cancellation method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more echo cancellation device embodiments provided below can refer to the limitations of the echo cancellation method above, and will not be repeated here.
[0101] In combination with the contents of the above embodiments, in one embodiment, Figure 3 As shown, an echo cancellation device is provided, including: a first acquisition module 311, a synchronization module 312, an echo cancellation module 313 and an amplitude adjustment module 314, wherein:
[0102] The first acquisition module 311 is used to filter the signal to be processed and obtain the echo processing signal, wherein the signal to be processed is the sound generated by the audio signal output by the audio device to the speaker after being played by the speaker and the sound of the person is collected by the microphone at the same time;
[0103] A synchronization module 312, configured to use the audio signal output by the audio device to the speaker as a reference signal, and synchronize the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0104] The echo cancellation module 313 is used to perform echo cancellation on the echo processing signal based on the echo cancellation algorithm and the synchronization reference signal, and output the human voice after the echo cancellation;
[0105] The amplitude adjustment module 314 is used to adjust the amplitude of the synchronization reference signal according to the amplitude ratio that meets the matching condition.
[0106] In one embodiment, the first acquisition module 311 includes:
[0107] The filtering submodule 3111 is used to filter out the audio signal outside the preset frequency range in the signal to be processed, wherein the preset frequency range is 20 Hz to 20 kHz.
[0108] An audio device 3112 for outputting audio signals to a speaker and a synchronization module 312;
[0109] A loudspeaker 3113, used to amplify the audio signal output by the audio device;
[0110] Microphone 3114 is used to collect the sound emitted by people and the audio signal output by the speaker.
[0111] In one embodiment, the echo cancellation device further includes:
[0112] In one embodiment, the synchronization module 312 includes:
[0113] An extraction submodule, used for extracting an audio signal with a frequency range of 4kHz to 20kHz from the echo processing signal as a synchronous comparison signal;
[0114] A first determination submodule, configured to determine a first reference time set according to a time period corresponding to the reference signal, and to determine a second reference time set according to a time period corresponding to the synchronous comparison signal;
[0115] A first determination submodule, configured to determine a time difference between the echo processing signal and the reference signal according to a frequency distribution of a signal amount of the reference signal at each first reference moment in a first reference moment set, and a frequency distribution of a signal amount of the synchronous comparison signal at each second reference moment in a second reference moment set;
[0116] The adjustment module is used to adjust the starting time point and the ending time point of the reference signal according to the time difference.
[0117] In one embodiment, the first determining submodule includes:
[0118] A first determining unit, configured to select any first reference moment from the first reference moment set as a first target reference moment, and determine a first reference frequency point corresponding to the first target reference moment according to a frequency distribution of a signal amount of a reference signal at the first target reference moment;
[0119] a judgment unit, configured to select a second reference moment that has not been selected from the second reference moment set and use it as the comparison moment, determine a second preset number of second reference frequency points corresponding to the comparison moment according to the frequency distribution of the signal quantity of the synchronous comparison signal at the comparison moment and a first preset number of first reference frequency points corresponding to the first target reference moment, judge whether a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points, and if not, repeat the above-mentioned process of selecting the second reference moment, determining the second reference frequency points corresponding to the comparison moment, and judging, until a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points, and use the second reference moment selected when the matching condition is satisfied as the second target reference moment;
[0120] The second determining unit is used to determine the time difference between the echo processing signal and the reference signal according to the first target reference time and the second target reference time.
[0121] In one embodiment, the judging unit includes:
[0122] a calculation subunit, configured to group the first reference frequency point and the second reference frequency point having the same frequency value into a reference frequency point group, and calculate the amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group;
[0123] A judging subunit, used to judge whether the amplitude ratio corresponding to each reference frequency point group is within a preset range, and obtain the total number of reference frequency point groups whose amplitude ratios are within the preset range;
[0124] The determination subunit is configured to determine whether a matching condition is satisfied between a first preset number of first reference frequency points and a second preset number of second reference frequency points if the total number is not less than a preset threshold.
[0125] In one embodiment, the echo cancellation device can also be described using a layered architecture, such as Figure 4 The embodiment of the present invention comprises: an application layer, a server layer, a sound subsystem layer, a driver layer and a physical layer, wherein the application layer comprises a client capable of playing audio. These audio clients can be connected to the audio server via an audio stream. The server layer can be software and manage the use and access to audio devices such as audio chips, mics, speakers, etc. The server layer can run as a background process for receivers and audio processing. The sound subsystem layer comprises software for implementing audio sampling and filtering. The driver layer may include an audio driver.
[0126] Each module in the above-mentioned echo cancellation device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each module.
[0127] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Figure 5 As shown. The computer device includes a processor, a memory and a network interface connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store audio signal data. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, an echo cancellation method is implemented.
[0128] Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0129] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:
[0130] The signal to be processed is filtered to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0131] Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0132] Based on the echo cancellation algorithm and the synchronization reference signal, echo cancellation is performed on the echo processing signal.
[0133] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0134] The audio signal outside the preset frequency range in the signal to be processed is filtered out, wherein the preset frequency range is 20 Hz to 20 kHz.
[0135] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0136] extracting an audio signal with a frequency range of 4kHz to 20kHz from the echo processing signal as a synchronous comparison signal;
[0137] Determine a first reference time set according to a time period corresponding to the reference signal, and determine a second reference time set according to a time period corresponding to the synchronous comparison signal;
[0138] Determine the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set;
[0139] According to the time difference, the starting time point and the ending time point of the reference signal are adjusted.
[0140] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0141] Select any first reference time from the first reference time set as the first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to the frequency distribution of the signal amount of the reference signal at the first target reference time;
[0142] Select a second reference time that has not been selected from the second reference time set and use it as the comparison time; determine a second preset number of second reference frequency points corresponding to the comparison time according to the frequency distribution of the signal amount of the synchronous comparison signal at the comparison time and a first preset number of first reference frequency points corresponding to the first target reference time; and judge whether the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition; if not, repeat the above process of selecting the second reference time, determining the second reference frequency points corresponding to the comparison time, and judging until the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition, and use the second reference time selected when the matching condition is met as the second target reference time;
[0143] A time difference between the echo processing signal and the reference signal is determined according to the first target reference time and the second target reference time.
[0144] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0145] The first reference frequency point and the second reference frequency point with the same frequency value form a reference frequency point group, and calculate the amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group;
[0146] Determine whether the amplitude ratio corresponding to each reference frequency point group is within a preset range, and obtain the total number of reference frequency point groups whose amplitude ratios are within the preset range;
[0147] If the total number is not less than the preset threshold, it is determined that a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points.
[0148] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0149] The amplitude of the synchronization reference signal is adjusted according to the amplitude ratio that meets the matching condition.
[0150] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0151] The signal to be processed is filtered to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0152] Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0153] Based on the echo cancellation algorithm and the synchronization reference signal, echo cancellation is performed on the echo processing signal.
[0154] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0155] The audio signal outside the preset frequency range in the signal to be processed is filtered out, wherein the preset frequency range is 20 Hz to 20 kHz.
[0156] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0157] extracting an audio signal with a frequency range of 4kHz to 20kHz from the echo processing signal as a synchronous comparison signal;
[0158] Determine a first reference time set according to a time period corresponding to the reference signal, and determine a second reference time set according to a time period corresponding to the synchronous comparison signal;
[0159] Determine the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set;
[0160] According to the time difference, the starting time point and the ending time point of the reference signal are adjusted.
[0161] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0162] Select any first reference time from the first reference time set as the first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to the frequency distribution of the signal amount of the reference signal at the first target reference time;
[0163] Select a second reference time that has not been selected from the second reference time set and use it as the comparison time; determine a second preset number of second reference frequency points corresponding to the comparison time according to the frequency distribution of the signal amount of the synchronous comparison signal at the comparison time and a first preset number of first reference frequency points corresponding to the first target reference time; and judge whether the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition; if not, repeat the above process of selecting the second reference time, determining the second reference frequency points corresponding to the comparison time, and judging until the first preset number of first reference frequency points and the second preset number of second reference frequency points meet a matching condition, and use the second reference time selected when the matching condition is met as the second target reference time;
[0164] A time difference between the echo processing signal and the reference signal is determined according to the first target reference time and the second target reference time.
[0165] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0166] The first reference frequency point and the second reference frequency point with the same frequency value form a reference frequency point group, and calculate the amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group;
[0167] Determine whether the amplitude ratio corresponding to each reference frequency point group is within a preset range, and obtain the total number of reference frequency point groups whose amplitude ratios are within the preset range;
[0168] If the total number is not less than the preset threshold, it is determined that a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points.
[0169] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0170] The amplitude of the synchronization reference signal is adjusted according to the amplitude ratio that meets the matching condition.
[0171] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:
[0172] The signal to be processed is filtered to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time;
[0173] Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal;
[0174] Based on the echo cancellation algorithm and the synchronization reference signal, echo cancellation is performed on the echo processing signal.
[0175] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0176] The audio signal outside the preset frequency range in the signal to be processed is filtered out, wherein the preset frequency range is 20 Hz to 20 kHz.
[0177] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0178] extracting an audio signal with a frequency range of 4kHz to 20kHz from the echo processing signal as a synchronous comparison signal;
[0179] Determine a first reference time set according to a time period corresponding to the reference signal, and determine a second reference time set according to a time period corresponding to the synchronous comparison signal;
[0180] Determine the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set;
[0181] According to the time difference, the starting time point and the ending time point of the reference signal are adjusted.
[0182] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0183] Select any first reference time from the first reference time set as the first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to the frequency distribution of the signal amount of the reference signal at the first target reference time;
[0184] Select a second reference time that has not been selected from the second reference time set and use it as the comparison time; determine a second preset number of second reference frequency points corresponding to the comparison time according to the frequency distribution of the signal amount of the synchronous comparison signal at the comparison time and a first preset number of first reference frequency points corresponding to the first target reference time; and judge whether a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points; if not, repeat the above process of selecting the second reference time, determining the second reference frequency points corresponding to the comparison time, and judging until a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points; and use the second reference time selected when the matching condition is satisfied as the second target reference time;
[0185] A time difference between the echo processing signal and the reference signal is determined according to the first target reference time and the second target reference time.
[0186] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0187] The first reference frequency point and the second reference frequency point with the same frequency value form a reference frequency point group, and calculate the amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group;
[0188] Determine whether the amplitude ratio corresponding to each reference frequency point group is within a preset range, and obtain the total number of reference frequency point groups whose amplitude ratios are within the preset range;
[0189] If the total number is not less than the preset threshold, it is determined that a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points.
[0190] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0191] The amplitude of the synchronization reference signal is adjusted according to the amplitude ratio that meets the matching condition.
[0192] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.
[0193] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0194] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0195] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. An echo cancellation method, It is characterized in that The method comprises: Filtering the signal to be processed to obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time; Using the audio signal output by the audio device to the speaker as a reference signal, synchronizing the reference signal based on the echo processing signal to obtain a synchronization reference signal; Based on the echo cancellation algorithm and the synchronization reference signal, performing echo cancellation on the echo processing signal; The synchronizing the reference signal based on the echo processing signal comprises: Extracting an audio signal with a frequency range of 4 kHz to 20 kHz from the echo processing signal as a synchronous comparison signal; Determine a first reference time set according to the time period corresponding to the reference signal, and determine a second reference time set according to the time period corresponding to the synchronous comparison signal; Determine the time difference between the echo processing signal and the reference signal according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set, and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set; According to the time difference, adjusting the starting time point and the ending time point of the reference signal; The determining, according to the frequency distribution of the signal amount of the reference signal at each first reference time in the first reference time set, and the frequency distribution of the signal amount of the synchronous comparison signal at each second reference time in the second reference time set, the time difference between the echo processing signal and the reference signal comprises: Select any first reference time from the first reference time set as a first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to the frequency distribution of the signal amount of the reference signal at the first target reference time; Select a second reference time that has not been selected from the second reference time set and use it as the comparison time; determine a second preset number of second reference frequency points corresponding to the comparison time according to the frequency distribution of the signal amount of the synchronous comparison signal at the comparison time and a first preset number of first reference frequency points corresponding to the first target reference time; and judge whether a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points; if not, repeat the above process of selecting the second reference time, determining the second reference frequency points corresponding to the comparison time, and judging until the matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points; and use the second reference time selected when the matching condition is satisfied as the second target reference time; A time difference between the echo processing signal and the reference signal is determined according to the first target reference time and the second target reference time.
2. The method according to claim 1, It is characterized in that The filtering of the signal to be processed to obtain the echo processing signal includes: The audio signal outside a preset frequency range in the signal to be processed is filtered out, and the preset frequency range is 20 Hz to 20 kHz.
3. The method according to claim 1, It is characterized in that The first preset number is the same as the second preset number and both are not less than 2; for any first reference frequency point in the first preset number of first reference frequency points, there is a second reference frequency point with the same frequency value in the second preset number of second reference frequency points; Correspondingly, the determining whether the first preset number of first reference frequency points and the second preset number of second reference frequency points satisfy a matching condition includes: The first reference frequency point and the second reference frequency point with the same frequency value form a reference frequency point group, and calculate the amplitude ratio between the first reference frequency point and the second reference frequency point in each reference frequency point group; Determine whether the amplitude ratio corresponding to each reference frequency point group is within a preset range, and obtain the total number of reference frequency point groups whose amplitude ratios are within the preset range; If the total number is not less than the preset threshold, it is determined that the first preset number of first reference frequency points and the second preset number of second reference frequency points satisfy a matching condition.
4. The method according to claim 1, It is characterized in that Before performing echo cancellation on the echo processed signal based on the echo cancellation algorithm and the synchronization reference signal, the method includes: The amplitude of the synchronization reference signal is adjusted according to the amplitude ratio that meets the matching condition.
5. An echo cancellation device, It is characterized in that The device comprises: A first acquisition module is used to filter the signal to be processed and obtain an echo processing signal, wherein the signal to be processed is the sound generated after the audio signal output by the audio device to the speaker is played by the speaker and the sound emitted by a person is collected by the microphone at the same time; A synchronization module, configured to use the audio signal output by the audio device to the speaker as a reference signal, and synchronize the reference signal based on the echo processing signal to obtain a synchronization reference signal; An echo cancellation module, configured to perform echo cancellation on the echo processing signal based on an echo cancellation algorithm and the synchronization reference signal, and output a human voice after the echo cancellation; An amplitude adjustment module, used for adjusting the amplitude of the signal output by the synchronization module; The synchronization module comprises: An extraction submodule, used for extracting an audio signal with a frequency range of 4kHz to 20kHz from the echo processing signal as a synchronous comparison signal; A first determination submodule, configured to determine a first reference time set according to a time period corresponding to the reference signal, and to determine a second reference time set according to a time period corresponding to the synchronous comparison signal; A first determination submodule, configured to determine a time difference between the echo processing signal and the reference signal according to a frequency distribution of a signal amount of the reference signal at each first reference time in the first reference time set, and a frequency distribution of a signal amount of the synchronous comparison signal at each second reference time in the second reference time set; An adjustment module, used to adjust the starting time point and the ending time point of the reference signal according to the time difference; The first determining submodule includes: A first determining unit, configured to select any first reference time from the first reference time set as a first target reference time, and determine a first reference frequency point corresponding to the first target reference time according to a frequency distribution of a signal amount of the reference signal at the first target reference time; a judgment unit, configured to select a second reference moment that has not been selected from the second reference moment set and use it as a comparison moment, determine a second preset number of second reference frequency points corresponding to the comparison moment according to the frequency distribution of the signal quantity of the synchronous comparison signal at the comparison moment and a first preset number of first reference frequency points corresponding to the first target reference moment, and judge whether a matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points; if not, repeat the above-mentioned process of selecting the second reference moment, determining the second reference frequency point corresponding to the comparison moment, and judging until the matching condition is satisfied between the first preset number of first reference frequency points and the second preset number of second reference frequency points, and use the second reference moment selected when the matching condition is satisfied as the second target reference moment; The second determining unit is used to determine the time difference between the echo processing signal and the reference signal according to the first target reference time and the second target reference time.
6. A computer device comprising a memory and a processor, wherein the memory stores a computer program, It is characterized in that When the processor executes the computer program, the steps of the method according to any one of claims 1 to 4 are implemented.
7. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 4 are implemented.
8. A computer program product comprising a computer program, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 4 are implemented.
Citation Information
Patent Citations
Echo cancellation method and device based on time delay estimation
CN107610713A
Method and equipment for eliminating echo
CN111402910A