CN114040309B - Wind noise detection method and device, electronic equipment and storage medium - Google Patents

Wind noise detection method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN114040309B
CN114040309B CN202111122238.8A CN202111122238A CN114040309B CN 114040309 B CN114040309 B CN 114040309B CN 202111122238 A CN202111122238 A CN 202111122238A CN 114040309 B CN114040309 B CN 114040309B
Authority
CN
China
Prior art keywords
audio signal
spectrum information
determining
information
correlation coefficient
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202111122238.8A
Other languages
Chinese (zh)
Other versions
CN114040309A (en
Inventor
张锐
段爽
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Xiaomi Mobile Software Co Ltd
Beijing Xiaomi Pinecone Electronic Co Ltd
Original Assignee
Beijing Xiaomi Mobile Software Co Ltd
Beijing Xiaomi Pinecone Electronic Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Xiaomi Mobile Software Co Ltd, Beijing Xiaomi Pinecone Electronic Co Ltd filed Critical Beijing Xiaomi Mobile Software Co Ltd
Priority to CN202111122238.8A priority Critical patent/CN114040309B/en
Publication of CN114040309A publication Critical patent/CN114040309A/en
Application granted granted Critical
Publication of CN114040309B publication Critical patent/CN114040309B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R29/00Monitoring arrangements; Testing arrangements
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L21/00Speech or voice signal processing techniques to produce another audible or non-audible signal, e.g. visual or tactile, in order to modify its quality or its intelligibility
    • G10L21/02Speech enhancement, e.g. noise reduction or echo cancellation
    • G10L21/0208Noise filtering
    • G10L21/0216Noise filtering characterised by the method used for estimating noise
    • G10L21/0232Processing in the frequency domain
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R1/00Details of transducers, loudspeakers or microphones
    • H04R1/10Earpieces; Attachments therefor ; Earphones; Monophonic headphones
    • H04R1/1041Mechanical or electronic switches, or control elements
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R1/00Details of transducers, loudspeakers or microphones
    • H04R1/10Earpieces; Attachments therefor ; Earphones; Monophonic headphones
    • H04R1/1083Reduction of ambient noise
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R2201/00Details of transducers, loudspeakers or microphones covered by H04R1/00 but not provided for in any of its subgroups
    • H04R2201/10Details of earpieces, attachments therefor, earphones or monophonic headphones covered by H04R1/10 but not provided for in any of its subgroups
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R2460/00Details of hearing devices, i.e. of ear- or headphones covered by H04R1/10 or H04R5/033 but not provided for in any of their subgroups, or of hearing aids covered by H04R25/00 but not provided for in any of its subgroups
    • H04R2460/01Hearing devices using active noise cancellation

Landscapes

  • Engineering & Computer Science (AREA)
  • Signal Processing (AREA)
  • Physics & Mathematics (AREA)
  • Acoustics & Sound (AREA)
  • Health & Medical Sciences (AREA)
  • Otolaryngology (AREA)
  • General Health & Medical Sciences (AREA)
  • Computational Linguistics (AREA)
  • Quality & Reliability (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Human Computer Interaction (AREA)
  • Multimedia (AREA)
  • Circuit For Audible Band Transducer (AREA)
  • Soundproofing, Sound Blocking, And Sound Damping (AREA)

Abstract

The present disclosure relates to a wind noise detection method applied to an earphone, wherein the earphone is provided with a first audio signal collector and a second audio signal collector; the method comprises the following steps: acquiring first frequency spectrum information of a first audio signal acquired by the first audio signal acquisition unit and second frequency spectrum information of a second audio signal acquired by the second audio signal acquisition unit; determining a first correlation coefficient of frequency between the first audio signal and the second audio signal according to the first frequency spectrum information and the second frequency spectrum information; determining a second correlation coefficient of the amplitude between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information; and determining whether wind noise exists in the environment where the earphone is positioned according to the first correlation coefficient and the second correlation coefficient.

Description

Wind noise detection method and device, electronic equipment and storage medium
Technical Field
The disclosure relates to the field of signal processing, and in particular relates to a wind noise detection method, a device, electronic equipment and a storage medium.
Background
In daily life, external wind noise exists in most cases, and the external wind noise has certain influence on sleeping, work, learning, entertainment and the like. For example, when a headset such as an earphone is used for related activities such as work, learning or entertainment, if wind noise exists in the environment, the wind noise affects the effect of the headset.
The earphone can reduce the influence of wind noise on the output effect of the earphone through the noise reduction technology, wind noise is detected before noise reduction, and corresponding noise reduction processing is carried out according to the detected noise.
Disclosure of Invention
The disclosure provides a wind noise detection method, a wind noise detection device, electronic equipment and a storage medium.
In a first aspect of embodiments of the present disclosure, a wind noise detection method is provided and applied to an earphone, where the earphone has a first audio signal collector and a second audio signal collector; the method comprises the following steps: acquiring first frequency spectrum information of a first audio signal acquired by the first audio signal acquisition unit and second frequency spectrum information of a second audio signal acquired by the second audio signal acquisition unit; determining a first correlation coefficient between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information; determining a second correlation coefficient of the amplitude between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information; and determining whether wind noise exists in the environment where the earphone is positioned according to the first correlation coefficient and the second correlation coefficient.
In one embodiment, the determining a first correlation coefficient between frequencies of the first audio signal and the second audio signal according to the first spectral information and the second spectral information includes: determining a first power spectral density of the first spectral information according to the first spectral information; determining a second power spectral density of the second spectral information according to the second spectral information; determining a cross-correlation power spectral density of the first audio signal and the second audio signal from the first spectral information, the second spectral information, the first power spectral density and the second power spectral density; and determining the first correlation coefficient according to the cross-correlation power spectral density.
In one embodiment, said determining said first correlation coefficient from said cross-correlation power spectral density comprises: determining a characterization coefficient of the cross-correlation power spectral density according to the cross-correlation power spectral density; determining the first correlation coefficient according to the characterization coefficient and the weight of the characterization coefficient; wherein the weights are determined from the first audio signal and the second audio signal.
In one embodiment, the determining a second correlation coefficient of the amplitude between the first audio signal and the second audio signal according to the first spectral information and the second spectral information includes: determining first amplitude spectrum information of the first audio signal according to the first frequency spectrum information; determining second amplitude spectrum information of the first audio signal according to the second frequency spectrum information; and determining the second correlation coefficient based on the first amplitude spectrum information and the second amplitude spectrum information through a correlation coefficient algorithm.
In one embodiment, the first spectral information and the second spectral information each comprise M frames of audio signal frames; the determining whether wind noise exists in the environment where the earphone is located according to the first correlation coefficient and the second correlation coefficient comprises: determining that the first correlation coefficient is smaller than a first preset correlation coefficient and the second correlation number is smaller than the frame number of the audio signal frames of a second preset correlation coefficient within a preset duration; and when the duty ratio of the total frame number of the audio signal frames in the preset duration is larger than a duty ratio threshold value, determining that wind noise exists.
In one embodiment, the method further comprises: when the wind noise is determined to exist, determining the wind noise level according to the average value of the first correlation coefficient corresponding to the r-frame audio signal frames in the preset duration; wherein r is less than M.
In one embodiment, the acquiring the first spectrum information of the first audio signal acquired by the first audio signal acquisition unit and the second spectrum information of the second audio signal acquired by the second audio signal acquisition unit includes: framing and windowing the first audio signal; said framing and said windowing of said second audio signal; the frame length and the frame shift of the first audio signal and the second audio signal after the framing are the same; the frame length is the same as the window length of the windowed frame; converting the first audio signal subjected to framing and windowing from a time domain to a frequency domain to obtain the first spectrum information; and converting the second audio signal subjected to framing and windowing from a time domain to a frequency domain to obtain the second spectrum information.
In one embodiment, when it is determined that wind noise exists, a control strategy corresponding to the current wind noise level is selected to control the earphone according to a preset corresponding relation between the wind noise level and the control strategy.
In a second aspect of embodiments of the present disclosure, a wind noise detection apparatus is provided, which is applied to an earphone, where the earphone has a first audio signal collector and a second audio signal collector; the method comprises the following steps: the frequency spectrum information acquisition module is used for acquiring first frequency spectrum information of the first audio signal acquired by the first audio signal acquisition unit and second frequency spectrum information of the second audio signal acquired by the second audio signal acquisition unit; a first correlation coefficient determining module, configured to determine a first correlation coefficient of a frequency between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information; a second correlation number determining module, configured to determine a second correlation coefficient of an amplitude between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information; and the wind noise determining module is used for determining whether wind noise exists in the environment where the earphone is positioned according to the first correlation coefficient and the second correlation coefficient.
In a third aspect of the disclosed embodiments, there is provided an electronic device, including:
a processor and a memory for storing executable instructions capable of executing on the processor, wherein: the processor is configured to execute the executable instructions that, when executed, perform the method of any of the embodiments described above.
In a fourth aspect of the disclosed embodiments, there is provided a non-transitory computer-readable storage medium having stored therein computer-executable instructions that, when executed by a processor, implement the method of any of the above embodiments.
The technical scheme provided by the embodiment of the disclosure can comprise the following beneficial effects:
according to the embodiment of the disclosure, the first frequency spectrum information of the first audio signal acquired by the first audio signal acquisition unit is acquired through the first audio signal acquisition unit in the earphone, and the second frequency spectrum information of the second audio signal acquired by the second audio signal acquisition unit is acquired through the second audio signal acquisition unit. Then, according to the first frequency spectrum information and the second frequency spectrum information, determining a first correlation coefficient of the frequency between the first audio signal and the second audio signal; determining a second correlation coefficient of the amplitude between the first audio signal and the second audio signal according to the first frequency spectrum information and the second frequency spectrum information; and determining whether wind noise exists in the environment where the earphone is positioned according to the first correlation coefficient and the second correlation coefficient. And combining a first correlation coefficient related to frequency and a second correlation coefficient related to amplitude between the first audio signal and the second audio signal to comprehensively determine whether wind noise exists, thereby improving the detection accuracy of the wind noise and reducing the occurrence of false detection or omission of the wind noise in certain application scenes.
It is to be understood that both the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the disclosure.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description, serve to explain the principles of the disclosure.
FIG. 1 is a flow chart illustrating a wind noise detection method according to an exemplary embodiment;
FIG. 2 is a flow diagram illustrating a process for acquiring first and second spectral information according to an exemplary embodiment;
FIG. 3 is a flow chart illustrating a process for determining a first correlation coefficient according to an exemplary embodiment;
FIG. 4 is a schematic flow chart illustrating another method of determining a first correlation coefficient according to an exemplary embodiment;
FIG. 5 is a schematic flow chart diagram illustrating one method of determining a second phase relationship in accordance with an exemplary embodiment;
FIG. 6 is a schematic diagram illustrating one method of determining wind noise of a headset according to an exemplary embodiment;
FIG. 7 is a schematic diagram illustrating another detection of wind noise according to an example embodiment;
FIG. 8 is a schematic diagram illustrating one specific application scenario in accordance with an exemplary embodiment;
Fig. 9 is a schematic structural view of a wind noise detection apparatus according to an exemplary embodiment;
fig. 10 is a block diagram of a terminal device according to an exemplary embodiment.
Detailed Description
Reference will now be made in detail to exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numbers in different drawings refer to the same or similar elements, unless otherwise indicated. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus consistent with some aspects of the disclosure as detailed in the accompanying claims.
With the development of noise reduction technology, headphones have active noise reduction functions, such as headphones and the like. However, when the earphone is in a wearing state, the earphone is influenced by wind noise of the environment. For example, when the environment is a road, natural wind may exist, wind noise may be generated during walking, running or riding, and the wind noise may affect the active noise reduction experience of the noise reduction earphone.
Headphones such as headphones have a plurality of audio signal collectors such as a feedforward audio signal collector, a talk audio signal collector, a feedback audio signal collector, and the like. Wind noise mainly affects the feedforward noise reduction of the earphone. Principle of feedforward noise reduction: wind noise is collected by a feedforward audio signal collector, such as a feedforward microphone, and then is cancelled by a feedforward filter in acoustic wave opposition. But wind noise is non-stationary noise which changes rapidly, the change rate of an inverted signal generated by the feedforward filter is smaller than that of the wind noise, and the wind noise is difficult to be counteracted correctly, so that the active noise reduction effect is affected.
The earphone makes noise reduction in two ways:
firstly, the earphone reduces the influence of wind noise from the hardware level by adding a physical wind noise resistant mode.
Secondly, a wind noise detection algorithm is used, after corresponding wind noise is detected, the gain of the feedforward audio signal collector is reduced, or the noise reduction of the feedforward audio signal collector is closed, only feedback noise reduction is used, and the influence of wind noise is reduced from a software level.
Of course, other noises besides wind noise, for example, other noises besides the audio signal output by the earphone, which all belong to the environmental noise, can be reduced.
In general, before noise reduction is performed on environmental noise, such as wind noise, the environmental noise needs to be detected, and after the environmental noise is detected, the noise is reduced through a corresponding noise reduction technology, so that a better noise reduction effect is obtained. In general, environmental noise is detected by frequency domain cross-correlation information of a feedforward audio signal collector and a call audio signal collector, for example, the environmental noise is determined according to an average value of cross-correlation coefficients of certain frequency bands, and a type of noise matching with the average value can be determined according to the average value, and the like.
The detection mode of the environmental noise, such as wind noise, is to detect the environmental noise only through the frequency domain cross-correlation information of the feedforward audio signal collector and the call audio signal collector, so that the detection accuracy is low, and the corresponding environmental noise cannot be accurately detected in certain application scenes, so that the wind noise cannot be accurately reduced.
Referring to fig. 1, a flow chart of a wind noise detection method provided in the present technical solution is provided, where the detection method may be applied to an earphone, and the earphone has a first audio signal collector and a second audio signal collector. The earphone can be provided with a plurality of audio signal collectors, such as earphones, and the like, and the audio signals of the environment can be collected through the audio signal collectors, so that wind noise can be detected according to the collected audio signals. In this embodiment, the headset has at least a first audio signal collector, which may be a feedforward audio signal collector, which may be a microphone or the like, and a second audio signal collector. The second audio signal collector can be used for a call audio signal collector for a call, and the call audio signal collector can collect environmental noise, such as wind noise, of the environment where the call audio signal collector is located in addition to collecting the call audio signal.
In one embodiment, when the earphone is a wearable device such as an earphone, the earphone may be an in-ear earphone or a semi-in-ear earphone with different structures. When the earphone is in a wearing state, a part of the earphone faces the auditory canal, a part of the earphone faces away from the auditory canal, and the first audio signal collector, namely a collection through hole of the feedforward audio signal collector, can be positioned on the outer surface of the earphone facing away from the auditory canal, so that wind noise can be collected conveniently. The second audio signal collector, namely the collection through hole of the conversation audio signal collector, can be located at the position where the earphone is close to the sounding of the mouth and the like. The first audio signal collector and the second audio signal collector are not directed towards the ear canal or towards a feedback audio signal collector within the ear canal, such as a feedback microphone or the like.
The method comprises the following steps:
step S100, acquiring first frequency spectrum information of a first audio signal acquired by a first audio signal acquisition unit and second frequency spectrum information of a second audio signal acquired by a second audio signal acquisition unit.
Step S200, determining a first correlation coefficient of a frequency between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information.
Step S300, determining a second correlation coefficient of the amplitude between the first audio signal and the second audio signal according to the first spectral information and the second spectral information.
Step S400, determining whether wind noise exists in the environment where the earphone is located according to the first correlation coefficient and the second correlation coefficient.
For step S100, the first spectral information of the first audio signal may be acquired by the first audio signal acquisition unit, and the second spectral information of the second audio signal may be acquired by the second audio signal acquisition unit.
In this embodiment, the audio signal collected by the first audio signal collector is taken as a first audio signal, and the spectrum information of the first audio signal is taken as a first spectrum information. And taking the audio signal acquired by the second audio signal acquisition unit as a second audio signal, and taking the frequency spectrum information of the first audio signal as second frequency spectrum information.
After the first audio signal collector collects the first audio signal, the first frequency spectrum information of the first audio signal can be obtained, and after the second audio signal collector collects the second audio signal, the second frequency spectrum information of the second audio signal can be obtained. The specific acquisition process is not limited herein, and the manner in which the first spectral information can be obtained from the first audio signal and the manner in which the second spectral information can be obtained from the second audio signal are both within the scope of protection of the embodiment. It is within the scope of this embodiment that the first audio signal and the second audio signal are typically time domain signals, the first spectral information being frequency domain information of the first audio signal, the second spectral signal being frequency domain information of the second audio signal, the manner in which the first audio signal is converted from time domain to frequency domain first spectral information and the second audio signal is converted from time domain to frequency spectrum second spectral information.
The specific procedure of acquiring the first spectrum information and the second spectrum information may refer to the subsequent embodiment, and may be specifically converted by a Fast Fourier Transform (FFT) or the like.
With step S200, after the first spectrum information and the second spectrum signal are acquired, a first correlation coefficient of a frequency between the first audio signal and the second audio signal may be determined according to the first spectrum information and the second spectrum information.
The first correlation coefficient of the frequency between the first audio signal and the second audio signal, which may also be referred to as the correlation coefficient of the complex spectrum between the first audio signal and the second audio signal, is taken as the first correlation coefficient and belongs to a kind of cross correlation coefficient between the first audio signal and the second audio signal. The first spectral information and the second spectral information are both spectral information represented in complex form, from which a first correlation coefficient of a complex spectrum between the first audio signal and the second audio signal can be determined.
The first correlation coefficient represents a coefficient of correlation of the first audio signal and the second audio signal in the complex spectrum. The specific process of determining the first correlation coefficient is not limited herein, and reference is made to the following embodiments.
In step S300, after the first spectrum information and the second spectrum signal are acquired, a second correlation coefficient of the amplitude between the first audio signal and the second audio signal may be determined according to the first spectrum information and the second spectrum information.
Since the first spectral information and the second spectral information are both spectral information identified in complex form, real spectral information of the first audio signal may be determined from the first spectral information, and real spectral information, also referred to as amplitude spectrum, of the second audio signal may be determined from the second spectral information. Then, a second correlation coefficient of the amplitude between the first audio signal and the second audio signal can be determined based on the amplitude spectrum information of the first audio signal and the amplitude spectrum information of the second audio signal, which belongs to another cross-correlation coefficient between the first audio signal and the second audio signal.
The second correlation coefficient represents a coefficient of correlation of the first audio signal and the second audio signal in terms of amplitude spectrum, and the first correlation coefficient and the second correlation coefficient are two different correlation coefficients. The specific process of determining the second correlation coefficient is not limited herein, and reference is made to the following embodiments. There is no necessarily sequential relationship between step S200 and step S300.
In step S400, after the first correlation coefficient and the second correlation coefficient are determined, since the first correlation coefficient and the second correlation coefficient are based on the correlation coefficients of different dimensions between the first spectrum information and the second spectrum information, it can be determined whether the environment where the earphone is located has wind noise according to the first correlation coefficient and the second correlation coefficient.
And combining a first correlation coefficient related to frequency and a second correlation coefficient related to amplitude between the first audio signal and the second audio signal to comprehensively determine wind noise, thereby improving the detection accuracy of the wind noise and reducing the occurrence of false detection or omission detection of the wind noise in certain application scenes.
The wind noise may be used to determine whether there is wind noise reaching a detectable intensity, e.g., whether wind noise and/or wind noise level is detected.
In another embodiment, referring to fig. 2, a flowchart of acquiring first spectrum information and second spectrum information is shown.
Step S100, acquiring first spectrum information of a first audio signal acquired by a first audio signal acquisition unit and second spectrum information of a second audio signal acquired by a second audio signal acquisition unit may specifically include:
step S101, framing and windowing the first audio signal.
Step S102, framing and windowing the second audio signal; the frame length and the frame shift of the first audio signal and the second audio signal after framing are the same; the frame length is the same as the window length of the windowing.
Step S103, converting the first audio signal after framing and windowing from the time domain to the frequency domain, and obtaining the first spectrum information.
Step S104, converting the second audio signal after framing and windowing from the time domain to the frequency domain to obtain second spectrum information.
For step S101 and step S102, after the first audio signal collector collects the first audio signal, the earphone may perform framing and windowing processing on the first audio signal. After the second audio signal collector collects the second audio signal, the earphone can perform framing and time domain windowing processing on the second audio signal. The framing and windowing process performed by the headset on the first audio signal is the same as the framing and windowing process performed by the headset on the second audio signal. The first audio signal and the second audio signal are signals in the time domain.
In this embodiment, the first audio signal collector and the second audio signal collector may collect audio signals at the same sampling rate, and obtain the first audio signal and the second audio signal, respectively. The sampling rate may be 48000HZ, 16000HZ, 8000HZ, 4000HZ, etc. After the first audio signal and the second audio signal are respectively subjected to the same framing, the obtained frame lengths are the same, for example, 16ms, 32ms, 64ms, or the like. In order to make the transition between frames smooth and maintain its continuity, there is a frame shift between two adjacent frames, which may be half the frame length when framing.
After framing the first audio signal and the second audio signal, respectively, the framed information may also be windowed. The windowing process can reduce the error between the signal after framing and the original signal, so that the signal after framing becomes continuous and each frame can show the characteristic of a periodic function. A hamming window or hanning window or other window function may be used, the window length being the same as the frame length, spectral leakage or the like may be reduced.
The first audio signal may be framed and windowed by specifically formula (1) as follows:
ff(n,m)=f((m-1)*inc+n)*w(n),0≤n≤(L-1) (1)
framing and windowing the second audio signal by the following formula (2):
tt(n,m)=t((m-1)*inc+n)*w(n),0≤n≤(L-1) (2)
Where f (n) denotes the first audio signal, t (n) denotes the second audio signal, ff (n, m) denotes the first audio signal after windowing, tt (n, m) denotes the second audio signal after windowing, and w (n) is a window function. M represents an index of the number of frames after framing, and divides the first audio signal and the second audio signal into M frames of audio signal, respectively. n represents an index of sampled data points for an mth frame of audio signal frame, each frame of audio signal frame including n sampled data points. L represents the frame length and inc represents the frame shift.
Equation (1) and equation (2) are the same equations, and are convenient for representing the first audio signal after windowing and the second audio signal after windowing, and are represented by equations (1) and (2), respectively. There is a corresponding conversion relationship between the unit of L in hz and the unit of ms, for example, when the frame length is 32ms, the frame length in hz is equal to L512, the frame shift is equal to inc256, and the specific conversion process will not be described in detail.
The information ff (n, m) after framing and windowing of the first audio signal and the information tt (n, m) after framing and windowing of the second audio signal are obtained by the formula (1) and the formula (2), respectively. The first audio signal comprises M frames of audio signal frames after framing and windowing, and the second audio signal comprises M frames of audio signal frames after framing and windowing.
The first audio signal ff (n, m) after framing and windowing is converted from the time domain to the frequency domain, resulting in first spectral information F (k, m), via step S103.
The second audio signal tt (n, m) after framing and windowing is converted from the time domain to the frequency domain, resulting in second spectral information T (k, m), via step S104. Where K in F (K, m) and T (K, m) represents indexes of frequency points, n is converted into K after ff (n, m) and tt (n, m) are converted from a time domain to a frequency domain, and K frequency points are included in an mth frame of audio signal frame.
F (k, m) represents first spectral information of n sample data points included in the m-th frame of audio signal frame, i.e., first spectral information of the k-th frequency point in the m-th frame of audio signal frame. Synthesizing first spectrum information of each frequency point in the m-th frame of audio signal frame, namely the first spectrum information of the m-th frame of audio signal frame of the first audio signal; and synthesizing the first frequency spectrum information of each frequency point in the M frames of audio signal frames, namely the first frequency spectrum information of the first audio signal. T (k, m) represents second spectrum information of n sampling data points included in the m-th frame of audio signal frame, i.e., second spectrum information of the k-th frequency point in the m-th frame of audio signal frame. Synthesizing second spectrum information of each frequency point in the m-th frame of audio signal frame, namely the second spectrum information of the m-th frame of audio signal frame of the second audio signal; and synthesizing second spectrum information of each frequency point in the M frames of audio signal frames, namely the second spectrum information of the second audio signal.
The frequency spectrum information of K frequency points of each audio signal frame in the M audio signal frames in the first audio signal can be obtained through the steps, namely the first frequency spectrum information of the first audio signal, and the frequency spectrum information of K frequency points of each audio signal frame in the M audio signal frames in the second audio signal can be obtained, namely the second frequency spectrum information of the second audio signal.
In another embodiment, referring to fig. 3, a flowchart of determining a first correlation coefficient is shown. Step S200, determining a first correlation coefficient between frequencies of the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information, including:
step S201, determining a first power spectral density of the first spectrum information according to the first spectrum information.
Step S202, determining a second power spectral density of the second spectral information according to the second spectral information.
Step S203, determining a cross-correlation power spectral density of the first audio signal and the second audio signal according to the first spectral information, the second spectral information, the first power spectral density and the second power spectral density.
Step S204, determining a first correlation coefficient according to the cross-correlation power spectral density.
The manner in which the first power spectral density can be determined according to the first spectral information, the manner in which the second power spectral density of the second spectral information is determined according to the second spectral information, the manner in which the cross-correlation power spectral density of the first audio signal and the second audio signal is determined according to the first spectral information, the second spectral information, the first power spectral density and the second power spectral density, and the manner in which the first correlation coefficient is determined according to the cross-correlation power spectral density are all within the protection scope of this embodiment, and reference is made to the following embodiments for a specific procedure.
In one embodiment, the first spectral information is spectral information comprising M frames of an audio signal frame; the M-th frame of audio signal frame comprises K frequency points, wherein M is more than or equal to 1 and less than or equal to M.
For step S201, determining a first power spectral density of the first spectral information according to the first spectral information, including: a first power spectral density of spectral information of a kth frequency point in an mth frame of audio signal frames in the first spectral information is determined.
Determining the first power spectral density of the spectral information of the kth frequency point in the mth frame of audio signal frames in the first spectral information comprises:
and determining the first power spectrum density of each frequency point in the M-th frame of audio signal frame in the first spectrum information according to the spectrum information of the k-th frequency point in the M-th frame of audio signal frame, the first power spectrum density of the k-th frequency point in the M-1-th frame of audio signal frame and the conjugate information of the spectrum information of the k-th frequency point in the M-th frame of audio signal frame. When m is equal to 1, the first power spectral density of the kth frequency point in the m-1 th frame of audio signal frame is 0.
Specifically, the following formula (3) can be referred to:
wherein,representing the power spectral density of the kth frequency point in the mth frame of the audio signal frame in the first frequency spectrum, F * (k, m) represents conjugated information of F (k, m), and +_ >A first power spectral density representing a kth frequency bin in an m-1 st frame of the audio signal frame. Alpha is a smoothing coefficient and is a constant.
By the embodiment, the first power spectral density of each frequency point in each audio signal frame in m audio signal frames in the first frequency spectrum information, namely the first power spectral density of the first frequency spectrum information, can be determined. The first power spectral density is in complex form.
For step S202, after determining the second spectral information, a second power spectral density may be determined from the second spectral information. The method of determining the second power spectral density is the same as the method of determining the first power spectral density.
In one embodiment, the second spectral information is spectral information comprising m frames of audio signal frames; the a-frame audio signal frame comprises K frequency points, wherein M is more than or equal to 1 and less than or equal to M.
For step S202, determining a second power spectral density of the second spectral information according to the second spectral information, including: and determining a second power spectral density of the spectral information of the kth frequency point in the mth frame of audio signal frame in the second spectral information.
Determining a second power spectral density of spectral information of a kth frequency point in an mth frame of audio signal frames in the second spectral information, comprising:
and determining the second power spectrum density of each frequency point in the M-th frame of audio signal frame in the second spectrum information according to the spectrum information of the k-th frequency point in the M-th frame of audio signal frame, the second power spectrum density of the k-th frequency point in the M-1-th frame of audio signal frame and the conjugate information of the spectrum information of the k-th frequency point in the M-th frame of audio signal frame. And when m is equal to 1, the second power spectral density of the kth frequency point in the m-1 th frame of audio signal frame is 0.
Specifically, the following formula (4) can be referred to:
wherein,representing the power spectral density, T, of the kth frequency point in the mth frame of the audio signal in the second frequency spectrum * (k, m) represents conjugated information of T (k, m), and +.>And a second power spectral density representing a kth frequency bin in an m-1 th frame of the audio signal frame. Alpha is a smoothing coefficient and is a constant.
By the embodiment, the second power spectral density of each frequency point in each audio signal frame in m audio signal frames in the second spectrum information, namely the second power spectral density of the second spectrum information, can be determined. The second power spectral density is in complex form.
In another embodiment, for step S203, determining the cross-correlation power spectral density of the first audio signal and the second audio signal according to the first spectral information, the second spectral information, the first power spectral density and the second power spectral density may include:
and determining the second power spectral density of the spectral information of the kth frequency point in the m-th audio signal frame in the first spectral information and the second power spectral density of the spectral information of the kth frequency point in the m-th audio signal frame in the second spectral information according to the first power spectral density of the spectral information of the kth frequency point in the m-th audio signal frame in the first spectral information and the second spectral information.
The method comprises the following steps:
and determining the cross-correlation power spectrum density of the kth frequency point in the M-th audio signal frame in the first frequency spectrum information and the second frequency spectrum information according to the first frequency spectrum information of the kth frequency point in the M-th audio signal frame, the conjugate information of the second frequency spectrum information of the kth frequency point in the M-th audio signal frame, the cross-correlation power spectrum density of the kth frequency point in the M-th audio signal frame, the first power spectrum density of the kth frequency point in the M-th audio signal frame and the second power spectrum density of the kth frequency point in the M-th audio signal frame in the first frequency spectrum information and the second frequency spectrum information.
When m is equal to 1, the cross-correlation power spectrum of the kth frequency point in the m-1 th frame of audio signal frame in the first frequency spectrum information and the second frequency spectrum information is 0.
Specifically, the following formulas (5) and (6) can be referred to
Wherein η (k, m) represents a cross-correlation power spectral density of a kth frequency point in an m-th frame of the audio signal frame in the first spectrum information and the second spectrum information, and the cross-correlation power spectral density is in a complex form.And representing the cross-correlation power spectrum of the kth frequency point in the m-th frame of audio signal frame in the first frequency spectrum information and the second frequency spectrum information.
By this embodiment, the cross-correlation power spectral densities of the frequency points in the M frames of the audio signal comprised by the first spectral information and the second spectral information can be determined.
In another embodiment, the cross-correlation power spectrum density of the kth frequency point in the M-th audio signal frame in the first spectrum information and the second spectrum information may be determined according to the second spectrum information of the kth frequency point in the M-th audio signal frame, the conjugate information of the first spectrum information of the kth frequency point in the M-th audio signal frame, the cross-correlation power spectrum density of the kth frequency point in the M-1 th audio signal frame, the first power spectrum density of the kth frequency point in the M-th audio signal frame, and the second power spectrum density of the kth frequency point in the M-th audio signal frame in the first spectrum information and the second spectrum information.
Referring to fig. 4, another process for determining the first correlation coefficient is shown. For step S204, determining a first correlation coefficient from the cross-correlation power spectral density comprises:
and determining a first correlation coefficient of the m-th frame of audio signal frame in the first frequency spectrum information and the second frequency spectrum information according to the cross-correlation power frequency spectrum density of the k-th frequency point in the m-th frame of audio signal frame in the first frequency spectrum information and the second frequency spectrum information.
The method specifically comprises the following steps:
step S2041, determining the characterization coefficient of the cross-correlation power spectral density according to the cross-correlation power spectral density.
Specifically, the method comprises the following steps: and determining the characterization coefficient of the cross-correlation power spectral density of the kth frequency point in the m-th audio signal frame in the first frequency spectrum information and the second frequency spectrum information according to the modulus of the cross-correlation power spectral density of the kth frequency point in the m-th audio signal frame in the first frequency spectrum information and the second frequency spectrum information.
The following formula (7) can be referred to:
υ(k,m)=|η(k,m)| (7)
wherein v (k, m) is a real number.
Step S2042, determining a first correlation coefficient according to the characterization coefficient and the weight of the characterization coefficient; wherein the weights for the characterization coefficients are determined from the first audio signal and the second audio signal.
Since the characterization coefficients are coefficients of cross-correlation power spectrum densities of the kth frequency point in the m-th audio signal frame in the first spectrum information and the second spectrum information, for the first spectrum information and the second spectrum information, each frequency point in each audio signal frame in each frame determines a corresponding characterization coefficient, and the characterization coefficients corresponding to different frequency points in the audio signal frames in different frames have respective weights (may also be referred to as weighting coefficients). Specifically, the first correlation coefficient of the m-th frame audio signal frame corresponding to the first audio signal and the second audio signal can be determined according to the sum of products of the characterization coefficients of all frequency points in the m-th frame audio signal frame and the corresponding weights.
Specifically, the following formula (8) can be referred to
Wherein ζ (m) represents a first correlation coefficient of an m-th frame of the audio signal frame corresponding to the first audio signal and the second audio signal,the weight of the characterization coefficient representing the cross-correlation power spectral density of the kth frequency point in the mth frame of audio signal frame, x and y are constants.
By increasing the weight of each characterization coefficient, the complex spectrum correlation of the kth frequency point of the first spectrum information and the second spectrum information in the mth frame of audio signal frame is improved, and the problems that the correlation is lower and difficult to measure caused by measuring the complex spectrum correlation of the first audio signal and the second audio signal in the mth frame of audio signal frame only in an equal form are solved.
The weight of the characterization coefficient may be determined according to the degree of influence of the first audio signal and the second audio signal on the first correlation, or may be preset.
In another embodiment, referring to fig. 5, a flow chart for determining a second phase relationship is shown, comprising:
step S301, determining first amplitude spectrum information of a first audio signal according to the first spectrum information;
step S302, determining second amplitude spectrum information of the first audio signal according to the second spectrum information;
step S303, determining a second correlation number based on the first amplitude spectrum information and the second amplitude spectrum information through a correlation coefficient algorithm.
After the first spectrum information is determined, the first amplitude spectrum information of the first audio signal is determined according to the first spectrum information, specifically, the first amplitude spectrum information of the kth frequency point in the mth frame of audio signal frame in the first spectrum information is determined according to the first spectrum information of the kth frequency point in the mth frame of audio signal frame corresponding to the first audio signal.
For example, it can be determined by the following formula (9):
FM(k,m)=|F(k,m)| (9)
similarly, the second amplitude spectrum information of the second audio signal may be determined according to the following formula (10), and specifically, the second amplitude spectrum information of the kth frequency point in the mth frame of audio signal frame in the second frequency spectrum information may be determined according to the second frequency spectrum information of the kth frequency point in the mth frame of audio signal frame corresponding to the second audio signal.
TM(k,m)=|T(k,m)| (10)
After the first amplitude spectrum information and the second amplitude spectrum information of the kth frequency point in the mth frame of audio signal frames corresponding to the first audio signal and the second audio signal are determined, a second correlation number, such as a pearson correlation coefficient, is determined by a correlation coefficient algorithm, and a second correlation coefficient p (m) between FM (k, m) and TM (k, m) is determined.
The second correlation coefficient is a correlation coefficient of an mth frame of audio signal frame corresponding to the first audio signal and an mth frame of audio signal frame corresponding to the second audio signal, namely a correlation coefficient of an mth frame of audio signal frame in the first frequency spectrum information and an mth frame of audio signal frame in the second frequency spectrum information.
Referring to fig. 6, a schematic diagram of determining wind noise of an earphone is provided. Step S400, determining whether wind noise exists in the environment where the earphone is located according to the first correlation coefficient and the second correlation coefficient, including:
In step S401, it is determined that the first correlation coefficient is smaller than the first preset correlation coefficient and the second correlation number is smaller than the frame number of the audio signal frames of the second preset correlation coefficient within the preset duration.
In step S402, when the duty ratio of the total frame number of the audio signal frames within the preset duration is greater than the duty ratio threshold, it is determined that wind noise exists.
According to the embodiment, wind noise exists in the environment where the earphone is located according to the first correlation coefficient and the second correlation number of at least one frame of audio signal frame corresponding to the first audio signal and the second audio signal in the preset time.
The preset duration may include one frame of audio signal frame, that is, according to the first correlation coefficient and the second correlation coefficient of the mth frame of audio signal frame corresponding to the first audio signal and the second audio signal, it is determined whether wind noise exists in the mth frame of audio signal frame corresponding to the first audio signal and the second audio signal.
It is also possible that: after the first correlation coefficient and the second correlation coefficient are determined, detecting the total frame number a1 of the audio signal frames in a preset time period, for example, 1 second or 2 seconds, and the total frame number of the first audio signal in the preset time period is the same as the total frame number of the second audio signal in the preset time period. And then determining the frame number r of the audio signal frames in which the first correlation coefficient is smaller than the first preset correlation coefficient and the second correlation coefficient is smaller than the second preset correlation coefficient in the preset time period, and if the duty ratio of the frame number r to the total frame number a1 exceeds a duty ratio threshold value, indicating that wind noise exists in the preset time period. The type of wind noise can be set according to specific application scenes, and can comprise the level and source of wind noise and the like.
The first preset correlation coefficient may be 0.95, the second preset correlation coefficient may be 1, and the duty ratio threshold may be determined according to actual requirements, for example, 80%.
Experiments show that wind noise detection is performed only through correlation of complex frequency spectrums, and inaccurate detection conditions in certain scenes, such as false detection conditions in subway scenes, can occur. By analyzing the false detection data, the amplitude spectrum in the subway scene is found to have strong correlation, and the reason that the complex spectrum correlation is weak is because the correlation of the spectrum phase is weak. Therefore, by combining the first correlation coefficient of the complex spectrum and the second correlation coefficient of the magnitude spectrum, wind noise is detected, and the accuracy of wind noise detection is improved. The first correlation coefficient of the complex spectrum may also determine a wind noise level.
In another embodiment, the method further comprises:
when the wind noise exists, determining the wind noise level of the wind noise according to the average value of the first correlation coefficient corresponding to the r-frame audio signal frame in the preset time period; wherein r is less than M.
And determining an arithmetic average value of the first correlation coefficients of the r frames of audio signal frames according to the respective first correlation coefficients of the r frames of audio signal frames in the preset time period, and determining the wind noise level according to the arithmetic average value. The preset wind noise level corresponds to a threshold range of the corresponding arithmetic mean, for example, the arithmetic mean is wind noise of a first level within a first threshold range, and when the arithmetic mean is within a second threshold range, the wind noise is determined to be wind noise of a second level. The first threshold range may be greater than the second threshold range, and the first level of wind noise may be higher than the second level of wind noise. If the first level of wind noise may be strong wind, the second level of wind noise may be weak wind, etc.
In another embodiment, when it is determined that wind noise exists, a control strategy corresponding to the current wind noise level is selected to control the earphone according to a preset corresponding relation between the wind noise level and the control strategy. The preset wind noise levels also correspond to corresponding control strategies, and corresponding relations, such as mapping relations and the like, exist between different wind noise levels and the control strategies, each wind noise level corresponds to one control strategy, and the control strategies corresponding to different wind noise levels can be different. The control strategy can be preset or can be adjusted according to actual requirements. After the control policy is determined according to the wind noise level, the headphones may be controlled, for example, noise reduction processing or the like, according to the control policy corresponding to the current wind noise level.
In another embodiment, wind noise includes: wind noise, voice noise, and the like.
In another embodiment, referring to fig. 7, another schematic diagram for detecting wind noise is shown.
In this embodiment, for detecting wind noise, reference is made to the specific flow of fig. 7 in the above embodiment, and the description thereof will not be repeated here.
Fig. 8 is a schematic diagram of a specific application scenario. The wind noise is detected by the wind noise detection method, and then the wind noise is classified, so that the earphone is convenient to switch to the wind noise resistant mode according to the wind noise level.
In another embodiment, referring to fig. 9, a schematic structural diagram of a wind noise detection device is shown, where the quaternary device is applied to a headset, and the headset has a first audio signal collector and a second audio signal collector; the device comprises:
the frequency spectrum information acquisition module 1 is used for acquiring first frequency spectrum information of the first audio signal acquired by the first audio signal acquisition unit and second frequency spectrum information of the second audio signal acquired by the second audio signal acquisition unit;
a first correlation coefficient determining module 2, configured to determine a first correlation coefficient of a frequency between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information;
a second correlation number determining module 3, configured to determine a second correlation coefficient of an amplitude between the first audio signal and the second audio signal according to the first spectrum information and the second spectrum information;
and the wind noise determining module 4 is configured to determine whether wind noise exists in the environment where the earphone is located according to the first correlation coefficient and the second correlation coefficient.
In another embodiment, the first correlation coefficient determining module 2 includes:
a first power spectral density determining unit configured to determine a first power spectral density of the first spectrum information according to the first spectrum information;
A second power spectral density determining unit, configured to determine a second power spectral density of the second spectrum information according to the second spectrum information;
a cross-correlation power spectral density determining unit configured to determine a cross-correlation power spectral density of the first audio signal and the second audio signal according to the first spectral information, the second spectral information, the first power spectral density and the second power spectral density;
and a first correlation coefficient determining unit for determining the first correlation coefficient according to the cross-correlation power spectral density.
In another embodiment, the first correlation coefficient determination unit includes:
a characterization coefficient determining subunit, configured to determine a characterization coefficient of the cross-correlation power spectral density according to the cross-correlation power spectral density;
a first correlation coefficient determining subunit, configured to determine the first correlation coefficient according to the characterization coefficient and a weight of the characterization coefficient; wherein the weights are determined from the first audio signal and the second audio signal.
In another embodiment, the second phase relation determining module 3 includes:
a first amplitude spectrum information determining unit configured to determine first amplitude spectrum information of the first audio signal according to the first spectrum information;
A second amplitude spectrum information determining unit configured to determine second amplitude spectrum information of the first audio signal according to the second frequency spectrum information;
and a second correlation number determining unit configured to determine the second correlation coefficient based on the first amplitude spectrum information and the second amplitude spectrum information by a correlation coefficient algorithm.
In another embodiment, the first spectral information and the second spectral information each comprise M frames of audio signal frames;
the wind noise determination module 4 is further configured to:
determining that the first correlation coefficient is smaller than a first preset correlation coefficient and the second correlation number is smaller than the frame number of the audio signal frames of a second preset correlation coefficient within a preset duration;
and when the duty ratio of the total frame number of the audio signal frames in the preset duration is larger than a duty ratio threshold value, determining that wind noise exists.
In another embodiment, the apparatus further comprises:
the wind noise level determining module is used for determining the wind noise level of wind noise according to the average value of the first correlation coefficient corresponding to the r-frame audio signal frame in the preset duration when the wind noise is determined to exist; wherein r is less than M.
In another embodiment, the spectrum information acquisition module 1 includes:
A first framing and windowing unit for framing and windowing the first audio signal;
a second framing and windowing unit for said framing and said windowing of said second audio signal; the frame length and the frame shift of the first audio signal and the second audio signal after the framing are the same; the frame length is the same as the window length of the windowed frame;
a first spectrum information determining unit configured to convert the first audio signal after the framing and the windowing from a time domain to a frequency domain, to obtain the first spectrum information;
and a second spectrum information determining unit, configured to convert the second audio signal after the framing and the windowing from a time domain to a frequency domain, to obtain the second spectrum information.
In another embodiment, the apparatus further comprises:
and the control module is used for selecting a control strategy corresponding to the current wind noise level to control the earphone according to the corresponding relation between the preset wind noise level and the control strategy when the wind noise exists.
In another embodiment, the wind noise includes: wind noise.
In another embodiment, there is also provided an electronic device including:
A processor and a memory for storing executable instructions capable of executing on the processor, wherein:
the processor is configured to execute the executable instructions that, when executed, perform the method of any of the embodiments described above.
In another embodiment, there is also provided a non-transitory computer readable storage medium having stored therein computer executable instructions that when executed by a processor implement the method of any of the above embodiments.
It should be noted that, the "first" and "second" in the embodiments of the present disclosure are merely for convenience of expression and distinction, and are not otherwise specifically meant.
Fig. 10 is a block diagram of a terminal device according to an exemplary embodiment. For example, the terminal device may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, an exercise device, a personal digital assistant, and the like.
Referring to fig. 10, the terminal device 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.
The processing component 802 generally controls overall operation of the terminal device, such as operations associated with presentation, telephone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to perform all or part of the steps of the methods described above. Further, the processing component 802 can include one or more modules that facilitate interactions between the processing component 802 and other components. For example, the processing component 802 can include a multimedia module to facilitate interaction between the multimedia component 808 and the processing component 802.
The memory 804 is configured to store various types of data to support operations at the terminal device. Examples of such data include instructions for any application or method operating on the terminal device, contact data, phonebook data, messages, pictures, video, etc. The memory 804 may be implemented by any type or combination of volatile or nonvolatile memory devices 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 or optical disk.
The power component 806 provides power to the various components of the terminal device. The power components 806 may include a power management system, one or more power sources, and other components associated with generating, managing, and distributing power for the terminal devices.
The multimedia component 808 includes a screen between the terminal device and the user that provides an output interface. 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 a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may sense not only the boundary of a touch or sliding action, but also the duration and pressure associated with the touch or sliding operation. In some embodiments, the multimedia component 808 includes a front camera and/or a rear camera. The front camera and/or the rear camera may receive external multimedia data when the terminal device is in an operation mode, such as a photographing mode or a video mode. Each front camera and rear camera may be a fixed optical lens system or have focal length and optical zoom capabilities.
The audio component 810 is configured to output and/or input audio signals. For example, the audio component 810 includes a Microphone (MIC) configured to receive external audio signals when the terminal device is in an operational mode, such as a call mode, a recording mode, and a voice recognition mode. The received audio signals may be further stored in the memory 804 or transmitted via the communication component 816. In some embodiments, audio component 810 further includes a speaker for outputting audio signals.
The I/O interface 812 provides an interface between the processing component 802 and peripheral interface modules, which may be a keyboard, click wheel, buttons, etc. These buttons may include, but are not limited to: homepage button, volume button, start button, and lock button.
The sensor assembly 814 includes one or more sensors for providing status assessment of various aspects for the terminal device. For example, the sensor assembly 814 may detect an on/off state of the terminal device, a relative positioning of the assemblies, such as a display and keypad of the terminal device, the sensor assembly 814 may also detect a change in position of the terminal device or one of the assemblies of the terminal device, the presence or absence of user contact with the terminal device, an orientation or acceleration/deceleration of the terminal device, and a change in temperature of the terminal device. The sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 814 may also include a light 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 gyroscopic sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.
The communication component 816 is configured to facilitate communication between the terminal device and other devices, either wired or wireless. The terminal device may access a wireless network based on a communication standard, such as WiFi,2G or 3G, or a combination thereof. In one exemplary embodiment, the communication component 816 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In one exemplary embodiment, the communication component 816 further includes a Near Field Communication (NFC) module to facilitate short range communications. For example, the NFC module may be implemented based on a Radio Frequency Identification (RFID) technology, an infrared data association (IrDA) technology, an Ultra Wideband (UWB) technology, a Bluetooth (BT) technology, and other technologies.
In an exemplary embodiment, the terminal device 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 elements for executing the methods described above.
Other embodiments of the disclosure will be apparent to those skilled in the art from consideration of the specification and practice of the disclosure disclosed herein. This disclosure is intended to cover any adaptations, uses, or adaptations of the disclosure following the general principles of the disclosure and including such departures from the present disclosure as come within known or customary practice within the art to which the disclosure pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.
It is to be understood that the present disclosure is not limited to the precise arrangements and instrumentalities shown in the drawings, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (7)

1. The wind noise detection method is characterized by being applied to a headset, wherein the headset is provided with a first audio signal collector and a second audio signal collector; the method comprises the following steps:
acquiring first frequency spectrum information of a first audio signal acquired by the first audio signal acquisition unit and second frequency spectrum information of a second audio signal acquired by the second audio signal acquisition unit;
determining a first power spectral density of the first spectral information according to the first spectral information; determining a second power spectral density of the second spectral information according to the second spectral information; determining a cross-correlation power spectral density of the first audio signal and the second audio signal from the first spectral information, the second spectral information, the first power spectral density and the second power spectral density; determining a characterization coefficient of the cross-correlation power spectral density according to the cross-correlation power spectral density; determining a first correlation coefficient of power spectral density between the first audio signal and the second audio signal according to the characterization coefficient and the weight of the characterization coefficient; wherein the weights are determined from the first audio signal and the second audio signal;
Determining first amplitude spectrum information of the first audio signal according to the first frequency spectrum information; determining second amplitude spectrum information of the first audio signal according to the second frequency spectrum information; determining, by a correlation coefficient algorithm, a second correlation coefficient for an amplitude between the first audio signal and the second audio signal based on the first amplitude spectrum information and the second amplitude spectrum information;
the first spectral information and the second spectral information each include M frames of audio signal frames; determining that the first correlation coefficient is smaller than a first preset correlation coefficient and the second correlation number is smaller than the frame number of the audio signal frames of a second preset correlation coefficient within a preset duration; and when the duty ratio of the total frame number of the audio signal frames within the preset duration is larger than a duty ratio threshold value, determining that wind noise exists in the environment where the earphone is located.
2. The method according to claim 1, wherein the method further comprises:
when the wind noise is determined to exist, according to the preset time lengthrDetermining the wind noise level by the average value of the first correlation coefficient corresponding to the frame audio signal frame; wherein,rless thanM
3. The method of claim 1, wherein the acquiring the first spectral information of the first audio signal acquired by the first audio signal acquisition unit and the second spectral information of the second audio signal acquired by the second audio signal acquisition unit comprises:
Framing and windowing the first audio signal;
said framing and said windowing of said second audio signal; the frame length and the frame shift of the first audio signal and the second audio signal after the framing are the same; the frame length is the same as the window length of the windowed frame;
converting the first audio signal subjected to framing and windowing from a time domain to a frequency domain to obtain the first spectrum information;
and converting the second audio signal subjected to framing and windowing from a time domain to a frequency domain to obtain the second spectrum information.
4. The method of claim 1, wherein when it is determined that wind noise exists, selecting a control strategy corresponding to a current wind noise level to control the earphone according to a preset correspondence between wind noise levels and control strategies.
5. The wind noise detection device is characterized by being applied to a headset, wherein the headset is provided with a first audio signal collector and a second audio signal collector; the device comprises:
the frequency spectrum information acquisition module is used for acquiring first frequency spectrum information of the first audio signal acquired by the first audio signal acquisition unit and second frequency spectrum information of the second audio signal acquired by the second audio signal acquisition unit;
A first correlation coefficient determining module, configured to determine a first power spectral density of the first spectrum information according to the first spectrum information; determining a second power spectral density of the second spectral information according to the second spectral information; determining a cross-correlation power spectral density of the first audio signal and the second audio signal from the first spectral information, the second spectral information, the first power spectral density and the second power spectral density; determining a characterization coefficient of the cross-correlation power spectral density according to the cross-correlation power spectral density; determining a first correlation coefficient of power spectral density between the first audio signal and the second audio signal according to the characterization coefficient and the weight of the characterization coefficient; wherein the weights are determined from the first audio signal and the second audio signal;
a second correlation number determining module, configured to determine first amplitude spectrum information of the first audio signal according to the first spectrum information; determining second amplitude spectrum information of the first audio signal according to the second frequency spectrum information; determining, by a correlation coefficient algorithm, a second correlation coefficient for an amplitude between the first audio signal and the second audio signal based on the first amplitude spectrum information and the second amplitude spectrum information;
The wind noise determining module is used for determining the first frequency spectrum information and the second frequency spectrum information, wherein the first frequency spectrum information and the second frequency spectrum information comprise M frames of audio signal frames; determining that the first correlation coefficient is smaller than a first preset correlation coefficient and the second correlation number is smaller than the frame number of the audio signal frames of a second preset correlation coefficient within a preset duration; and when the duty ratio of the total frame number of the audio signal frames within the preset duration is larger than a duty ratio threshold value, determining that wind noise exists in the environment where the earphone is located.
6. An electronic device, comprising:
a processor and a memory for storing executable instructions capable of executing on the processor, wherein:
a processor for executing the executable instructions, which when executed perform the method of any of the preceding claims 1 to 4.
7. A non-transitory computer readable storage medium having stored therein computer executable instructions which when executed by a processor implement the method of any one of the preceding claims 1 to 4.
CN202111122238.8A 2021-09-24 2021-09-24 Wind noise detection method and device, electronic equipment and storage medium Active CN114040309B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111122238.8A CN114040309B (en) 2021-09-24 2021-09-24 Wind noise detection method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111122238.8A CN114040309B (en) 2021-09-24 2021-09-24 Wind noise detection method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN114040309A CN114040309A (en) 2022-02-11
CN114040309B true CN114040309B (en) 2024-03-19

Family

ID=80140481

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111122238.8A Active CN114040309B (en) 2021-09-24 2021-09-24 Wind noise detection method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114040309B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114615586A (en) * 2022-03-25 2022-06-10 歌尔股份有限公司 Earphone noise reduction method and device, electronic equipment and readable storage medium

Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109074814A (en) * 2017-03-07 2018-12-21 华为技术有限公司 A kind of noise detecting method and terminal device
CN110875049A (en) * 2019-10-25 2020-03-10 腾讯科技(深圳)有限公司 Voice signal processing method and device
CN111144347A (en) * 2019-12-30 2020-05-12 腾讯科技(深圳)有限公司 Data processing method, device, platform and storage medium
CN111935584A (en) * 2020-08-26 2020-11-13 恒玄科技(上海)股份有限公司 Wind noise processing method and device for wireless earphone assembly and earphone
CN112017696A (en) * 2020-09-10 2020-12-01 歌尔科技有限公司 Voice activity detection method of earphone, earphone and storage medium
CN112242148A (en) * 2020-11-12 2021-01-19 北京声加科技有限公司 Method and device for inhibiting wind noise and environmental noise based on headset
CN112584267A (en) * 2020-12-03 2021-03-30 广东思派康电子科技有限公司 Method for preventing strong wind noise and earphone
CN112802486A (en) * 2020-12-29 2021-05-14 紫光展锐(重庆)科技有限公司 Noise suppression method and device and electronic equipment
CN112802463A (en) * 2020-12-24 2021-05-14 北京猿力未来科技有限公司 Audio signal screening method, device and equipment
CN113160846A (en) * 2021-04-22 2021-07-23 维沃移动通信有限公司 Noise suppression method and electronic device
CN113223554A (en) * 2021-03-15 2021-08-06 百度在线网络技术(北京)有限公司 Wind noise detection method, device, equipment and storage medium
CN113286214A (en) * 2020-02-20 2021-08-20 北京小鸟听听科技有限公司 Earphone signal processing method and device and earphone

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8184816B2 (en) * 2008-03-18 2012-05-22 Qualcomm Incorporated Systems and methods for detecting wind noise using multiple audio sources
US10242689B2 (en) * 2015-09-17 2019-03-26 Intel IP Corporation Position-robust multiple microphone noise estimation techniques

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109074814A (en) * 2017-03-07 2018-12-21 华为技术有限公司 A kind of noise detecting method and terminal device
CN110875049A (en) * 2019-10-25 2020-03-10 腾讯科技(深圳)有限公司 Voice signal processing method and device
CN111144347A (en) * 2019-12-30 2020-05-12 腾讯科技(深圳)有限公司 Data processing method, device, platform and storage medium
CN113286214A (en) * 2020-02-20 2021-08-20 北京小鸟听听科技有限公司 Earphone signal processing method and device and earphone
CN111935584A (en) * 2020-08-26 2020-11-13 恒玄科技(上海)股份有限公司 Wind noise processing method and device for wireless earphone assembly and earphone
CN112017696A (en) * 2020-09-10 2020-12-01 歌尔科技有限公司 Voice activity detection method of earphone, earphone and storage medium
CN112242148A (en) * 2020-11-12 2021-01-19 北京声加科技有限公司 Method and device for inhibiting wind noise and environmental noise based on headset
CN112584267A (en) * 2020-12-03 2021-03-30 广东思派康电子科技有限公司 Method for preventing strong wind noise and earphone
CN112802463A (en) * 2020-12-24 2021-05-14 北京猿力未来科技有限公司 Audio signal screening method, device and equipment
CN112802486A (en) * 2020-12-29 2021-05-14 紫光展锐(重庆)科技有限公司 Noise suppression method and device and electronic equipment
CN113223554A (en) * 2021-03-15 2021-08-06 百度在线网络技术(北京)有限公司 Wind noise detection method, device, equipment and storage medium
CN113160846A (en) * 2021-04-22 2021-07-23 维沃移动通信有限公司 Noise suppression method and electronic device

Also Published As

Publication number Publication date
CN114040309A (en) 2022-02-11

Similar Documents

Publication Publication Date Title
CN111968662B (en) Audio signal processing method and device and storage medium
CN111128221B (en) Audio signal processing method and device, terminal and storage medium
CN111986693B (en) Audio signal processing method and device, terminal equipment and storage medium
CN114040285B (en) Method and device for generating feedforward filter parameters of earphone, earphone and storage medium
CN112037825B (en) Audio signal processing method and device and storage medium
JP2021509963A (en) Multi-beam selection method and equipment
CN114630239B (en) Method, device and storage medium for reducing earphone blocking effect
CN111883164A (en) Model training method and device, electronic equipment and storage medium
CN109256145B (en) Terminal-based audio processing method and device, terminal and readable storage medium
US11682412B2 (en) Information processing method, electronic equipment, and storage medium
CN114040309B (en) Wind noise detection method and device, electronic equipment and storage medium
CN111698593B (en) Active noise reduction method and device, and terminal
CN112863537B (en) Audio signal processing method, device and storage medium
CN112447184A (en) Voice signal processing method and device, electronic equipment and storage medium
CN111667842A (en) Audio signal processing method and device
CN115884030A (en) Noise reduction method and device, earphone equipment, storage medium and chip
CN116017250A (en) Data processing method, device, storage medium, chip and hearing aid device
CN115065921A (en) Method and device for preventing hearing aid from howling
CN112951262B (en) Audio recording method and device, electronic equipment and storage medium
CN115278441A (en) Voice detection method, device, earphone and storage medium
CN114786085A (en) Noise reduction control method and device, noise reduction earphone and storage medium
CN110580910A (en) Audio processing method, device and equipment and readable storage medium
CN114513723A (en) Howling suppression method, howling suppression device, earphone and storage medium
CN111986688B (en) Method, device and medium for improving voice definition
CN116233696B (en) Airflow noise suppression method, audio module, sound generating device and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant