Audio playing fluency detection method and device and storage medium

By segmenting and sine wave root mean square value calculation of the audio signal collected by the audio playback device, the problem of low audio lag detection accuracy of true wireless headphones in the prior art is solved, and high-precision lag detection is achieved.

CN119922479APending Publication Date: 2025-05-02BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311421848.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-30
Publication Date
2025-05-02

AI Technical Summary

Technical Problem

In the prior art, it is difficult to detect audio lags in true wireless headphones efficiently, and mainly relies on pressure measurement and the detection accuracy is not high.

Method used

By collecting the audio signals played by the audio playback device and performing segmentation processing, the root mean square value of the sine wave of each audio signal is calculated. If it is less than the preset threshold value, it is judged that there is a lag.

Benefits of technology

It realizes high-precision detection of whether there is lag during the audio playback process, and can effectively detect the audio lag problem of real wireless headphones and other devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119922479A_ABST
    Figure CN119922479A_ABST
Patent Text Reader

Abstract

The invention relates to an audio playing fluency detection method and device and a storage medium. The audio playing fluency detection method comprises the following steps: collecting audio played by audio playing equipment and converting the audio into an audio signal; segmenting the audio signal, and determining a sine wave root-mean-square value of each segment of audio signal based on each segment of audio signal after segmentation; and in response to the existence of the audio signal segment of which the sine wave root-mean-square value is smaller than the preset threshold value, determining that the playing fluency of the audio playing equipment for playing the audio is lagging. According to the invention, the jamming existing in the audio playing process of the audio equipment is detected with high precision based on calculation of the sine wave root-mean-square value of each segment of audio signal.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of speaker detection, and in particular to a method, device and storage medium for detecting the fluency of audio playback. Background Art

[0002] In the related art, most of the audio testing solutions for the terminal's external audio playback devices, such as True Wireless Stereo (TWS) headphones, are based on Audio Pression or soundcheck to perform single-body sound performance testing. The problem of TWS headphones playing audio freezes is basically a problem that can only be discovered through stress testing. Therefore, the related art requires audio freeze detection for TWS headphones. Summary of the invention

[0003] In order to overcome the problems existing in the related art, the present disclosure provides an audio playback fluency detection method, device and storage medium.

[0004] According to a first aspect of an embodiment of the present disclosure, a method for detecting the smoothness of audio playback is provided, the method comprising: collecting audio played by an audio playback device and converting the audio into an audio signal; segmenting the audio signal, and determining a sine wave root mean square value of each audio signal segment based on each segmented audio signal; in response to the presence of an audio signal segment whose sine wave root mean square value is less than a preset threshold value, determining that the playback smoothness of the audio played by the audio playback device is jamming.

[0005] In one embodiment, segmenting the audio signal includes: segmenting the filtered audio signal based on the audio frequency of the audio signal and the sampling rate of collecting the audio signal to obtain Y audio signal segments; each of the Y audio signal segments includes N sample points, and the N sample points are determined based on the ratio between the sampling rate and the audio frequency.

[0006] In one embodiment, the audio frequency satisfies at least one of the following: a frequency that can emit sound in the Bluetooth audio transmission model protocol mode; a frequency that is a multiple of the sampling rate and is less than the sampling rate; and a frequency that is greater than an audio frequency threshold.

[0007] In one embodiment, the audio signal includes: an audio signal that is played in a loop after splicing the head and tail of the second audio signal based on the first audio signal; before determining that the playback smoothness of the audio played by the audio playback device is jittery, the method also includes: determining that a third frequency corresponding to an amplitude peak of a frequency spectrum corresponding to a third audio signal is different from the first frequency.

[0008] In one implementation, the peak value of the frequency spectrum amplitude of the third audio signal is determined in the following manner:

[0009] Determine a target audio signal segment whose root mean square value of the sine wave is less than a preset threshold value; determine K front-taken audio signal segments before the target audio signal segment, and / or determine M rear-taken audio signal segments after the target audio signal segment, and the audio frequencies corresponding to the K front-taken audio signal segments and the M rear-taken audio signal segments are multiples of the sampling rate; determine the frequency spectrum amplitude peak of the audio signal composed of the target audio signal segment, the front-taken audio signal segment and the rear-taken audio signal segment as the frequency spectrum amplitude peak of the third audio signal segment.

[0010] According to a second aspect of an embodiment of the present disclosure, a device for detecting audio playback fluency is provided, the device comprising:

[0011] A collection unit, used to collect audio played by the audio playback device and convert it into an audio signal;

