Noise recognition method and device, computer equipment and storage medium
By preprocessing and feature extraction of the original noise samples, building a deep learning model and fine-tuning, the problem of poor recognition effect of existing noise recognition algorithms in diversified environments is solved, and efficient and accurate noise recognition is achieved.
Patent Information
- Application Number
- CN202411374911.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-29
- Publication Date
- 2025-01-10
AI Technical Summary
When existing noise recognition algorithms face diverse environments and no noise types, their recognition effect is reduced, their generalization capabilities are insufficient, and they rely on clean voice data. The scale of the data set is limited, resulting in insufficient robustness.
By collecting original noise samples for preprocessing, extracting MFCC features, annotating feature samples, building deep learning models, pre-training and fine-tuning, generating noise recognition models, and realizing the recognition of target noise data.
It improves the efficiency and accuracy of noise recognition, enhances the robustness and versatility of the model, and adapts to noise recognition in diverse environments.
Smart Images

Figure CN119296500A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the fields of artificial intelligence technology and financial technology, and in particular to a noise recognition method, device, computer equipment and computer-readable storage medium. Background Art
[0002] At present, with the development of computer technology, more and more technologies are applied in the financial field. The traditional financial industry is gradually transforming to Fintech, and noise recognition technology is no exception. For example, in the intelligent assistant or chatbot scenarios of financial institutions (such as banks), noise recognition technology can help identify and filter background noise, improve the accuracy of speech recognition, and thus improve user experience. However, due to the security and real-time requirements of the financial industry, higher requirements are also placed on noise recognition technology.
[0003] At present, with the popularization of smart devices and the development of mobile communication technology, speech recognition and voiceprint recognition technologies have been widely used in many fields such as finance, security, and entertainment. The core of these technologies lies in accurately identifying and processing voice signals to achieve effective voice transcription, user identity authentication and other functions. However, voice signals in real environments are often accompanied by various background noises, which pose a major challenge to the accuracy and reliability of speech recognition and voiceprint recognition. In order to improve the performance of speech recognition and voiceprint recognition systems, noise processing has become a key technical problem. In the field of professional recording, noise interference can be directly reduced during the recording stage by using noise reduction devices such as special digital signal processor (DSP) chips. However, these devices are usually expensive, which limits their popularity in the consumer market.
[0004] Currently, in most daily usage scenarios, such as mobile phone calls and application recordings, users often cannot rely on professional noise reduction equipment. Therefore, the original voice signal will inevitably be mixed with various types of noise such as traffic noise, wind noise, and human voice conversations. The complexity and variability of these noises put higher demands on existing noise recognition algorithms. Although some noise recognition algorithms have been proposed and applied to actual scenarios, they still have some limitations in practical applications, such as:
[0005] 1. Insufficient generalization ability: Some existing noise recognition algorithms can only effectively recognize specific types of noise, such as vehicle noise, air conditioning noise, etc., and the recognition effect is significantly reduced when facing other types of noise, which limits the application of this type of algorithm in diverse environments;
[0006] 2. Reliance on clean speech data: Some existing noise recognition algorithms rely on pre-recorded clean speech data as a reference, and identify and remove noise by comparing these clean speech data. Although this method works well under certain conditions, it requires the support of a large amount of clean non-noise speech data, which limits the versatility and flexibility of this type of algorithm.
[0007] 3. Limited dataset size: Some existing noise recognition algorithms often rely on limited datasets during the training phase, which results in insufficient robustness of these algorithms when faced with unprecedented noise types or complex noise environments.
[0008] Based on this, how to provide a noise recognition method, apparatus, computer device and computer-readable storage medium to improve the efficiency and accuracy of noise recognition is a problem that urgently needs to be solved by those skilled in the art. Summary of the invention
[0009] In view of the above-mentioned deficiencies in the prior art, an object of the present invention is to provide a noise recognition method, apparatus, computer device and computer-readable storage medium, aiming to solve the problem of how to improve the efficiency and accuracy of noise recognition.
[0010] In order to achieve the above object, the present invention adopts the following technical solutions:
[0011] In a first aspect, the present invention provides a noise recognition method, which comprises:
[0012] Collecting a number of original noise samples, and preprocessing the number of original noise samples to obtain target noise samples;
[0013] Extracting features of the target noise sample to obtain an MFCC feature sample;
[0014] Extracting target feature samples from the MFCC feature samples, and labeling the target feature samples to obtain label samples;
[0015] Using the MFCC feature samples to train a pre-built deep learning model to generate a pre-trained model;
[0016] Fine-tuning the pre-trained model using the label samples to generate a noise recognition model;
[0017] Based on the noise recognition model, noise recognition of target noise data is achieved.
[0018] In a second aspect, the present invention provides a noise recognition device, comprising:
[0019] A collection module, used for collecting a number of original noise samples, and preprocessing the number of original noise samples to obtain a target noise sample;
[0020] A feature extraction module is used to extract features from the target noise sample to obtain an MFCC feature sample;
[0021] A label marking module is used to extract target feature samples from the MFCC feature samples and label the target feature samples to obtain label samples;
[0022] A model training module, used to train a pre-built deep learning model using the MFCC feature samples to generate a pre-trained model;
[0023] A model fine-tuning module, used to fine-tune the pre-trained model using the label samples to generate a noise recognition model;
[0024] The noise recognition module is used to realize noise recognition for target noise data based on the noise recognition model.
[0025] In a third aspect, the present invention provides a computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the noise recognition method as described above when executing the computer program.
[0026] In a fourth aspect, the present invention provides a computer-readable storage medium storing a computer program, wherein the computer program implements the noise recognition method as described above when executed by a processor.
[0027] Compared with the prior art, the present invention provides a noise recognition method, device, computer equipment and computer-readable storage medium, wherein a plurality of original noise samples are collected, the plurality of original noise samples are preprocessed to obtain a target noise sample; feature extraction is performed on the target noise sample to obtain an MFCC feature sample; target feature samples are extracted from the MFCC feature samples, and the target feature samples are labeled to obtain a label sample; a pre-constructed deep learning model is trained using the MFCC feature samples to generate a pre-trained model; the pre-trained model is fine-tuned using the label samples to generate a noise recognition model; based on the noise recognition model, noise recognition of target noise data is realized; thereby, the efficiency and accuracy of noise recognition can be improved through the present invention. BRIEF DESCRIPTION OF THE DRAWINGS
[0028] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0029] Figure 1 A schematic diagram of an application environment of a noise recognition method provided by an embodiment of the present invention.
[0030] Figure 2 A flowchart of a noise recognition method provided by an embodiment of the present invention is shown.
[0031] Figure 3 A schematic diagram of a program module of a noise recognition device provided by an embodiment of the present invention.
[0032] Figure 4 A schematic diagram of the structure of a computer device provided by an embodiment of the present invention.
[0033] Figure 5 Another structural schematic diagram of a computer device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0034] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0035] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.
[0036] It should also be understood that the term "and / or" used in the present description and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
[0037] As used in the present specification and the appended claims, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0038] In addition, in the description of the present specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0039] References to "one embodiment" or "some embodiments" etc. described in the present specification mean that one or more embodiments of the present invention include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0040] It should be understood that the order of execution of the steps in the following embodiments does not imply a precedence of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present invention.
[0041] In order to illustrate the technical solution of the present invention, specific embodiments are provided below for illustration.
[0042] A noise recognition method provided by an embodiment of the present invention can be applied in Figure 1In the application environment shown, the client and the server communicate through the network. The client includes but is not limited to PDAs, desktop computers, laptops, ultra-mobile personal computers (UMPCs), netbooks, cloud computing devices, personal digital assistants (PDAs) and other computer devices. The server can be an independent server or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms.
[0043] See also Figure 2 An embodiment of the present invention provides a noise recognition method, wherein the method comprises the following steps:
[0044] S100, collecting a number of original noise samples, and preprocessing the original noise samples to obtain a target noise sample;
[0045] S200, extracting features from the target noise sample to obtain an MFCC feature sample;
[0046] S300, extracting target feature samples from the MFCC feature samples, and labeling the target feature samples to obtain label samples;
[0047] S400, training a pre-built deep learning model using the MFCC feature samples to generate a pre-trained model;
[0048] S500, fine-tuning the pre-trained model using the label sample to generate a noise recognition model;
[0049] S600: Implement noise recognition for target noise data based on the noise recognition model.
[0050] In specific implementation, this embodiment first collects and preprocesses the original noise samples to ensure the quality and diversity of the data, laying a solid foundation for subsequent feature extraction; then, MFCC (Mel Frequency Cepstral Coefficient), a feature extraction technology used for speech and audio analysis, is used to extract key features from the target noise samples, which can effectively capture the spectral characteristics of the noise; then, according to the specific noise recognition requirements, the most representative target features are screened from the MFCC feature samples, and accurately labeled to generate label samples. This process not only improves the pertinence of subsequent model fine-tuning training, but also enables the model to learn the specific features and categories of the noise samples through the guidance of the label samples; then, the pre-built deep learning model is trained using the MFCC feature samples to generate a pre-trained model, which utilizes the powerful ability of deep learning in processing complex pattern recognition tasks; then, the pre-trained model is fine-tuned using the label samples to further optimize the performance of the model, making it more suitable for specific noise recognition tasks; finally, based on the fine-tuned noise recognition model, the target noise data can be quickly and accurately recognized, and effective classification and recognition of noise is achieved. This implementation method ensures high efficiency and high accuracy of the noise recognition process by combining advanced feature extraction technology and deep learning models, as well as targeted preprocessing and fine-tuning steps. That is, this implementation method can improve the efficiency and accuracy of noise recognition and provide an effective solution for noise recognition in various application scenarios.
[0051] Furthermore, in one embodiment, the noise identification method, wherein the step S100, collecting a number of original noise samples, preprocessing the number of original noise samples to obtain a target noise sample, specifically comprises the steps of:
[0052] Collect several raw noise samples containing various noise types;
[0053] After data cleaning, signal enhancement, format conversion and audio segmentation are performed on the plurality of original noise samples, target noise samples are obtained.
[0054] In specific implementation, this embodiment optimizes and standardizes the original noise samples through a carefully designed preprocessing process, thereby significantly improving the efficiency and accuracy of subsequent noise recognition tasks; first, by collecting samples containing multiple noise types, the diversity and representativeness of the data set are ensured, providing a wide range of noise features for subsequent model training; then, the data cleaning step effectively removes invalid or interfering data, such as silent segments or outliers, thereby purifying the data set and reducing the negative impact of noise on model training; the signal enhancement operation improves the quality of the target noise signal and enhances its significance in the audio, making feature extraction more accurate; format conversion ensures that all audio samples are processed in a unified format, simplifying the subsequent processing process; finally, the audio segmentation operation cuts long audio files into shorter segments containing single or multiple noise events, which not only improves processing efficiency, but also helps to more accurately locate and identify noise events; overall, the steps of this embodiment lay a solid foundation for building a noise recognition model with strong robustness and high generalization ability.
[0055] The specific implementation process of the steps in this embodiment is roughly as follows:
[0056] 1. Original noise sample collection:
[0057] Determine the type of noise that needs to be identified, such as traffic noise, human voices, animal calls, etc.;
[0058] Obtain audio samples containing these noise types, i.e., raw noise samples, through field recordings, public datasets, or cooperative institutions;
[0059] Make sure the original noise samples cover different environments, time periods, and devices to increase the diversity of the data;
[0060] 2. Data cleaning:
[0061] Examine the raw noise samples to identify and mark sections containing invalid data, such as long periods of silence, recording errors, or non-target noise;
[0062] Use automated tools or manual methods to remove or replace these invalid data to improve data quality;
[0063] 3. Signal enhancement:
[0064] De-noise the original noise samples, using algorithms such as spectral subtraction and Wiener filtering to reduce background noise and highlight the target noise signal;
[0065] If necessary, perform volume standardization to ensure consistent volume levels between samples to avoid affecting subsequent processing due to volume differences;
[0066] 4. Format conversion:
[0067] Convert all raw noise samples to a unified format and sampling rate, such as WAV format with a sampling rate of 16kHz;
[0068] Ensure that the audio quality is not lost during the conversion process and all necessary noise characteristics are preserved;
[0069] 5. Audio segmentation:
[0070] Split long audio files from original noise samples into shorter segments based on the duration and characteristics of the noise events;
[0071] Each segment should contain a complete noise event to facilitate feature extraction and model training;
[0072] Either fixed-length segmentation or dynamic segmentation methods based on noise event detection can be used;
[0073] Through the above process, this embodiment can effectively prepare high-quality target noise samples suitable for noise recognition, laying a solid foundation for subsequent feature extraction and model training.
[0074] Furthermore, in one embodiment, the noise recognition method, wherein the step S200, extracting features from the target noise sample to obtain an MFCC feature sample, specifically comprises the steps of:
[0075] Performing frame segmentation on each audio data in the target noise sample according to a preset frame length;
[0076] Performing a short-time Fourier transform on each frame of the audio data to obtain a short-term power spectrum;
[0077] Filtering the short-term power spectrum using a Mel filter to obtain a Mel spectrum;
[0078] Taking the logarithm of the Mel spectrum to obtain a logarithmic Mel spectrum graph;
[0079] Performing discrete cosine transform on the logarithmic Mel spectrogram to obtain MFCC features;
[0080] The MFCC features of each of the audio data are integrated to obtain MFCC feature samples.
[0081] In specific implementation, this embodiment realizes the extraction of key Mel-frequency cepstral coefficient (MFCC) features from the target noise sample through a series of carefully designed audio data processing technologies. These features can effectively capture and express the spectral characteristics of the audio data. First, each audio data in the target noise sample is frame-segmented according to a preset frame length, so that each frame of the audio data contains sufficient time information for local analysis. Then, the short-time Fourier transform (STFT) converts the time domain signal of each frame of the audio data into a frequency domain signal, thereby obtaining a short-term power spectrum. Then, the short-term power spectrum is filtered using a Mel filter to simulate the perception sensitivity of the human ear to sounds of different frequencies to obtain a Mel spectrum. Then, Taking the logarithm of the Mel spectrum further enhances the perception of changes in sound intensity, so that the logarithmic Mel spectrum can more accurately reflect the human ear's perception of sound; then, by performing discrete cosine transform (DCT) on the logarithmic Mel spectrum, MFCC features are extracted, and these features can compactly represent the key information of the audio data; finally, the MFCC features of all audio data are integrated to form MFCC feature samples for subsequent model training, and these samples provide high-quality input data for building an efficient and accurate noise recognition model; the method of this embodiment not only improves the accuracy of feature extraction, but also enhances the model's ability to recognize different types of noise, thereby achieving a significant improvement in the technical effect in the field of noise recognition.
[0082] The specific implementation process of the steps in this embodiment is roughly as follows:
[0083] 1. Frame segmentation:
[0084] Determine an appropriate frame length, usually 20-40 milliseconds, depending on the audio sampling rate and noise characteristics;
[0085] Split each audio data in the target noise sample into overlapping frames; each frame usually contains a fixed number of sample points, for example, if the sampling rate is 16kHz and the frame length is 40ms, each frame contains 640 sample points;
[0086] There may be a certain overlap between frames, such as a 50% overlap, which helps to maintain signal continuity at the frame boundaries;
[0087] 2. Short-time Fourier transform (STFT):
[0088] Apply a window function, such as a Hamming window, to each frame of audio data to reduce discontinuities at frame boundaries;
[0089] Perform short-time Fourier transform (STFT) on the frame processed by the window function to convert the time domain signal into a frequency domain signal to obtain a short-term power spectrum;
[0090] 3. Mel filter bank:
[0091] A group of Mel filters is used to filter the short-term power spectrum; the Mel filter group is composed of multiple triangular filters, and the frequency response curve of each filter simulates the auditory characteristics of the human ear;
[0092] Each filter outputs the energy of the signal within the corresponding frequency range, thus obtaining the Mel spectrum;
[0093] 4. Logarithmic transformation:
[0094] Take the logarithm of the Mel spectrum to get a logarithmic Mel spectrum; this helps reduce the dynamic range and make the features of the spectrum more prominent;
[0095] 5. Discrete Cosine Transform (DCT):
[0096] Perform discrete cosine transform on the logarithmic Mel spectrum to extract the most important cepstral coefficients, usually taking the first 13 coefficients as MFCC features;
[0097] DCT is a transform that converts a signal from the time domain to the frequency domain. It is used in MFCC feature extraction to reduce the dimensionality of the data while retaining the most important information.
[0098] 6. Feature integration:
[0099] Integrate the MFCC features of all audio data to obtain MFCC feature samples;
[0100] MFCC feature samples can be further used to train machine learning models, such as deep learning networks, to achieve automatic recognition and classification of noise;
[0101] Through the above process, this embodiment can extract MFCC feature samples that can represent the characteristics of the target noise sample from the target noise sample, and provide high-quality input data for the subsequent construction of an efficient and accurate noise recognition model.
[0102] Furthermore, in one embodiment, the noise recognition method, wherein the step S300, extracting target feature samples from the MFCC feature samples, and labeling the target feature samples to obtain label samples, specifically comprises the steps of:
[0103] Determine noise identification requirements and noise labeling strategies;
[0104] According to the noise recognition requirement, extracting target feature samples from the MFCC feature samples;
[0105] According to the noise labeling strategy, the target feature sample is labeled to obtain a labeled sample.
[0106] In specific implementation, this embodiment ensures the pertinence and effectiveness of the sample extraction and labeling process by accurately defining the noise recognition requirements and noise labeling strategies, thereby significantly improving the accuracy and robustness of the subsequent noise recognition model; first, by predetermining the specific requirements and labeling strategies for noise recognition, a clear direction and standard are set for the entire recognition process; then, according to these requirements, the target feature samples that best represent different noise types are carefully selected from the MFCC feature samples. This selection process ensures the data quality and relevance of subsequent model training; finally, the target feature samples are carefully labeled according to the established labeling strategy to generate samples with accurate labels. These labeled samples provide key data support for training efficient and accurate noise recognition models; the entire process not only improves the representativeness of the features and the accuracy of the labeling, but also lays a solid foundation for building a noise recognition model that can be widely applied to various noise environments through the carefully designed sample extraction and labeling process.
[0107] The specific implementation process of the steps in this embodiment is roughly as follows:
[0108] 1. Determine noise identification requirements:
[0109] Analyze the application scenario and identify the type of noise that needs to be identified (such as vehicle noise, human voice, industrial noise, etc.);
[0110] 2. Determine the noise labeling strategy:
[0111] Design a labeling system to define labels for each noise type;
[0112] Determine the labeling rules, including how to deal with noise mixing, noise intensity classification, etc.;
[0113] 3. Target feature sample extraction:
[0114] According to the determined noise recognition requirements, the features most relevant to the target noise type are selected from the MFCC feature samples, namely, the target feature samples;
[0115] This may include selecting specific MFCC coefficients, energy values, or calculating feature statistics (such as mean, variance);
[0116] 4. Target feature sample annotation:
[0117] According to the determined noise labeling strategy, the extracted target feature samples are labeled;
[0118] The labeling process may involve manual listening or the use of semi-automatic tools to ensure the accuracy of labeling;
[0119] 5. Generate label samples:
[0120] Associate the marked labels with the corresponding feature samples to form label samples;
[0121] Label samples will be used to train noise recognition models, and the consistency and readability of the data must be ensured;
[0122] 6. Verification and optimization:
[0123] Perform quality checks on label samples to ensure label accuracy and consistency;
[0124] Adjust noise identification requirements and noise labeling strategies as needed to optimize sample extraction and labeling processes;
[0125] Through the above process, this embodiment can systematically extract and annotate high-quality label samples from MFCC feature samples, providing accurate and reliable fine-tuning data for training the noise recognition model.
[0126] Furthermore, in one embodiment, the noise recognition method, wherein the step S400, using the MFCC feature samples to train a pre-built deep learning model to generate a pre-trained model, specifically comprises the steps of:
[0127] Build deep learning models based on the Transformer architecture;
[0128] Using the MFCC feature samples to train and test the deep learning model;
[0129] When the deep learning model meets the preset preliminary performance requirements, a pre-trained model is generated.
[0130] In specific implementation, this embodiment adopts an advanced Transformer architecture to construct a deep learning model, and uses its self-attention mechanism to effectively process sequence data, so as to capture long-term dependencies and complex noise patterns in MFCC feature samples; by using MFCC feature samples to train and test the deep learning model, the deep learning model can learn feature representations to distinguish different noise types and improve recognition accuracy; when the deep learning model shows results that meet the preset preliminary performance requirements during the training and testing process, a pre-trained model is generated, which indicates that the generated pre-trained model already has good initial performance, which lays a solid foundation for further fine-tuning and practical application, and ensures the efficiency and reliability of the noise recognition task.
[0131] The specific implementation process of the steps in this embodiment is roughly as follows:
[0132] 1. Build the Transformer model:
[0133] Build deep learning models based on the Transformer architecture, which typically includes multi-head self-attention mechanisms and positional encodings to process sequence data;
[0134] Determine key parameters such as the number of layers, number of heads, and model dimensions of the model to suit specific noise recognition tasks;
[0135] 2. Prepare training data:
[0136] Organize MFCC feature samples into a format acceptable to deep learning models, such as standardized feature values, to ensure data consistency and readability;
[0137] Divide the dataset into training, validation, and test sets to facilitate the training and evaluation of deep learning models;
[0138] 3. Model training:
[0139] Use the training set data to train the deep learning model and optimize the model parameters through back propagation and gradient descent algorithms;
[0140] Adjust hyperparameters such as learning rate, batch size, and number of training rounds to improve the training efficiency and performance of deep learning models;
[0141] 4. Model testing and evaluation:
[0142] Verify the performance of the deep learning model on the validation set, and use indicators such as accuracy, recall, and F1 score to evaluate the recognition effect of the deep learning model;
[0143] Adjust the model structure or parameters according to the test results and perform multiple iterations of training until the model performance reaches a satisfactory level;
[0144] 5. Generate pre-trained model:
[0145] Once the deep learning model meets the preset preliminary performance requirements on the test set, such as accuracy exceeding a certain threshold, the model is saved as a pre-trained model;
[0146] The pre-trained model can be used for further fine-tuning or directly used for noise recognition tasks;
[0147] Through the above process, this embodiment can effectively utilize the powerful capabilities of the Transformer architecture to build and train a pre-trained model that can accurately identify various noises.
[0148] Furthermore, in one embodiment, the noise recognition method, wherein the step S500, using the label sample to fine-tune the pre-trained model to generate a noise recognition model, specifically comprises the steps of:
[0149] Fine-tuning the pre-trained model using the labeled samples;
[0150] When the pre-trained model meets the preset target performance requirements, a noise recognition model is generated.
[0151] In specific implementation, this embodiment further improves and optimizes the model performance by fine-tuning the pre-trained model using labeled samples; in this process, the pre-trained model can learn the characteristics and patterns of specific noise data more deeply, thereby improving the accuracy and robustness of noise recognition; when the pre-trained model meets the preset target performance requirements in the test, such as high accuracy and low false alarm rate, it is confirmed as an effective noise recognition model, which indicates that the noise recognition model is ready to be deployed in practical applications to provide efficient and reliable noise recognition services; this fine-tuning method not only enhances the adaptability of the model to specific tasks, but also ensures its stability and effectiveness in diverse environments, providing strong technical support for noise monitoring and management.
[0152] The specific implementation process of the steps in this embodiment is roughly as follows:
[0153] 1. Configure fine-tuning parameters:
[0154] Adjust the learning rate and other hyperparameters to suit the fine-tuning phase; typically, the learning rate during fine-tuning is lower than during initial training to avoid drastic adjustments to the pre-trained model.
[0155] Determine the number of fine-tuning rounds and batch size to ensure that the pre-trained model can learn effective features even with limited data;
[0156] 2. Execution fine-tuning:
[0157] Use the obtained labeled samples to further fine-tune the pre-trained model; in this process, the weights of the model will be adjusted according to the new data to better adapt to the noise recognition task;
[0158] Monitor performance metrics during training, such as loss function and accuracy, to ensure that the model performs well during fine-tuning;
[0159] 3. Performance evaluation:
[0160] Evaluate the performance of the fine-tuned model on the validation set to ensure that it meets the preset target performance requirements, such as accuracy, recall, etc.
[0161] If the performance does not meet the requirements, you may need to further adjust the fine-tuning strategy, such as changing hyperparameters or increasing training data;
[0162] 4. Generate noise recognition model:
[0163] Once the model's performance on the validation set meets the preset target performance requirements, save the model as a noise recognition model and prepare to deploy it in actual applications;
[0164] Conduct final tests to verify the stability and accuracy of the noise recognition model in a real environment;
[0165] Through the above process, this embodiment can ensure that the pre-trained model is optimized for a specific task and generate an efficient noise recognition model that can accurately recognize various noises.
[0166] Furthermore, in one embodiment, the noise recognition method, wherein the step S600, based on the noise recognition model, realizes noise recognition for target noise data, specifically comprises the steps of:
[0167] Acquire target noise data to be identified, and extract target MFCC features corresponding to the target noise data;
[0168] Inputting the target MFCC features into the noise recognition model to generate a noise recognition result of the target noise data;
[0169] The noise recognition result is output or displayed.
[0170] In specific implementation, this embodiment realizes a complete noise recognition process from acquiring target noise data to outputting noise recognition results. By extracting the target MFCC features corresponding to the target noise data and analyzing them using the trained noise recognition model, different noise types can be accurately identified and classified. This process not only improves the automation level of noise recognition, but also enables users to quickly understand and respond to the noise environment through intuitive output or display methods, thereby providing effective technical support in the fields of noise monitoring, environmental assessment, and acoustic research; in addition, this automated noise recognition technology also helps to reduce manual intervention, improve recognition efficiency, reduce costs, and provide data support for further acoustic analysis and environmental improvement measures.
[0171] The specific implementation process of the steps in this embodiment is roughly as follows:
[0172] 1. Obtain target noise data:
[0173] Capturing environmental sounds, which may include a variety of noise sources, through recording devices or data collection systems;
[0174] Ensure that the recording quality meets the analysis requirements, such as appropriate signal-to-noise ratio and sufficient recording duration;
[0175] 2. Extract target MFCC features:
[0176] Preprocess the acquired noise data, including denoising, segmentation and normalization, to improve the accuracy of subsequent feature extraction;
[0177] The MFCC algorithm is used to extract the features of the noise data, including calculating the Mel spectrum, taking the logarithm, applying the discrete cosine transform, etc., to obtain the MFCC coefficients that can represent the noise characteristics, that is, the target MFCC features;
[0178] 3. Input the target MFCC features into the noise recognition model:
[0179] Format the extracted target MFCC features into the data structure required for model input, such as adjusting the data dimension or standardizing the feature values;
[0180] Input the processed feature data into the pre-trained noise recognition model;
[0181] 4. Generate noise recognition results:
[0182] The noise recognition model analyzes the input target MFCC features and identifies the type or category of noise through internal weights and algorithm calculations;
[0183] The noise identification model outputs a noise identification result, which may include the type of noise, confidence, or distinction from other noise types;
[0184] 5. Output or display the noise recognition results:
[0185] The noise recognition results are presented to the user in an easy-to-understand form, such as through charts, sound waveforms or text labels; of course, the noise recognition results can also be output to a specified location according to actual needs;
[0186] If necessary, the noise identification results can be integrated into a larger system, such as an environmental monitoring system or an automated control system, to achieve real-time response or historical data analysis;
[0187] 6. Post-processing and feedback (optional):
[0188] Further fine-tune or optimize the noise recognition model based on user feedback or system performance evaluation to improve recognition accuracy and robustness;
[0189] Regularly update the noise recognition model to adapt to new noise environments or changing data distributions;
[0190] Through the above process, this embodiment can realize the process from the collection of target noise data to be identified to the output or display of the final noise identification result, thereby providing a complete noise identification solution for the user.
[0191] It can be seen from the above method embodiments that the noise recognition method provided by the present invention includes: collecting a number of original noise samples, preprocessing the several original noise samples to obtain target noise samples; extracting features from the target noise samples to obtain MFCC feature samples; extracting target feature samples from the MFCC feature samples, and labeling the target feature samples to obtain label samples; using the MFCC feature samples to train a pre-built deep learning model to generate a pre-trained model; using the label samples to fine-tune the pre-trained model to generate a noise recognition model; based on the noise recognition model, realizing noise recognition for target noise data. In this way, the efficiency and accuracy of noise recognition can be improved by the method of the present invention.
[0192] It can be understood that the noise recognition method provided in the embodiment of the present invention can be applied to noise recognition scenarios related to the field of financial technology. Specifically, the noise recognition function can be integrated into the intelligent assistant or chat robot scenarios of financial institutions (such as banks). Noise recognition technology can help intelligent assistants or chat robots identify and filter background noise, improve the accuracy of speech recognition, and thus improve user experience.
[0193] It should be understood that, although the present application provides method operation steps as described in the embodiments or flowcharts, more or less operation steps may be included based on conventional or non-creative labor, and these operation steps are not necessarily performed in sequence according to the embodiment or flowchart. The order of steps listed in the embodiment or flowchart is only one way of executing the order of many steps, and does not represent the only execution order. It should be noted that there is not necessarily a certain order between the above steps. A person of ordinary skill in the art can understand from the description of the embodiment of the present invention that in different embodiments, the above steps may have different execution orders, that is, they may be executed in parallel, or they may be executed in exchange, etc. Moreover, at least a part of the steps in the embodiment or flowchart may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but may be executed at different times, and the execution order of these sub-steps or stages is not necessarily performed in sequence, but may be executed in turn, alternately or synchronously with other steps or at least a part of the sub-steps or stages of other steps.
[0194] Based on the above method embodiment, please refer to Figure 3 Another embodiment of the present invention further provides a noise identification device, wherein the device comprises:
[0195] The collecting module 11 is used to collect a number of original noise samples and pre-process the original noise samples to obtain a target noise sample;
[0196] A feature extraction module 12 is used to extract features from the target noise sample to obtain an MFCC feature sample;
[0197] The label marking module 13 is used to extract target feature samples from the MFCC feature samples, and label the target feature samples to obtain label samples;
[0198] A model training module 14 is used to train a pre-built deep learning model using the MFCC feature samples to generate a pre-trained model;
[0199] A model fine-tuning module 15, used to fine-tune the pre-trained model using the label samples to generate a noise recognition model;
[0200] The noise recognition module 16 is used to realize noise recognition for target noise data based on the noise recognition model.
[0201] Furthermore, in one embodiment, in the noise identification device, the collection module 11 is specifically used for:
[0202] Collect several raw noise samples containing various noise types;
[0203] After data cleaning, signal enhancement, format conversion and audio segmentation are performed on the plurality of original noise samples, target noise samples are obtained.
[0204] Furthermore, in one embodiment, in the noise recognition device, the feature extraction module 12 is specifically used for:
[0205] Performing frame segmentation on each audio data in the target noise sample according to a preset frame length;
[0206] Performing a short-time Fourier transform on each frame of the audio data to obtain a short-term power spectrum;
[0207] Filtering the short-term power spectrum using a Mel filter to obtain a Mel spectrum;
[0208] Taking the logarithm of the Mel spectrum to obtain a logarithmic Mel spectrum graph;
[0209] Performing discrete cosine transform on the logarithmic Mel spectrogram to obtain MFCC features;
[0210] The MFCC features of each of the audio data are integrated to obtain MFCC feature samples.
[0211] Furthermore, in one embodiment, in the noise identification device, the label marking module 13 is specifically used to:
[0212] Determine noise identification requirements and noise labeling strategies;
[0213] According to the noise recognition requirement, extracting target feature samples from the MFCC feature samples;
[0214] According to the noise labeling strategy, the target feature sample is labeled to obtain a labeled sample.
[0215] Furthermore, in one embodiment, in the noise recognition device, the model training module 14 is specifically used for:
[0216] Build deep learning models based on the Transformer architecture;
[0217] Using the MFCC feature samples to train and test the deep learning model;
[0218] When the deep learning model meets the preset preliminary performance requirements, a pre-trained model is generated.
[0219] Furthermore, in one embodiment, in the noise recognition device, the model fine-tuning module 15 is specifically used for:
[0220] Fine-tuning the pre-trained model using the labeled samples;
[0221] When the pre-trained model meets the preset target performance requirements, a noise recognition model is generated.
[0222] Furthermore, in one embodiment, the noise recognition device, wherein the noise recognition module 16 is specifically used for:
[0223] Acquire target noise data to be identified, and extract target MFCC features corresponding to the target noise data;
[0224] Inputting the target MFCC features into the noise recognition model to generate a noise recognition result of the target noise data;
[0225] The noise recognition result is output or displayed.
[0226] It should be noted that in the embodiment of the device of the present invention, the information interaction, execution process and other contents between the above-mentioned modules are based on the same concept as the embodiment of the method of the present invention. Their specific functions and technical effects can be found in the aforementioned method embodiment part and will not be repeated here.
[0227] Based on the above method embodiment, another embodiment of the present invention further provides a computer device, which may be a server, and its internal structure diagram may be as follows: Figure 4As shown. The computer device includes a processor, a memory, a network interface and a database connected via a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, the functions or steps of the noise identification method service side in any of the above method embodiments are implemented.
[0228] Based on the above method embodiment, another embodiment of the present invention further provides a computer device, which may be a client, and its internal structure diagram may be as follows: Figure 5 As shown. The computer device includes a processor, a memory, a network interface, a display screen and an input device connected via a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The network interface of the computer device is used to communicate with an external terminal via a network connection. When the computer program is executed by the processor, the functions or steps of the client side of the noise recognition method in any of the above method embodiments are implemented.
[0229] Those skilled in the art will understand that Figure 4 and Figure 5 The structural schematic diagram shown in the figure is only a schematic diagram of a partial structure related to the solution of the present invention, and does not constitute a limitation on the computer device to which the solution of the present invention is applied. The specific computer device may include more components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0230] The processor may be a CPU, or other general-purpose processors, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor, or the processor may be any conventional processor, etc.
[0231] Among them, the memory includes a readable storage medium, an internal memory, etc., wherein the internal memory can be the memory of a computer device, and the internal memory provides an environment for the operation of an operating system and computer-readable instructions in the readable storage medium. The readable storage medium can be a hard disk of a computer device, and in other embodiments, it can also be an external storage device of a computer device, for example, a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on a computer device. Further, the memory can also include both an internal storage unit of a computer device and an external storage device. The memory is used to store an operating system, an application program, a boot loader (BootLoader), data, and other programs, such as the program code of a computer program, etc. The memory can also be used to temporarily store data that has been output or is to be output.
[0232] Based on the above method embodiments, another embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, wherein when the computer program is executed by a processor, the noise recognition method in any of the above method embodiments is implemented. The computer-readable storage medium may be non-volatile or volatile.
[0233] It should be noted that the above-mentioned functions or steps that can be implemented by the computer-readable storage medium or computer device, and the technical effects brought about by the functions / steps, can be found in the relevant descriptions in the aforementioned method embodiments. To avoid repetition, they will not be described one by one here.
[0234] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM). The disclosed memory components or memories of the operating environments described herein are intended to comprise one or more of these and / or any other suitable types of memory.
[0235] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of the present invention. The specific working process of the units and modules in the above-mentioned device can refer to the corresponding process in the above-mentioned method embodiment, which will not be repeated here. If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium.
[0236] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0237] In the embodiments provided by the present invention, it should be understood that the disclosed devices / computer equipment and methods can be implemented in other ways. For example, the device / computer equipment embodiments described above are only schematic, for example, the division of modules or units is only a logical function division, and there may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0238] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0239] It should be noted that if software tools or components other than those of the Company appear in the embodiments of the present application, they are only used for illustration and do not represent actual use. The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit them; although the present invention has been described in detail with reference to the above embodiments, a person of ordinary skill in the art should understand that the technical solutions described in the above embodiments can still be modified, or some of the technical features thereof can be replaced by equivalents; and these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention, and should be included in the protection scope of the present invention.
Claims
1. A noise identification method, characterized in that: include: Collecting a number of original noise samples, and preprocessing the number of original noise samples to obtain target noise samples; Extracting features of the target noise sample to obtain an MFCC feature sample; Extracting target feature samples from the MFCC feature samples, and labeling the target feature samples to obtain label samples; Using the MFCC feature samples to train a pre-built deep learning model to generate a pre-trained model; Fine-tuning the pre-trained model using the label samples to generate a noise recognition model; Based on the noise recognition model, noise recognition of target noise data is achieved.
2. The noise identification method according to claim 1, characterized in that: The collecting of a plurality of original noise samples and preprocessing of the plurality of original noise samples to obtain a target noise sample comprises: Collect several raw noise samples containing various noise types; After data cleaning, signal enhancement, format conversion and audio segmentation are performed on the plurality of original noise samples, target noise samples are obtained.
3. The noise identification method according to claim 1, characterized in that: The step of extracting features from the target noise sample to obtain an MFCC feature sample includes: Performing frame segmentation on each audio data in the target noise sample according to a preset frame length; Performing a short-time Fourier transform on each frame of the audio data to obtain a short-term power spectrum; Filtering the short-term power spectrum using a Mel filter to obtain a Mel spectrum; Taking the logarithm of the Mel spectrum to obtain a logarithmic Mel spectrum graph; Performing discrete cosine transform on the logarithmic Mel spectrogram to obtain MFCC features; The MFCC features of each of the audio data are integrated to obtain MFCC feature samples.
4. The noise identification method according to claim 1, characterized in that: The step of extracting a target feature sample from the MFCC feature sample and labeling the target feature sample to obtain a label sample includes: Determine noise identification requirements and noise labeling strategies; According to the noise recognition requirement, extracting target feature samples from the MFCC feature samples; According to the noise labeling strategy, the target feature sample is labeled to obtain a labeled sample.
5. The noise identification method according to claim 1, characterized in that: The method of training a pre-built deep learning model using the MFCC feature samples to generate a pre-trained model includes: Build deep learning models based on the Transformer architecture; Using the MFCC feature samples to train and test the deep learning model; When the deep learning model meets the preset preliminary performance requirements, a pre-trained model is generated.
6. The noise identification method according to claim 1, characterized in that: The step of fine-tuning the pre-trained model using the label sample to generate a noise recognition model includes: Fine-tuning the pre-trained model using the labeled samples; When the pre-trained model meets the preset target performance requirements, a noise recognition model is generated.
7. The noise identification method according to claim 1, characterized in that: The step of realizing noise recognition of target noise data based on the noise recognition model includes: Acquire target noise data to be identified, and extract target MFCC features corresponding to the target noise data; Inputting the target MFCC features into the noise recognition model to generate a noise recognition result of the target noise data; The noise recognition result is output or displayed.
8. A noise identification device, characterized in that: include: A collection module, used for collecting a number of original noise samples, and preprocessing the number of original noise samples to obtain a target noise sample; A feature extraction module is used to extract features from the target noise sample to obtain an MFCC feature sample; A label marking module is used to extract target feature samples from the MFCC feature samples and label the target feature samples to obtain label samples; A model training module, used to train a pre-built deep learning model using the MFCC feature samples to generate a pre-trained model; A model fine-tuning module, used to fine-tune the pre-trained model using the label samples to generate a noise recognition model; The noise recognition module is used to realize noise recognition for target noise data based on the noise recognition model.
9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the noise recognition method according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the noise recognition method according to any one of claims 1 to 7 is implemented.