Tone quality detection method and system based on deep learning
By constructing a sound quality detection network and employing deep learning methods, the problem of insufficient accuracy in traditional sound quality detection methods is solved, achieving high-precision sound quality detection that is adaptable to different devices and environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- JIANGXI XINGHAO IND CO LTD
- Filing Date
- 2026-01-30
- Publication Date
- 2026-05-01
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Existing sound quality testing methods cannot achieve high-precision, automated sound quality testing, and traditional acoustic parameters cannot accurately measure sound quality levels.
A deep learning-based sound quality detection method is adopted, which constructs a sound quality detection network, including a basic feature extraction module, a cascaded group feature enhancement module, and a multi-scale attention module, to perform sound quality detection.
It achieves high-precision automation of sound quality detection, significantly improving detection accuracy and robustness, and can adapt to differences in spectrogram characteristics under different audio devices and noise environments.
Smart Images

Figure CN121963790A_ABST
Abstract
Description
A Deep Learning-Based Sound Quality Detection Method and System Technical Field
[0001] This application belongs to the field of sound quality detection technology, specifically relating to a sound quality detection method and system based on deep learning. Background Technology
[0002] Sound quality testing is a core technical aspect of audio equipment R&D, production quality inspection, and audio content evaluation. Its testing accuracy directly determines the quality control of audio equipment and the user's listening experience. With the rapid development of the consumer electronics and smart audio device industries, the market's requirements for the sound quality of audio equipment are increasing, and traditional sound quality testing methods can no longer meet the needs of high-precision and automated testing.
[0003] Currently, most existing sound quality testing methods are objective evaluation methods based on signal processing. These methods typically extract traditional acoustic parameters such as signal-to-noise ratio, total harmonic distortion, and frequency response of audio signals as sound quality evaluation indicators. However, these parameters can only reflect the single-dimensional characteristics of audio signals and therefore cannot measure the actual sound quality level, which leads to inaccurate final sound quality test results. Summary of the Invention
[0004] The purpose of this application is to provide a sound quality detection method and system based on deep learning, which can solve the technical problem of inaccurate sound quality detection results in the prior art.
[0005] To address the aforementioned technical problems, this application provides the following: Firstly, embodiments of this application offer a deep learning-based sound quality detection method. The method includes: acquiring multiple spectrograms; preprocessing the multiple spectrograms to obtain preprocessed spectrograms; and constructing a dataset based on the multiple preprocessed spectrograms; constructing a sound quality detection network, the sound quality detection network including a basic feature extraction module, a cascaded grouping feature enhancement module, a multi-scale attention module, and an output module; dividing the dataset into a training set and a test set according to a preset ratio; training the sound quality detection network based on the training set; and testing the trained sound quality detection network based on the test set; acquiring a target spectrogram corresponding to a target audio device; and processing the target spectrogram based on the tested sound quality detection network to obtain the sound quality detection result of the target audio device.
[0006] As an optional implementation of the first aspect of this application, the sound quality detection network processes the target spectrogram to obtain the sound quality detection result of the target audio device, including: extracting basic features from the target spectrogram according to the basic feature extraction module to obtain target basic features; enhancing the target basic features according to the cascaded grouping feature enhancement module to obtain target cascaded enhanced features; enhancing the target cascaded enhanced features according to the multi-scale attention module to obtain target multi-scale attention features; and processing the target multi-scale attention features according to the output module to obtain the sound quality detection result of the target audio device.
[0007] As an optional implementation of the first aspect of this application, the cascaded grouping feature enhancement module enhances the target basic feature to obtain a target cascaded enhanced feature, including: processing the target basic feature according to a first grouping residual unit to obtain a first residual enhanced feature, and concatenating the first residual enhanced feature with the target basic feature to obtain a first residual fusion feature; processing the first residual fusion feature according to a second grouping residual unit to obtain a second residual enhanced feature, and concatenating the second residual enhanced feature with the first residual fusion feature to obtain a second residual fusion feature; processing the second residual fusion feature according to a third grouping residual unit to obtain a third residual enhanced feature, and concatenating the third residual enhanced feature with the second residual fusion feature to obtain a third residual fusion feature; processing the third residual fusion feature according to a fourth grouping residual unit to obtain a fourth residual enhanced feature, and concatenating the fourth residual enhanced feature with the third residual fusion feature to obtain a target cascaded enhanced feature; wherein the first grouping residual unit, the second grouping residual unit, the third grouping residual unit, and the fourth grouping residual unit have the same structure.
[0008] As an optional implementation of the first aspect of this application, the first grouped residual unit processes the target basic features to obtain a first residual enhancement feature, including: grouping the target basic features according to channels to obtain multiple channel grouped features; extracting features from each channel grouped feature using a channel convolution block to obtain a channel convolution feature corresponding to each channel grouped feature; concatenating all the channel convolution features to obtain the channel concatenated feature; and performing residual connection between the channel concatenated feature and the target basic features to obtain the first residual enhancement feature.
[0009] As an optional implementation of the first aspect of this application, the step of extracting features from each channel group feature using a channel convolutional block to obtain the channel convolutional features corresponding to each channel group feature includes: performing 1×1 convolution processing on the channel group features according to a first 1×1 convolutional layer to obtain a first convolutional feature; performing batch normalization and ReLU activation processing on the first convolutional feature sequentially to obtain a first activation feature; performing 3×3 convolution processing on the first activation feature according to a first 3×3 convolutional layer and a second 3×3 convolutional layer respectively to obtain a second convolutional feature and a third convolutional feature respectively; performing batch normalization and ReLU activation processing on the second convolutional feature sequentially to obtain a second activation feature, and performing batch normalization and ReLU activation processing on the third convolutional feature sequentially to obtain a third activation feature; concatenating the second activation feature and the third activation feature to obtain an activation fusion feature; and performing 1×1 convolution processing on the activation fusion feature according to a second 1×1 convolutional layer to obtain the channel convolutional features corresponding to the channel group features.
[0010] As an optional implementation of the first aspect of this application, the multi-scale attention module performs multi-scale attention enhancement processing on the target cascaded enhancement features to obtain target multi-scale attention features, including: performing 3×3 convolution processing on the target cascaded enhancement features according to a third 3×3 convolutional layer to obtain a fourth convolutional feature; concatenating the fourth convolutional feature with the target cascaded enhancement features to obtain a first multi-scale fusion feature; performing 3×3 convolution processing on the fourth convolutional feature according to the fourth 3×3 convolutional layer to obtain a fifth convolutional feature, and performing 3×3 convolution processing on the fifth convolutional feature according to the fifth 3×3 convolutional layer to obtain a sixth convolutional feature; concatenating the fifth convolutional feature with the sixth convolutional feature. The features are concatenated to obtain a second multi-scale fusion feature; the first multi-scale fusion feature is processed sequentially according to the first channel attention mechanism and the first spatial attention mechanism to obtain a first multi-scale attention feature; the second multi-scale fusion feature is processed sequentially according to the second channel attention mechanism and the second spatial attention mechanism to obtain a second multi-scale attention feature; the first multi-scale attention feature and the second multi-scale attention feature are concatenated to obtain the target multi-scale attention feature; wherein, the data processing procedures of the first channel attention mechanism and the second channel attention mechanism are the same, and the data processing procedures of the first spatial attention mechanism and the second spatial attention mechanism are the same.
[0011] As an optional implementation of the first aspect of this application, the step of processing the first multi-scale fusion feature sequentially according to the first channel attention mechanism and the first spatial attention mechanism to obtain the first multi-scale attention feature includes: performing channel attention enhancement on the first multi-scale fusion feature according to the first channel attention mechanism to obtain the first channel attention enhancement feature; and performing spatial attention enhancement on the first channel attention enhancement feature according to the first spatial attention mechanism to obtain the first multi-scale attention feature.
[0012] Secondly, embodiments of this application provide a deep learning-based audio quality detection system, the system comprising: a data construction module: acquiring multiple spectrograms, preprocessing the multiple spectrograms to obtain preprocessed spectrograms, and constructing a dataset based on the multiple preprocessed spectrograms; a network construction module: constructing an audio quality detection network, the audio quality detection network including a basic feature extraction module, a cascaded grouping feature enhancement module, a multi-scale attention module, and an output module; a network training module: dividing the dataset into a training set and a test set according to a preset ratio, training the audio quality detection network based on the training set, and testing the trained audio quality detection network based on the test set; and an automatic detection module: acquiring a target spectrogram corresponding to a target audio device, processing the target spectrogram based on the tested audio quality detection network, and obtaining the audio quality detection result of the target audio device.
[0013] Thirdly, embodiments of this application provide an audio quality testing device, including a processor, a memory, and a program or instructions stored in the memory and executable on the processor. When the program or instructions are executed by the processor, they implement the steps of the method described in the first aspect.
[0014] Fourthly, embodiments of this application provide a readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the steps of the method described in the first aspect.
[0015] In this embodiment, compared with the prior art, the following technical effects are achieved: According to the deep learning-based sound quality detection method of this embodiment, by acquiring the target spectrogram of the target audio device and then inputting the target spectrogram into the sound quality detection network, the sound quality detection network can achieve automated and high-precision detection of the sound quality of the target audio device; the sound quality detection network achieves a significant improvement in sound quality detection accuracy through the design of the cascaded grouping feature enhancement module and the multi-scale attention module.
[0016] The cascaded grouping feature enhancement module employs a channel grouping strategy within its internal residual units. This strategy divides the input features into multiple channel-grouped features and uses channel convolutional blocks for feature extraction in each group. This avoids the redundant computation of all channels in traditional convolution, significantly reducing the network's computational load and parameter size while maintaining feature extraction quality. Simultaneously, the module uses a cascaded splicing and fusion strategy. The residual enhancement features output from each grouping residual unit are spliced and fused with the input features of that level, and the resulting fused features serve as the input for the next level unit. Through four levels of cascaded processing, the module achieves the progressive accumulation and enhancement of effective sound quality-related information in the basic features, while gradually suppressing noise features and redundant information. This results in a more accurate and richer sound quality representation capability in the final output cascaded enhancement features, effectively improving the network's accuracy in sound quality detection.
[0017] The multi-scale attention module generates features at different scales through multiple stacked 3×3 convolutions. The features from the first 3×3 convolution are concatenated with the initial information to obtain local multi-scale information. The features from the second and third convolutions are then concatenated to obtain global multi-scale information, achieving comprehensive coverage of sound quality-related features and avoiding the limitations of single-scale features on detection results. Simultaneously, the multi-scale attention module applies a combination of channel attention and spatial attention mechanisms to the two types of multi-scale information. Through the synergistic effect of these dual attention mechanisms, the discriminative power of the features is significantly improved, allowing effective features to dominate subsequent detection processes and thus enhancing the accuracy of network detection. The two types of attention-enhanced multi-scale information are then concatenated to generate the target multi-scale attention feature. This feature combines the advantages of local details and global trends, while integrating attention weights from both channel and spatial dimensions. It effectively addresses the differences in spectrogram features under different audio devices and noise environments, significantly improving the robustness and generalization ability of the sound quality detection network. Attached Figure Description
[0018] Figure 1 is a flowchart of a deep learning-based sound quality detection method provided in some embodiments of this application; Figure 2 is a structural diagram of the sound quality detection network in a deep learning-based sound quality detection method provided in some embodiments of this application. Detailed Implementation
[0019] The technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0020] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.
[0021] The following description, in conjunction with the accompanying drawings, details a deep learning-based sound quality detection method and system provided in this application through specific embodiments and application scenarios.
[0022] An embodiment of a deep learning-based audio quality detection method includes: S100: acquiring multiple spectrograms, preprocessing the multiple spectrograms to obtain preprocessed spectrograms, and constructing a dataset based on the multiple preprocessed spectrograms; it should be noted that multiple audio data segments are acquired, and short-time Fourier transforms are performed on the multiple audio data segments to obtain multiple spectrograms, and preprocessing processes such as standardization, size unification, and data augmentation are performed on the multiple spectrograms to obtain multiple preprocessed spectrograms; finally, a dataset is constructed based on these preprocessed spectrograms.
[0023] S200: Construct a sound quality detection network, which includes a basic feature extraction module, a cascaded grouped feature enhancement module, a multi-scale attention module, and an output module; S300: Divide the dataset into training and testing sets according to a preset ratio. Train the sound quality detection network using the training set and test the trained network using the testing set. It should be noted that the dataset is divided into training and testing sets in a preset ratio of 8:2, and a loss function is constructed simultaneously. The sound quality detection network is iteratively trained using the training set, and the loss function is applied during training. The network parameters are calculated and backpropagated using the Adam optimizer until the parameters of the audio quality detection network converge. Once the parameters converge, the audio quality detection network is tested using a test set. The network processes the data in the test set to obtain test results, which are then evaluated using evaluation metrics. If the evaluation results meet the detection requirements, the training and testing of the audio quality detection network are complete. If the evaluation results do not meet the detection requirements, the parameters and training strategy of the audio quality detection network are readjusted and the network is trained again until the evaluation results meet the detection requirements.
[0024] S400: Obtain the target spectrogram corresponding to the target audio device, process the target spectrogram according to the tested sound quality detection network, and obtain the sound quality detection result of the target audio device.
[0025] According to an optional implementation of this embodiment, in S400, the sound quality detection network processes the target spectrogram to obtain the sound quality detection result of the target audio device, including: S410: extracting basic features from the target spectrogram using the basic feature extraction module to obtain target basic features; S420: enhancing the target basic features using the cascaded grouping feature enhancement module to obtain target cascaded enhanced features; S430: enhancing the target cascaded enhanced features using the multi-scale attention module to obtain target multi-scale attention features; S440: processing the target multi-scale attention features using the output module to obtain the sound quality detection result of the target audio device.
[0026] It should be noted that, firstly, the basic feature extraction module extracts basic features from the target spectrogram to obtain the target basic features; then, the target basic features are sent to the cascaded grouping feature enhancement module to enhance the target basic features, resulting in the target cascaded enhanced features; next, a multi-scale attention module is applied to the enhanced target cascaded enhanced features to perform multi-scale attention enhancement processing, resulting in the target multi-scale attention enhanced features; finally, the output module processes the target multi-scale attention features to obtain the sound quality detection result of the target spectrogram, which is the sound quality detection result of the target audio device corresponding to the target spectrogram.
[0027] According to an optional implementation of this embodiment, in S420, the cascaded grouping feature enhancement module enhances the target basic features to obtain target cascaded enhanced features, including: S421: processing the target basic features according to the first grouping residual unit to obtain a first residual enhanced feature, and concatenating the first residual enhanced feature with the target basic features to obtain a first residual fusion feature; S422: processing the first residual fusion feature according to the second grouping residual unit to obtain a second residual enhanced feature, and concatenating the second residual enhanced feature with the first residual fusion feature to obtain a second residual enhanced feature. S423: Process the second residual fusion feature according to the third group residual unit to obtain the third residual enhancement feature, and then concatenate the third residual enhancement feature and the second residual fusion feature to obtain the third residual fusion feature; S424: Process the third residual fusion feature according to the fourth group residual unit to obtain the fourth residual enhancement feature, and then concatenate the fourth residual enhancement feature and the third residual fusion feature to obtain the target cascade enhancement feature; wherein, the first group residual unit, the second group residual unit, the third group residual unit and the fourth group residual unit have the same structure.
[0028] It should be noted that, firstly, the target basic features are processed by the first grouped residual unit to obtain the first residual enhancement feature, and then the obtained first residual enhancement feature is concatenated with the initial target basic features to obtain the first residual fusion unit; nextly, the first residual fusion feature is processed by the second grouped residual unit with the same structure as the first grouped residual unit to obtain the second residual enhancement feature, and then the second residual enhancement feature is concatenated with the first residual fusion feature to obtain the second residual fusion feature; then, the second residual fusion feature is input into the third grouped residual unit for processing. The third grouped residual unit has the same structure as the first grouped residual unit to obtain the third residual enhancement feature, and then the third residual enhancement feature is concatenated with the second residual fusion feature to obtain the third residual fusion feature; finally, the third residual fusion feature is processed by the fourth grouped residual unit with the same structure as the first grouped residual unit to obtain the fourth residual enhancement feature, and then the fourth residual enhancement feature is concatenated with the third residual fusion feature to obtain the final target cascade enhancement feature.
[0029] According to an optional implementation of this embodiment, in S421, the first grouping residual unit processes the target basic features to obtain the first residual enhancement feature, including: S4211: grouping the target basic features according to channels to obtain multiple channel grouping features; S4212: extracting features from each channel grouping feature using a channel convolution block to obtain the channel convolution feature corresponding to each channel grouping feature; S4213: concatenating all channel convolution features to obtain the channel concatenated feature; S4214: performing residual connection between the channel concatenated feature and the target basic features to obtain the first residual enhancement feature.
[0030] It should be noted that, firstly, the target basic features are divided into multiple groups according to the channel dimension, thus obtaining multiple channel grouped features; for each channel grouped feature, a channel convolutional block is used for processing, so that each channel convolutional block outputs a channel convolutional feature corresponding to the channel grouped feature; then these channel convolutional features are fused by concatenation to obtain channel concatenated features; finally, the channel concatenated features are residually connected with the target basic features to obtain the first residual enhancement feature; for the second grouped residual unit, the third grouped residual unit, and the fourth grouped residual unit, the data processing steps are the same as those for the first grouped residual unit.
[0031] According to an optional implementation of this embodiment, in S4212, feature extraction is performed on each channel group feature using a channel convolutional block to obtain the channel convolutional feature corresponding to each channel group feature, including: S42121: Performing 1×1 convolution processing on the channel group features according to the first 1×1 convolutional layer to obtain the first convolutional feature; S42122: Performing batch normalization and ReLU activation processing on the first convolutional feature sequentially to obtain the first activation feature; S42123: Processing the first activation feature according to the first 3×3 convolutional layer and the second 3×3 convolutional layer respectively. Perform 3×3 convolution processing to obtain the second and third convolution features respectively; S42124: Perform batch normalization and ReLU activation processing on the second convolution feature to obtain the second activation feature, and perform batch normalization and ReLU activation processing on the third convolution feature to obtain the third activation feature; S42125: Concatenate the second and third activation features to obtain the activation fusion feature; S42126: Perform 1×1 convolution processing on the activation fusion feature according to the second 1×1 convolution layer to obtain the channel convolution feature corresponding to the channel grouping feature.
[0032] It should be noted that, firstly, the channel grouping features are processed by a first 1×1 convolutional layer to obtain the first convolutional feature; then, the first convolutional feature is batch normalized and ReLU activated sequentially to obtain the first activation feature; next, the first activation feature is processed by a first 3×3 convolutional layer and a second 3×3 convolutional layer in parallel to obtain the second and third convolutional features, respectively; then, the second and third convolutional features are batch normalized and ReLU activated sequentially to obtain the second and third activation features, respectively, and then the second and third activation features are concatenated to obtain the activation fusion feature; finally, the activation fusion feature is processed by a second 1×1 convolutional layer to obtain the channel convolutional feature corresponding to the channel grouping feature; each channel grouping feature is processed in the above manner to obtain the channel convolutional feature corresponding to each channel grouping feature.
[0033] According to an optional implementation of this embodiment, in S430, the multi-scale attention module performs multi-scale attention enhancement processing on the target cascaded enhancement features to obtain target multi-scale attention features, including: S431: performing 3×3 convolution processing on the target cascaded enhancement features according to the third 3×3 convolutional layer to obtain a fourth convolutional feature; S432: concatenating the fourth convolutional feature with the target cascaded enhancement features to obtain a first multi-scale fusion feature; S433: performing 3×3 convolution processing on the fourth convolutional feature according to the fourth 3×3 convolutional layer to obtain a fifth convolutional feature, and performing 3×3 convolution processing on the fifth convolutional feature according to the fifth 3×3 convolutional layer to obtain a sixth convolutional feature; S434: concatenating the fifth convolutional feature with the target cascaded enhancement features to obtain a first multi-scale fusion feature; The six convolutional features are concatenated to obtain the second multi-scale fusion feature; S435: The first multi-scale fusion feature is processed sequentially according to the first channel attention mechanism and the first spatial attention mechanism to obtain the first multi-scale attention feature; S436: The second multi-scale fusion feature is processed sequentially according to the second channel attention mechanism and the second spatial attention mechanism to obtain the second multi-scale attention feature; S437: The first multi-scale attention feature and the second multi-scale attention feature are concatenated to obtain the target multi-scale attention feature; wherein, the data processing process of the first channel attention mechanism and the second channel attention mechanism is the same, and the data processing process of the first spatial attention mechanism and the second spatial attention mechanism is the same.
[0034] It should be noted that, firstly, the target cascaded enhancement features are processed by a 3×3 convolutional layer to obtain the fourth convolutional feature. This fourth convolutional feature is then concatenated with the target cascaded enhancement features to obtain the first multi-scale fusion feature. Next, the fourth convolutional feature is processed by a 3×3 convolutional layer to obtain the fifth convolutional feature, and then processed by a 3×3 convolutional layer to obtain the sixth convolutional feature. Finally, the fifth and sixth convolutional features are concatenated to obtain the second multi-scale fusion feature. Then, the first channel attention is applied... The force mechanism and the first spatial attention mechanism process the first multi-scale fusion feature sequentially to obtain the first multi-scale attention feature; simultaneously, the second multi-scale fusion feature is processed sequentially through the second channel attention mechanism and the second spatial attention mechanism to obtain the second multi-scale attention feature; in this example, the data processing procedures of the first channel attention mechanism and the second channel attention mechanism are the same, and the data processing procedures of the first spatial attention mechanism and the second spatial attention mechanism are the same; finally, the first multi-scale attention feature and the second multi-scale attention feature are concatenated to obtain the target multi-scale attention feature.
[0035] According to an optional implementation of this embodiment, in step S435, the first multi-scale fusion feature is processed sequentially according to the first channel attention mechanism and the first spatial attention mechanism to obtain the first multi-scale attention feature, including: S4351: Channel attention enhancement is performed on the first multi-scale fusion feature according to the first channel attention mechanism to obtain the first channel attention enhancement feature; S4352: Spatial attention enhancement is performed on the first channel attention enhancement feature according to the first spatial attention mechanism to obtain the first multi-scale attention feature.
[0036] It should be noted that, firstly, channel attention is calculated on the first multi-scale fusion feature through a first channel attention mechanism. Specifically, max pooling and average pooling are performed on the first multi-scale fusion feature to obtain the first max pooling feature and the first average pooling feature. Then, the first max pooling feature and the first average pooling feature are processed by a parameter-sharing multilayer perceptron to obtain the first shared feature and the second shared feature. The first shared feature and the second shared feature are then added together to obtain the first pooling fusion feature. Finally, the first pooling fusion feature is processed using the Sigmoid activation function to obtain the first channel attention weight. Next, the first channel attention weight is multiplied by the first multi-scale fusion feature to obtain the first channel attention enhancement feature. Then, the first spatial attention mechanism is used to apply channel attention to the first channel. Spatial attention calculation is performed on the attention enhancement features. The first spatial attention mechanism first performs max pooling and average pooling on the first channel attention enhancement features to obtain second max pooling features and second average pooling features, respectively. The second max pooling features and second average pooling features are then concatenated to obtain a second pooling fusion feature. Next, the second pooling fusion feature is processed by a 5×5 convolution, and the feature after the 5×5 convolution is activated by Sigmoid to obtain the first spatial attention weight. Finally, the first spatial attention weight is multiplied by the first channel attention enhancement feature to obtain the first multi-scale attention feature. In this embodiment, the data processing process of the second channel attention mechanism is the same as that of the first channel attention mechanism, and the processing process of the second spatial attention mechanism is the same as that of the first spatial attention mechanism.
[0037] According to a deep learning-based sound quality detection method in this embodiment, by acquiring the target spectrogram of the target audio device and then inputting the target spectrogram into the sound quality detection network, the sound quality detection network can achieve automated and high-precision sound quality detection of the target audio device. The sound quality detection network achieves a significant improvement in sound quality detection accuracy through the design of a cascaded grouped feature enhancement module and a multi-scale attention module. The cascaded grouped feature enhancement module uses a channel grouping strategy in each internal grouped residual unit to divide the input features into multiple channel grouped features according to channels, and uses channel convolution blocks to extract features for each grouped feature, avoiding the redundant calculation of all channel features by traditional convolution, and significantly reducing the computational load and parameter scale of the network while ensuring the feature extraction effect. At the same time, the cascaded grouped feature enhancement module adopts a cascaded splicing and fusion strategy. The residual enhancement features output by each grouped residual unit are spliced and fused with the input features of the same level, and the fused features are used as the input of the next level unit. Through four levels of cascaded processing, the effective sound quality-related information in the basic features is accumulated and enhanced step by step, while gradually suppressing noise features and redundant information, so that the final output target is cascaded enhanced. The features possess more accurate and richer sound quality representation capabilities, thus effectively improving the accuracy of the network in sound quality detection. The multi-scale attention module generates features at different scales by stacking 3×3 convolutions multiple times. The features after the first 3×3 convolution are concatenated with the initial information to obtain local multi-scale information, and the features after the second and third convolutions are concatenated to obtain global multi-scale information, achieving comprehensive coverage of sound quality-related features and avoiding the limiting influence of single-scale features on the detection results. At the same time, the multi-scale attention module applies a combination of channel attention mechanism and spatial attention mechanism to the two types of multi-scale information respectively. Through the synergistic effect of the dual attention mechanism, the discriminativeness of the features is significantly improved, allowing effective features to dominate in the subsequent detection process, thereby improving the accuracy of network detection. Then, the two types of multi-scale information enhanced by attention are concatenated to generate target multi-scale attention features. This feature takes into account the advantages of local details and global trends, and integrates the attention weights of channel and spatial dimensions, which can effectively cope with the differences in spectrogram features under different audio devices and different noise environments, significantly improving the robustness and generalization ability of the sound quality detection network.
[0038] It should be noted that the deep learning-based audio quality detection method provided in this application can be executed by a deep learning-based audio quality detection system, or by a control module within that system for executing the deep learning-based audio quality detection method. This application uses an example of a deep learning-based audio quality detection system executing a deep learning-based audio quality detection method to illustrate the deep learning-based audio quality detection method provided in this application.
[0039] A deep learning-based audio quality detection system includes a data construction module: acquiring multiple spectrograms, preprocessing the spectrograms to obtain preprocessed spectrograms, and constructing a dataset based on the preprocessed spectrograms; a network construction module: constructing an audio quality detection network, which includes a basic feature extraction module, a cascaded grouping feature enhancement module, a multi-scale attention module, and an output module; a network training module: dividing the dataset into training and testing sets according to a preset ratio, training the audio quality detection network based on the training set, and testing the trained audio quality detection network based on the testing set; and an automatic detection module: acquiring the target spectrogram corresponding to the target audio device, processing the target spectrogram based on the tested audio quality detection network, and obtaining the audio quality detection result of the target audio device.
[0040] The deep learning-based audio quality detection system in this application embodiment can be a device, or a component, integrated circuit, or chip in a terminal. The device can be a mobile electronic device or a non-mobile electronic device. For example, mobile electronic devices can be mobile phones, tablets, laptops, PDAs, ultra-mobile personal computers (UMPCs), netbooks, or personal digital assistants (PDAs), etc., while non-mobile electronic devices can be servers, network-attached storage (NAS), or personal computers (PCs). This application embodiment does not impose specific limitations.
[0041] The deep learning-based audio quality detection system in this application embodiment can be a device with an operating system. This operating system can be Android, iOS, or other possible operating systems; this application embodiment does not specifically limit it.
[0042] The deep learning-based sound quality detection system provided in this application embodiment can realize the various processes and technical effects of the deep learning-based sound quality detection method in the method embodiments of Figures 1 to 2. To avoid repetition, these will not be described again here.
[0043] Optionally, this application embodiment also provides a sound quality detection device, including a processor, a memory, and a program or instructions stored in the memory and executable on the processor. When the program or instructions are executed by the processor, they implement the various processes of the above-described deep learning-based sound quality detection method embodiment and achieve the same technical effect. To avoid repetition, they will not be described again here.
[0044] This application also provides a readable storage medium storing a program or instructions. When the program or instructions are executed by a processor, they implement the various processes of the above-described embodiment of a deep learning-based sound quality detection method and achieve the same technical effect. To avoid repetition, they will not be described again here.
[0045] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.
[0046] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.
[0047] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0048] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.
Claims
1. A sound quality detection method based on deep learning, characterized in that, The method includes: acquiring multiple spectrograms; preprocessing the multiple spectrograms to obtain preprocessed spectrograms; constructing a dataset based on the multiple preprocessed spectrograms; constructing a sound quality detection network, the sound quality detection network including a basic feature extraction module, a cascaded grouping feature enhancement module, a multi-scale attention module, and an output module; dividing the dataset into a training set and a test set according to a preset ratio; training the sound quality detection network based on the training set; and testing the trained sound quality detection network based on the test set; acquiring a target spectrogram corresponding to a target audio device; processing the target spectrogram based on the tested sound quality detection network; and obtaining the sound quality detection result of the target audio device.
2. The sound quality detection method based on deep learning according to claim 1, characterized in that, The sound quality detection network processes the target spectrogram to obtain the sound quality detection result of the target audio device, including: extracting basic features from the target spectrogram using the basic feature extraction module to obtain target basic features; enhancing the target basic features using the cascaded grouping feature enhancement module to obtain target cascaded enhanced features; enhancing the target cascaded enhanced features using the multi-scale attention module to obtain target multi-scale attention features; and processing the target multi-scale attention features using the output module to obtain the sound quality detection result of the target audio device.
3. The sound quality detection method based on deep learning according to claim 2, characterized in that, The cascaded grouping feature enhancement module enhances the target basic features to obtain target cascaded enhanced features, including: processing the target basic features according to a first grouping residual unit to obtain a first residual enhanced feature, and concatenating the first residual enhanced feature with the target basic features to obtain a first residual fusion feature; processing the first residual fusion feature according to a second grouping residual unit to obtain a second residual enhanced feature, and concatenating the second residual enhanced feature with the first residual fusion feature to obtain a second residual fusion feature; processing the second residual fusion feature according to a third grouping residual unit to obtain a third residual enhanced feature, and concatenating the third residual enhanced feature with the second residual fusion feature to obtain a third residual fusion feature; processing the third residual fusion feature according to a fourth grouping residual unit to obtain a fourth residual enhanced feature, and concatenating the fourth residual enhanced feature with the third residual fusion feature to obtain the target cascaded enhanced feature; wherein the first grouping residual unit, the second grouping residual unit, the third grouping residual unit, and the fourth grouping residual unit have the same structure.
4. The sound quality detection method based on deep learning according to claim 3, characterized in that, The first grouped residual unit processes the target basic features to obtain a first residual enhanced feature, including: grouping the target basic features according to channels to obtain multiple channel grouped features; extracting features from each channel grouped feature using a channel convolutional block to obtain a channel convolutional feature corresponding to each channel grouped feature; concatenating all the channel convolutional features to obtain the channel concatenated feature; and performing residual connection between the channel concatenated feature and the target basic features to obtain the first residual enhanced feature.
5. The sound quality detection method based on deep learning according to claim 4, characterized in that, The step of extracting features from each channel group feature using a channel convolutional block to obtain the channel convolutional feature corresponding to each channel group feature includes: performing 1×1 convolution processing on the channel group feature according to a first 1×1 convolutional layer to obtain a first convolutional feature; performing batch normalization and ReLU activation processing on the first convolutional feature sequentially to obtain a first activation feature; performing 3×3 convolution processing on the first activation feature according to a first 3×3 convolutional layer and a second 3×3 convolutional layer respectively to obtain a second convolutional feature and a third convolutional feature respectively; performing batch normalization and ReLU activation processing on the second convolutional feature sequentially to obtain a second activation feature, and performing batch normalization and ReLU activation processing on the third convolutional feature sequentially to obtain a third activation feature; concatenating the second activation feature and the third activation feature to obtain an activation fusion feature; and performing 1×1 convolution processing on the activation fusion feature according to a second 1×1 convolutional layer to obtain the channel convolutional feature corresponding to the channel group feature.
6. The sound quality detection method based on deep learning according to claim 2, characterized in that, The multi-scale attention module performs multi-scale attention enhancement processing on the target cascaded enhancement features to obtain target multi-scale attention features, including: performing 3×3 convolution processing on the target cascaded enhancement features according to the third 3×3 convolutional layer to obtain a fourth convolutional feature; concatenating the fourth convolutional feature with the target cascaded enhancement features to obtain a first multi-scale fusion feature; performing 3×3 convolution processing on the fourth convolutional feature according to the fourth 3×3 convolutional layer to obtain a fifth convolutional feature, and performing 3×3 convolution processing on the fifth convolutional feature according to the fifth 3×3 convolutional layer to obtain a sixth convolutional feature; concatenating the fifth convolutional feature with the sixth convolutional feature to obtain the first multi-scale fusion feature. The first multi-scale fusion feature is processed sequentially according to the first channel attention mechanism and the first spatial attention mechanism to obtain the first multi-scale attention feature; the second multi-scale fusion feature is processed sequentially according to the second channel attention mechanism and the second spatial attention mechanism to obtain the second multi-scale attention feature; the first multi-scale attention feature and the second multi-scale attention feature are concatenated to obtain the target multi-scale attention feature; wherein, the data processing procedures of the first channel attention mechanism and the second channel attention mechanism are the same, and the data processing procedures of the first spatial attention mechanism and the second spatial attention mechanism are the same.
7. The sound quality detection method based on deep learning according to claim 6, characterized in that, The step of processing the first multi-scale fusion feature sequentially according to the first channel attention mechanism and the first spatial attention mechanism to obtain the first multi-scale attention feature includes: performing channel attention enhancement on the first multi-scale fusion feature according to the first channel attention mechanism to obtain the first channel attention enhancement feature; and performing spatial attention enhancement on the first channel attention enhancement feature according to the first spatial attention mechanism to obtain the first multi-scale attention feature.
8. A deep learning-based sound quality detection system, capable of implementing the deep learning-based sound quality detection method according to any one of claims 1-7, characterized in that, The system includes: a data construction module: acquiring multiple spectrograms, preprocessing the spectrograms to obtain preprocessed spectrograms, and constructing a dataset based on the preprocessed spectrograms; a network construction module: constructing a sound quality detection network, which includes a basic feature extraction module, a cascaded grouping feature enhancement module, a multi-scale attention module, and an output module; a network training module: dividing the dataset into a training set and a test set according to a preset ratio, training the sound quality detection network based on the training set, and testing the trained sound quality detection network based on the test set; and an automatic detection module: acquiring a target spectrogram corresponding to a target audio device, processing the target spectrogram based on the tested sound quality detection network, and obtaining the sound quality detection result of the target audio device.
9. A sound quality testing device, characterized in that, It includes a processor, a memory, and a program or instructions stored in the memory and executable on the processor, wherein the program or instructions, when executed by the processor, implement the steps of a deep learning-based audio quality detection method as described in any one of claims 1-7.
10. A readable storage medium, characterized in that, The readable storage medium stores a program or instructions that, when executed by a processor, implement the steps of a deep learning-based sound quality detection method as described in any one of claims 1-7.