[0012] A processing unit, configured to segment the audio signal and determine a sine wave root mean square value of each segment of the audio signal based on each segment of the audio signal;

[0013] The determining unit is used to determine that the playing smoothness of the audio played by the audio playing device is jamming in response to the presence of an audio signal segment whose sine wave root mean square value is less than a preset threshold value.

[0014] In one embodiment, the processing unit segments the audio signal in the following manner: based on the audio frequency of the audio signal and the sampling rate of the audio signal, the filtered audio signal is segmented to obtain Y audio signal segments; each of the Y audio signal segments includes N sample points, and the N sample points are determined based on the ratio between the sampling rate and the audio frequency.

[0015] In one embodiment, the audio frequency satisfies at least one of the following: a frequency that can emit sound in the Bluetooth audio transmission model protocol mode; a frequency that is a multiple of the sampling rate and is less than the sampling rate; and a frequency that is greater than an audio frequency threshold.

[0016] In one embodiment, the audio signal includes: an audio signal that is played in a loop after splicing the head and tail of the second audio signal based on the first audio signal, the first audio signal has a first frequency, the second audio signal has a second frequency, and the first frequency is different from the second frequency; before determining that the playback smoothness of the audio played by the audio playback device is stuck, the determination unit is also used to: determine that the third frequency corresponding to the peak value of the frequency spectrum amplitude of the third audio signal is different from the first frequency.

[0017] In one embodiment, the determination unit determines the peak amplitude of the frequency spectrum of the third audio signal in the following manner: determine a target audio signal segment whose root mean square value of the sine wave is less than a preset threshold value; determine K front audio signal segments before the target audio signal segment, and / or determine M rear audio signal segments after the target audio signal segment, and the audio frequencies corresponding to the K front audio signal segments and the M rear audio signal segments are multiples of the sampling rate; determine the peak amplitude of the frequency spectrum of the audio signal composed of the target audio signal segment, the front audio signal segment and the rear audio signal segment as the peak amplitude of the frequency spectrum of the third audio signal segment.

[0018] The technical solution provided by the embodiment of the present disclosure may include the following beneficial effects: According to the embodiment of the present disclosure, the audio played by the audio playback device is collected and converted into an audio signal. The audio signal is segmented, and based on each segment of the audio signal after segmentation, the sine wave root mean square value corresponding to each audio signal is calculated. When it is determined that there is an audio signal segment whose sine wave root mean square value is less than a preset threshold value, it is determined that the playback smoothness of the audio played by the audio playback device is jammed. In this way, it is possible to detect with high precision whether there is jamming during the audio playback process of the audio playback device.

[0019] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0020] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0021] Figure 1 The figure is a flow chart of a method for detecting the fluency of audio playback according to an exemplary embodiment.

[0022] Figure 2 The present invention is a flowchart showing a method of segmenting an audio signal and calculating a root mean square value of a sine wave of each segment according to an exemplary embodiment.

[0023] Figure 3 The figure is a flow chart of a method for detecting the fluency of audio playback according to an exemplary embodiment.

[0024] Figure 4 The diagram is a schematic diagram of an audio signal in which audio signal headers are spliced ​​according to an exemplary embodiment.

[0025] Figure 5 The present invention is a schematic diagram showing a method of determining whether the smoothness of audio playback by an audio playback device is jammed based on an audio signal spliced ​​at the beginning and the end of the audio signal according to an exemplary embodiment.

[0026] Figure 6 The figure is a schematic diagram of an audio playback fluency detection environment according to an exemplary embodiment.

[0027] Figure 7 The present invention is a block diagram of a device for detecting the fluency of audio playback according to an exemplary embodiment.

[0028] Figure 8 The invention is a block diagram of a device for detecting the fluency of audio playback according to an exemplary embodiment. DETAILED DESCRIPTION

[0029] Here, exemplary embodiments will be described in detail, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present disclosure.

[0030] The audio playback fluency detection method provided in the embodiments of the present disclosure is applied to the scenario of detecting the fluency of audio played by an audio device, for example, it is applied to the scenario of detecting audio freeze based on True Wireless Stereo (TWS) headphones under the Bluetooth audio transmission model protocol (Advanced Audio Distribution Profile, A2DP).

[0031] At present, the Bluetooth transmission protocol of TWS earphones is divided into call detection and A2DP music detection. The audio detection of A2DP is based on audio compression (Audio Pression) or electroacoustic detection system (soundcheck) to do single-body sound performance detection, but the A2DP playback jamming of TWS earphones can only be discovered by stress testing.

[0032] In view of this, the present disclosure provides a method for detecting the fluency of audio playback, which collects audio played by an audio playback device and converts it into an audio signal. The audio signal is segmented, and the root mean square value of the sine wave corresponding to each segment is calculated. Further, based on the determination of the root mean square value of the sine wave corresponding to each segment, it is determined whether there is a jam, and whether there is a jam in the audio playback device during audio playback can be detected with high precision.

[0033] Figure 1 is a flow chart of a method for detecting audio playback fluency according to an exemplary embodiment. Figure 1 As shown, the following steps are included.

[0034] In step S11, the audio played by the audio playing device is collected and converted into an audio signal.

[0035] In the disclosed embodiment, the collected audio may be audio played by an audio playback device connected to the terminal, wherein the audio may be determined by the terminal for audio playback fluency detection and played in the audio playback device.

[0036] In the disclosed embodiment, the audio signal is an audio signal corresponding to the audio played by the audio playback device. It can also be understood that the audio played by the audio playback device can be collected by the sound card, and the sound card can convert the audio into an audio signal.

[0037] In an example of the present disclosure, the sound card converts the acquired audio into an analog signal and a digital signal, so as to convert the audio into a digital audio signal that can be analyzed.

[0038] In an example of the present disclosure, the audio can be played by a terminal. It is understandable that the present disclosure embodiment is not limited to this, and the audio can also be played by other devices with an audio signal playing function.

[0039] In step S12, the audio signal is segmented, and based on each segment of the audio signal, a sine wave root mean square value of each segment of the audio signal is determined.

[0040] In the embodiment of the present disclosure, the audio signal is segmented, and based on each segment of the audio signal, calculation is performed on each segment to obtain a root mean square value of the sine wave.

[0041] In the embodiment of the present disclosure, a threshold value is pre-set for an audio playback device, such as a TWS headset, to detect whether the audio playback device is stuck during the audio playback process when playing an audio signal. The threshold value can be, for example, an experimental data value and is pre-set in the terminal.

[0042] In the embodiment of the present disclosure, based on calculating each segment corresponding to the audio signal, the root mean square value of the sine wave is obtained and compared with the threshold value to determine whether the audio playback device, such as a TWS headset, is stuck.

[0043] In step S13, in response to the presence of an audio signal segment in which the root mean square value of the sine wave is less than a preset threshold value, it is determined that the playing smoothness of the audio played by the audio playing device is jamming.

[0044] The audio playback fluency detection method provided by the embodiment of the present disclosure collects the audio played by the playback device and converts it into an audio signal. The audio signal is segmented, and the root mean square value of the sine wave corresponding to each segment is calculated. Further, based on the determination of the root mean square value of the sine wave corresponding to each segment, it is determined whether there is a jam, and whether there is a jam during the audio playback device playing audio can be detected with high precision.

[0045] Embodiments of the Disclosure The following describes a method for detecting the fluency of audio playback according to an embodiment of the disclosure.

[0046] The embodiment of the present disclosure firstly divides the audio signal into segments, and based on the audio signal of each segment, describes the implementation process of determining the sine wave root mean square value of each audio signal segment.

[0047] Figure 2 According to an exemplary embodiment, a flow chart of segmenting an audio signal and calculating the RMS value of a sine wave of each segment is shown. Figure 2 As shown, the following steps are included.

[0048] In step S21, based on the audio frequency of the audio signal and the sampling rate of the audio signal, the filtered audio signal is segmented to obtain Y frequency segments.

[0049] In the disclosed embodiment, based on the audio frequency of the audio signal and the sampling rate of the sampled audio signal, the filtered audio signal is segmented to obtain Y frequency segments. For example, if the audio signal is selected to be 3000 Hz, the audio signal after filtering and removing noise can be divided into 3000 segments within one second, where each segment is a complete cycle, for the convenience of later analysis.

[0050] In the embodiment of the present disclosure, the audio signal may be filtered based on a filter, wherein the filter may be a bandpass filter, such as a high-order filter: an 8th-order filter.

[0051] In one example of the present disclosure, a high-order filter is used to allow specific waves to pass through while shielding devices in other frequency bands, so that the corresponding characteristics of the filtered audio signal can be better.

[0052] In step S22, the number of sample points per segment is determined based on the sound card sampling rate and the audio frequency of the audio signal.

[0053] In the embodiment of the present disclosure, the Y audio signal segments are determined by the audio frequency of the audio signal, and each of the Y frequency segments includes N sample points.

[0054] In the disclosed embodiment, N sample points are determined by the ratio between the sound card sampling rate and the audio frequency of the audio signal. For example, when the sound card sampling rate is 48kHz and the audio frequency of the audio signal is 3000Hz, one cycle contains 16 sample points, that is, each segment contains 16 sample points.

[0055] In step S23, based on the number of sample points in each segment and the Y frequency segments, the root mean square value of the sine wave in each of the Y frequency segments is calculated.

[0056] In the embodiment of the present disclosure, the root mean square value of the sine wave corresponding to each audio signal segment in the Y audio signal segments is calculated.

[0057] In the embodiment of the present disclosure, the following formula is used to calculate the RMS value of the sine wave corresponding to each segment:

[0058]

[0059] In the above formula, RMSPower is the root mean square value of the sine wave, N is the total sample points, and x is the frequency value corresponding to each sample point.

[0060] For example, in the embodiment of the present disclosure, when the sound card sampling rate is 48kHz, that is, 48,000 points are played in one second. The audio signal is 3000Hz, that is, there are 3000 cycles in one second. Therefore, one cycle contains 16 sample points, that is, each segment contains 16 sample points. Then, the root mean square value of the sine wave corresponding to each frequency segment is calculated, that is, the root mean square value of the sine wave corresponding to each segment is calculated. That is, each of the 16 sample points corresponds to a frequency value, and based on the frequency value, the root mean square value of the sine wave of the 16 sample points is calculated.

[0061] In the disclosed embodiment, based on the audio frequency of the audio signal, the filtered audio signal is segmented to obtain Y audio signal segments. Based on the sound card sampling rate and the audio signal, it is determined that each segment of the Y audio signal segments should include N sample points, and then the root mean square value of the sine wave corresponding to each segment is calculated, so as to detect whether there is a freeze in the audio playback device during the audio playback process with high precision.

[0062] The following is an explanation of the implementation process of acquiring an audio signal in the embodiment of the present disclosure.

[0063] In the disclosed embodiment, the audio played by the audio playback device connected to the terminal is obtained. For example, the TWS headset is connected to the terminal via Bluetooth, and the audio is played in the TWS headset in a loop through the terminal.

[0064] In the embodiment of the present disclosure, obtaining the frequency of the audio signal corresponding to the audio played by the audio playback device can be understood as the frequency corresponding to the specified audio signal.

[0065] In the embodiment of the present disclosure, the frequency corresponding to the designated audio signal is the frequency corresponding to the case where sound can be emitted under the Bluetooth audio transmission protocol (Advanced Audio Distribution Profile, A2DP).

[0066] In one example of the present disclosure, A2DP can use the chip in the TWS headset to stack data to achieve high-definition sound.

[0067] In the embodiment of the present disclosure, the selection of the designated frequency can satisfy the designated frequency that is a multiple of the sound card sampling frequency. For example, when the sound card sampling rate is 48KHz, a 10-minute 3000Hz sound source is produced.

[0068] In the disclosed embodiment, the audio corresponding to the selected designated audio signal is stored in the terminal, and the terminal is connected to the TWS headset via Bluetooth and plays it in a loop.

[0069] In an example of the present disclosure, in order to ensure high-precision detection of whether there is a freeze in the audio playback device during audio playback and reduce the impact of noise, in an embodiment of the present disclosure, audio is played in a silent environment.

[0070] In the disclosed embodiment, the microphone collects the audio corresponding to the designated audio signal played in a loop, and the recording is performed at the maximum sampling rate of the sound card, which can improve the clarity of the sound corresponding to the recorded audio.

[0071] In one example of the present disclosure, the sampling rate of the sound card is greater than the frequency of the specified audio signal, so that after segmentation, each segment contains more sample points, and thus the root mean square value of the sine wave can be accurately calculated.

[0072] In the embodiment of the present disclosure, the audio frequency of the audio signal is greater than the audio frequency threshold. It can be understood that a high-frequency audio frequency is selected for the audio frequency, but it does not need to exceed the frequency range audible to the human ear.

[0073] For example, in the embodiment of the present disclosure, the sound card sampling rate is selected as 48kHz, and the audio frequency is 24000Hz, then one cycle contains 2 sample points, so the accuracy of calculating the RMS value of the sine wave is low. However, when the sound card sampling rate is 48kHz and the audio frequency is 3000Hz, one cycle contains 16 sample points, so the RMS value of the sine wave corresponding to the signal can be calculated with high accuracy.

[0074] In the present embodiment, the audio signals collected by the microphone are converted into digital signals through the sound card and sent to the local computer for analysis and calculation.

[0075] In the disclosed embodiment, by selecting a frequency that can emit sound under A2DP and selecting a frequency of a specified audio signal that is a multiple of the high sampling rate of the sound card, a sine wave root mean square value corresponding to the signal can be calculated with high precision.

[0076] In another embodiment of the present disclosure, when the RMS value of the sine wave is less than a preset threshold value, there may be a phenomenon of no sound due to the blank time at the beginning and end of the audio loop.

[0077] For example, in an example of the present disclosure, blank time can be understood as: when playing music, when the music jumps from the end to the beginning, there is a phenomenon of no sound, that is, blank time.

[0078] The following embodiment of the present disclosure describes the implementation process of avoiding the phenomenon of blank time and no sound when there is an audio signal segment with a sinusoidal root mean square value less than a preset threshold value, and determining that the playback smoothness of audio played by an audio playback device is stuck.

[0079] Figure 3 is a flow chart of a method for detecting audio playback fluency according to an exemplary embodiment. Figure 3 As shown, the following steps are included.

[0080] In step S31, the audio played by the audio playing device is collected and converted into an audio signal.

[0081] In step S32, the audio signal is segmented, and based on each segment of the audio signal, a sine wave root mean square value of each segment of the audio signal is determined.

[0082] In step S33, in response to the presence of an audio signal segment whose sinusoidal root mean square value is less than a preset threshold value, it is determined that the third frequency corresponding to the peak value of the frequency spectrum amplitude of the third audio signal is different from the first frequency, and it is determined that the playback smoothness of the audio played by the audio playback device is jamming.

[0083] Among them, step S31 and step S32 are consistent with step S11 and step S12, and will not be described in detail here.

[0084] In the embodiment of the present disclosure, the audio signal may be an audio signal formed by splicing audio signals of different frequencies.

[0085] In the embodiment of the present disclosure, the audio signal includes: an audio signal obtained by splicing the first and last parts of the second audio signal based on the first audio signal and then playing it in a loop, wherein the first audio signal has a first frequency, the second audio signal has a second frequency, and the first frequency is different from the second frequency.

[0086] In one example, Figure 4 FIG. 1 is a schematic diagram showing an audio signal in which the headers of the audio signals are spliced ​​according to an exemplary embodiment. Figure 4 As shown, the horizontal axis is time, the unit is milliseconds (hms). The vertical axis is frequency, the unit is Hertz (Hz). A is a first audio signal with a first frequency, and B is a second audio signal with a second frequency. The first frequency of the first audio signal may be greater than the second frequency of the second audio signal. Figure 4As shown, a first audio signal having a frequency different from that of the second audio signal is spliced ​​at the head of the second audio signal, wherein the length of the first audio signal may be 1 second.

[0087] In one example, the first audio signal having the first audio signal frequency is spliced ​​at the beginning and the end of the second audio signal having the second frequency, which may be accomplished by splicing an audio signal having a frequency of 4000 Hz at the beginning and the end of an audio signal having a frequency of 3000 Hz.

[0088] In the embodiment of the present disclosure, before determining that the playback smoothness of the audio played by the audio playback device is jittery, it is determined that the third frequency corresponding to the peak value of the frequency spectrum amplitude of the third audio signal is different from the first frequency.

[0089] In an example of the present disclosure, a fast Fourier transform is performed on the third audio signal to obtain a frequency spectrum of the third audio signal, and based on the frequency spectrum of the third audio signal, a frequency corresponding to an amplitude peak in the frequency spectrum of the third audio signal is determined as the third frequency.

[0090] In an example of the present disclosure, when it is determined that the third frequency is not equal to the first frequency of the first audio signal spliced ​​at the beginning and the end of the second audio signal, it is determined that the audio signal segment less than the preset threshold can be excluded as the blank time when the audio loop playback jumps, and then it can be determined that the playback smoothness of the audio played by the audio playback device is stuck.

[0091] In the embodiment of the present disclosure, by determining that the third frequency corresponding to the peak value of the frequency spectrum of the third audio signal is different from the first frequency, it is prevented that the blank time that occurs when the audio signal jumps in a loop is misjudged as the smoothness of the audio signal played by the external audio player being stuck. In this way, it is possible to more accurately determine whether there is actually stuck when the external audio player plays the audio signal.

[0092] In the embodiment of the present disclosure, the third audio signal may be an audio signal that has not been filtered by a filter.

[0093] Figure 5 FIG. 1 is a schematic diagram showing a method of determining whether the smoothness of audio playback by an audio playback device is a jam based on an audio signal spliced ​​at the beginning and the end of the audio signal according to an exemplary embodiment. Figure 5 As shown, the horizontal axis is frequency, in Hertz (Hz). The vertical axis is sound intensity, in decibels (dB). The third frequency corresponding to the amplitude peak of the audio signal frequency spectrum is, for example, 4800 Hz, which is different from the first frequency 4000 Hz of the first signal. Therefore, when the third frequency is different from the first frequency, the audio signal played by the external audio player is jittery.

[0094] In the embodiment of the present disclosure, the third audio signal may include: a target audio signal segment whose root mean square value of the sine wave is less than a preset threshold value; and / or K-th audio signal segments determined before the target audio signal segment; and / or M-th audio signal segments determined after the target audio signal segment.

[0095] Among them, the audio frequency corresponding to the audio signal segment taken before the K segment and the audio signal taken after the M segment has a multiple relationship with the sampling rate.

[0096] The number of the preceding audio signal segments before the target audio signal segment may be equal to the number of the succeeding audio signal segments after the target audio signal segment, that is, K may be equal to M.

[0097] In the disclosed embodiment, the frequency spectrum amplitude peak value of the audio signal composed of the target audio signal segment, the front audio signal segment and the rear audio signal segment can be determined as the frequency spectrum amplitude peak value of the third audio signal segment. For example, when the frequency of the signal is 3000 Hz, and there is an audio signal segment whose root mean square value is less than a preset threshold, the audio signal segment and the first 3000 segments and the last 3000 segments of the audio signal segment can be used as the third audio signal, and the frequency corresponding to the amplitude peak value of the frequency spectrum of the third audio signal is determined to be the third frequency, and the third frequency is compared with the first frequency to determine whether there is a freeze.

[0098] In the disclosed embodiment, by determining the peak value of the frequency spectrum amplitude of the third audio signal, and then determining whether the frequency corresponding to the peak value is the same as the first frequency, it is possible to more accurately determine whether there is actually a freeze when the audio external playback device plays the audio signal.

[0099] Figure 6 FIG. 1 is a schematic diagram showing an audio playback fluency detection environment according to an exemplary embodiment. Figure 6 As shown, the terminal c is connected to the TWS headset d via Bluetooth and plays the audio in a loop. The microphone e collects the audio, and the sound card b collects the audio and converts it into a digital audio signal that can be used for analysis. The digital audio signal is then sent to the device a for analysis and calculation.

[0100] In the embodiment of the present disclosure, the device a and the terminal c may be the same terminal, but the embodiment of the present disclosure is not limited to this.

[0101] In the embodiment of the present disclosure, the audio is collected by a microphone. It is understandable that the embodiment of the present disclosure is not limited to this, and the audio can also be collected by other devices with audio signal collection function.

[0102] The audio playback fluency detection method provided by the embodiment of the present disclosure collects the audio played by the playback device and converts it into a corresponding audio signal. The audio signal is segmented, and the root mean square value of the sine wave corresponding to each segment is calculated. Further, based on the determination of the root mean square value of the sine wave corresponding to each segment, it is determined whether there is a jam, and whether there is a jam during the audio playback device playing audio can be detected with high precision.

[0103] Based on the same concept, an embodiment of the present disclosure also provides a device for detecting the fluency of audio playback.

[0104] It is understandable that in order to achieve the above functions, the device for detecting the smoothness of audio playback provided by the embodiment of the present disclosure includes hardware structures and / or software modules corresponding to the execution of each function. In combination with the units and algorithm steps of each example disclosed in the embodiment of the present disclosure, the embodiment of the present disclosure can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the technical solution of the embodiment of the present disclosure.

[0105] Figure 7 is a block diagram of a device for detecting the fluency of audio playback according to an exemplary embodiment. Figure 7 The device 100 includes a collecting unit 101, a processing unit 102 and a determining unit 103.

[0106] The collection unit 101 is used to collect the audio played by the audio playing device and convert it into an audio signal.

[0107] The processing unit 102 is used to segment the audio signal and determine the sine wave root mean square value of each segment of the audio signal based on each segment of the audio signal.

[0108] The determining unit 103 is configured to determine that the smoothness of the audio playback device playing the audio is stuck in response to the presence of an audio signal segment in which the root mean square value of the sine wave is less than a preset threshold value.

[0109] In one embodiment, the processing unit 102 segments the audio signal in the following manner: based on the audio frequency of the audio signal and the sampling rate of the audio signal, the filtered audio signal is segmented to obtain Y audio signal segments; each of the Y audio signal segments includes N sample points, and the N sample points are determined based on the ratio between the sampling rate and the audio frequency.

[0110] In one embodiment, the audio frequency satisfies at least one of the following: a frequency that can emit sound in the Bluetooth audio transmission model protocol mode; a frequency that is a multiple of the sampling rate and is less than the sampling rate; and a frequency that is greater than an audio frequency threshold.

[0111] In one embodiment, the audio signal includes: an audio signal that is looped and played after splicing the head and tail of the second audio signal based on the first audio signal, the first audio signal has a first frequency, the second audio signal has a second frequency, and the first frequency is different from the second frequency; before determining that the playback smoothness of the audio played by the audio playback device is stuck, the determination unit 103 is also used to: determine that the third frequency corresponding to the peak value of the frequency spectrum amplitude of the third audio signal is different from the first frequency.

[0112] In one embodiment, the determination unit 103 determines the peak amplitude of the frequency spectrum of the third audio signal in the following manner: determine a target audio signal segment whose root mean square value of the sine wave is less than a preset threshold value; determine K front audio signal segments before the target audio signal segment, and / or determine M rear audio signal segments after the target audio signal segment, and the audio frequencies corresponding to the K front audio signal segments and the M rear audio signal segments are multiples of the sampling rate; determine the peak amplitude of the frequency spectrum of the audio signal consisting of the target audio signal segment, the front audio signal segment, and the rear audio signal segment as the peak amplitude of the frequency spectrum of the third audio signal segment.

[0113] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0114] Figure 8 1 is a block diagram of a device 200 for detecting audio playback fluency according to an exemplary embodiment. For example, the device 200 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0115] Reference Figure 8 , the device 200 may include one or more of the following components: a processing component 202 , a memory 204 , a power component 206 , a multimedia component 208 , an audio component 210 , an input / output (I / O) interface 212 , a sensor component 214 , and a communication component 216 .

[0116] The processing component 202 generally controls the overall operation of the device 200, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 202 may include one or more processors 220 to execute instructions to perform all or part of the steps of the above-described method. In addition, the processing component 202 may include one or more modules to facilitate interaction between the processing component 202 and other components. For example, the processing component 202 may include a multimedia module to facilitate interaction between the multimedia component 208 and the processing component 202.

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

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

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

[0120] The audio component 210 is configured to output and / or input audio signals. For example, the audio component 210 includes a microphone (MIC), and when the device 200 is in an operation mode, such as a call mode, a recording mode, and a speech recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 204 or sent via the communication component 216. In some embodiments, the audio component 210 also includes a speaker for outputting audio signals.

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

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

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

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

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

[0126] It is to be understood that in the present disclosure, "plurality" refers to two or more than two, and other quantifiers are similar. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the associated objects before and after are in an "or" relationship. The singular forms "a", "the" and "the" are also intended to include plural forms, unless the context clearly indicates other meanings.

[0127] It is further understood that the terms "first", "second", etc. are used to describe various information, but such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other, and do not indicate a specific order or degree of importance. In fact, the expressions "first", "second", etc. can be used interchangeably. For example, without departing from the scope of the present disclosure, the first information can also be referred to as the second information, and similarly, the second information can also be referred to as the first information.

[0128] It can be further understood that, unless otherwise specified, “connection” includes a direct connection without other components between the two, and also includes an indirect connection with other components between the two.

[0129] It is further understood that, although the operations are described in a specific order in the drawings in the embodiments of the present disclosure, it should not be understood as requiring the operations to be performed in the specific order shown or in a serial order, or requiring the execution of all the operations shown to obtain the desired results. In certain environments, multitasking and parallel processing may be advantageous.

[0130] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. This application is intended to cover any modifications, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure.

[0131] It should be understood that the present disclosure is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the scope of the appended claims.

Claims

1. A method for detecting the fluency of audio playback, characterized in that: The method comprises: Collect the audio played by the audio playback device and convert it into an audio signal; Segmenting the audio signal, and determining a sine wave root mean square value of each segment of the audio signal based on each segment of the audio signal; In response to the presence of an audio signal segment in which a sine wave root mean square value is less than a preset threshold value, it is determined that the playing smoothness of the audio played by the audio playing device is jamming.

2. The method according to claim 1, characterized in that The step of segmenting the audio signal comprises: Based on the audio frequency of the audio signal and the sampling rate of the audio signal, the audio signal is segmented to obtain Y audio signal segments; Each of the Y audio signal segments includes N sample points, and the N sample points are determined based on a ratio between the sampling rate and the audio frequency.

3. The method according to claim 2, characterized in that The audio frequency satisfies at least one of the following: The frequency of the sound that can be emitted in the Bluetooth audio transmission model protocol mode; A frequency that is a multiple of the sampling rate and is less than the sampling rate; and Frequencies greater than the audio frequency threshold.

4. The method according to any one of claims 1 to 3, characterized in that The audio signal comprises: an audio signal obtained by splicing a head portion and a tail portion of a second audio signal based on a first audio signal and then playing the signal in a loop, the first audio signal having a first frequency, the second audio signal having a second frequency, and the first frequency being different from the second frequency; Before determining that the playing smoothness of the audio played by the audio playing device is stuck, the method further includes: It is determined that a third frequency corresponding to a peak value of the frequency spectrum amplitude of the third audio signal is different from the first frequency.

5. The method according to claim 4, characterized in that The peak value of the frequency spectrum amplitude of the third audio signal is determined in the following manner: Determine a target audio signal segment whose sine wave root mean square value is less than a preset threshold value; Determine K audio signal segments taken before the target audio signal segment, and / or determine M audio signal segments taken after the target audio signal segment, wherein the audio frequencies corresponding to the K audio signal segments taken before and the M audio signal segments taken after are multiples of the sampling rate; The frequency spectrum amplitude peak value of the audio signal composed of the target audio signal segment, the front-taken audio signal segment and the rear-taken audio signal segment is determined as the third audio signal segment frequency spectrum amplitude peak value.

6. A device for detecting the fluency of audio playback, characterized in that: The device comprises: A collection unit, used to collect audio played by the audio playback device and convert it into an audio signal; A processing unit, configured to segment the audio signal and determine a sine wave root mean square value of each segment of the audio signal based on each segment of the audio signal; The determining unit is used to determine that the playing smoothness of the audio played by the audio playing device is jamming in response to the presence of an audio signal segment whose sine wave root mean square value is less than a preset threshold value.

7. The device according to claim 6, characterized in that: The processing unit segments the audio signal in the following manner: Based on the audio frequency of the audio signal and the sampling rate of the audio signal, segment the filtered audio signal to obtain Y audio signal segments; Each of the Y audio signal segments includes N sample points, and the N sample points are determined based on a ratio between the sampling rate and the audio frequency.

8. The device according to claim 7, characterized in that: The audio frequency satisfies at least one of the following: The frequency of the sound that can be emitted in the Bluetooth audio transmission model protocol mode; A frequency that is a multiple of the sampling rate and is less than the sampling rate; and Frequencies greater than the audio frequency threshold.

9. The device according to any one of claims 6 to 8, characterized in that The audio signal comprises: an audio signal obtained by splicing a head portion and a tail portion of a second audio signal based on a first audio signal and then playing the signal in a loop, the first audio signal having a first frequency, the second audio signal having a second frequency, and the first frequency being different from the second frequency; Before determining that the playing smoothness of the audio played by the audio playback device is jitter, the determining unit is further used to: determine that a third frequency corresponding to a peak value of the frequency spectrum amplitude of the third audio signal is different from the first frequency.

10. The device according to claim 9, characterized in that The determination unit determines the peak value of the frequency spectrum amplitude of the third audio signal in the following manner: Determine a target audio signal segment whose sine wave root mean square value is less than a preset threshold value; Determine K audio signal segments taken before the target audio signal segment, and / or determine M audio signal segments taken after the target audio signal segment, wherein the audio frequencies corresponding to the K audio signal segments taken before and the M audio signal segments taken after are multiples of the sampling rate; The frequency spectrum amplitude peak value of the audio signal composed of the target audio signal segment, the front-taken audio signal segment and the rear-taken audio signal segment is determined as the third audio signal segment frequency spectrum amplitude peak value.

11. A device for detecting the fluency of audio playback, characterized in that: include: processor; a memory for storing processor-executable instructions; Wherein, the processor is configured to: execute the method for detecting audio playback fluency as described in any one of claims 1-5.

12. A storage medium, characterized in that: The instructions in the storage medium, when the instructions in the storage medium are executed by the processor of the terminal, enable the terminal to execute the method for detecting the audio playback fluency as described in any one of claims 1-5.