Malicious voice detection method based on influence function

Through the malicious speech detection method based on the influence function, the speech data features are extracted, the influence function is calculated, and the malicious samples are identified and processed. This solves the problem of malicious speech sample recognition in the existing technology and improves the generalization ability of the model and the security of the application. Automated and intelligent malicious voice detection is realized.

CN118629422APending Publication Date: 2024-09-10LIAONING UNIVERSITY
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410698022.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-31
Publication Date
2024-09-10

AI Technical Summary

Technical Problem

Existing technologies are difficult to effectively identify and process speech samples containing malicious content, leading to deviations in model training, affecting the model's generalization ability and application security. Traditional manual review is time-consuming and susceptible to subjective bias, and a single detection rule cannot be effective. Distinguish malicious content.

Method used

Adopt a malicious speech detection method based on the influence function. By extracting the characteristics of the speech data set, such as the fundamental frequency, Mel frequency cepstral coefficient, linear predictive coding coefficient and short-term energy, the original influence function is calculated and optimized, using the Jacobian matrix and feature weights to identify samples that have a great impact on the model and determine whether they are malicious samples.

Benefits of technology

It improves the generalization ability and accuracy of the model, identifies abnormal samples that may cause model performance to decline, enhances the transparency and interpretability of data processing, and provides an automated and intelligent malicious speech detection method suitable for complex Voice data scenario.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure BDA0004870295680000021
    Figure BDA0004870295680000021
  • Figure FDA0004870295670000016
    Figure FDA0004870295670000016
  • Figure BDA0004870295680000042
    Figure BDA0004870295680000042
Patent Text Reader

Abstract

According to the malicious voice detection method based on the influence function, the interpretability of a deep learning model in the field of malicious voice detection is enhanced by analyzing the influence degree of data points on model prediction. And malicious voice possibly existing in the original sound signal is identified and detected by using the influence function, so that the detection precision and efficiency are greatly improved. Compared with a traditional method, the method achieves a better detection effect by using less calculation amount through the influence function. The technology has excellent performance in the aspects of keeping the detection efficiency and advantages, and provides new application possibility for the fields of deep learning and explanatory machine learning. The technology not only improves the accuracy of malicious voice detection, but also can accurately identify and explain why the model determines that the specific voice is malicious, thereby improving the transparency and credibility of the model while ensuring the detection rate.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of deep learning and machine learning explainability, and is a malicious speech detection method based on influence function. Background Art

[0002] With the rapid development of deep learning technology, the field of speech recognition and processing can capture and analyze natural language from unprecedented perspectives. Deep learning models, especially convolutional neural networks (CNNs), recurrent neural networks (RNNs) and their variants, long short-term memory networks (LSTMs), have been shown to excel in extracting key information from speech signals. These advances have not only greatly promoted the practicality of intelligent voice assistants, but also provided technical support for real-time applications such as automatic generation of subtitles for video content. However, while advancing the technology, a series of new challenges have also been exposed, especially the problem of identifying and processing speech samples containing malicious content in training data.

[0003] The content of these malicious voice samples may include various offensive, fraudulent information, or other remarks that can be considered inappropriate. If these data are not properly managed and preprocessed, it will cause deviations in model training, which will in turn affect the generalization ability of the entire model and the security of the application. For example, malicious voice can manipulate the voice recognition system to execute improper commands, or introduce errors in the automatic content review system, causing serious consequences.

[0004] Faced with the demand for automated malicious speech detection in reality, over-reliance on traditional manual review mechanisms is no longer sufficient. Manual review is not only time-consuming and labor-intensive, but also susceptible to subjective bias, and simple filtering rules are even more inadequate when dealing with complex, high-dimensional speech data. Considering the diversity of modern speech data and the complex time series characteristics it exhibits, single and static detection rules cannot effectively distinguish malicious content.

[0005] Faced with this situation, more efficient and intelligent automatic detection methods are urgently needed. By utilizing the characteristics of deep learning itself and combining it with big data analysis, we can develop algorithms that automatically distinguish malicious speech. For example, with the help of natural language processing and sentiment analysis technology, we can train specialized deep learning models to identify intonation, speech speed, pauses, and other voice characteristics to detect potential malicious intent. Through these technologies, a multi-level comprehensive judgment system can be built that can capture obvious offensive language and carefully analyze the implicit emotions and subtle changes in language.

[0006] In addition, adversarial training can enhance the model's robustness to malicious samples by introducing specially designed noise and distortion samples to teach the model to identify and resist potential attacks or deception attempts. In addition, ensemble learning methods improve detection accuracy and system robustness by combining multiple models, allowing the system to remain flexible and effective in the face of evolving malicious attacks.

[0007] In short, in order to ensure the accuracy and security of voice processing systems, modern technology must be committed to developing new methods to deal with the challenges posed by malicious voice samples. Only in this way can deep learning technology continue to advance the boundaries of voice recognition and processing, thereby providing users with a safer, smarter and more convenient service experience. Summary of the invention

[0008] The present invention aims at the technical problems existing in the prior art and provides a malicious speech detection method based on an influence function.

[0009] The technical solution adopted by the present invention is as follows: a malicious speech detection method based on an influence function, the steps of which are:

[0010] 1) Extraction of speech data set features: extraction of fundamental frequency, Mel-frequency cepstral coefficients, linear prediction coding coefficients, and short-time energy;

[0011] 1.1) Fundamental frequency F0: There is no fixed formula for fundamental frequency extraction because it depends on a specific algorithm or method. The simple autocorrelation formula is as follows:

[0012]

[0013] Where R(τ) represents the autocorrelation function, x(n) is the time series signal, τ is the lag, and N is the signal length.

[0014] 1.2) Mel-frequency cepstral coefficient (MFCC): First, the signal is pre-emphasized and framed, and then a Hanning window is used for each frame, that is, a fast Fourier transform (FFT) is performed on each windowed frame signal to calculate the power spectrum, and the power spectrum is processed using a Mel filter bank, and a discrete cosine transform (DCT) is performed on each frame to obtain the MFCC.

[0015]

[0016] Where w(n) is the Hanning window of the nth frame, and N is the window size.

[0017] 1.3) Linear Prediction Coding Coefficient LPC: The LPC model assumes that the value of the current sample can be taken as a linear combination of past sample values, plus an error term. The formula can be expressed as:

[0018]

[0019] in, is the predicted value of the current sample, a i is the prediction coefficient, x(ni) is the past sample value, e(n) is the error term, p is the model order,

[0020] 1.4) Short-time energy: The calculation formula of short-time energy is:

[0021]

[0022] Wherein, E(m) represents the energy of the m-th frame, x(m+n) represents the n-th sample value of the m-th frame, and N is the frame length.

[0023] 2) Original influence function: Calculate the influence of input features on the model. For each input feature x test ,y test , calculate the influence gradient in the model The formula is as follows:

[0024]

[0025] Among them, x and y represent the input and output of the training data point respectively, x test and test They represent the input and output of the test data point, θ represents the parameters of the model, and L(x, y, θ) represents the loss function of the model given the parameters θ. and Denote the gradients of input x and parameter θ respectively. θ is the second-order derivative matrix of the loss function under parameter θ.

[0026] The calculation method of the Hessian matrix H(θ) is shown in the formula:

[0027]

[0028] Among them, θ∈R n is the parameter vector, r i (θ) is the i-th residual term;

[0029] 3) Optimize the influence function: Approximate the Jacobian matrix transpose, the product of the weight matrix and the Jacobian matrix to replace the Hessian matrix, use the previously obtained feature importance matrix as the weight matrix, assign importance weights to the feature residuals, and the Jacobian weight matrix G(θ) is calculated as shown in the formula:

[0030] G(θ)=J(θ) T WJ(θ)

[0031] Among them, G(θ) represents the first-order derivative matrix of the loss function with respect to the parameter θ, and J(θ) represents the nonlinear function r i (θ) is the partial derivative matrix of the parameter vector θ, W is a diagonal matrix, and the elements on the diagonal represent the feature weights corresponding to each residual;

[0032] The Jacobian matrix J(θ) is calculated as shown in the formula

[0033]

[0034] Among them, θ∈R n Parameter vector, r i (θ) the i-th residual term and the i-th row is

[0035] The optimized influence function is shown in the formula:

[0036]

[0037] 4) Speech detection: The Jacobian matrix is ​​calculated using the method in 3). The feature importance weight matrix is ​​calculated using the Jacobian matrix and feature weights. The feature loss is calculated using the loss function. Finally, the impact of a single sample on the model is obtained. If the impact exceeds the set threshold, the sample is considered to be a malicious sample. If the impact is lower than the set threshold, the sample is considered not to be a malicious sample.

[0038] The beneficial effects created by the present invention are as follows: the present invention not only provides a new approach to solving the challenges of deep learning in processing clean and mixed data, but also provides a feasible technical means for other related tasks in the field of data science, and is expected to become an important tool for future data analysis and model optimization work. DETAILED DESCRIPTION

[0039] A malicious speech detection method based on influence function includes the following aspects:

[0040] 1. Extraction of speech dataset features

[0041] For speech feature extraction, different feature extraction methods involve a variety of formulas and technical means. The following are the extraction formulas for different features, covering some of the feature extraction techniques commonly used in speech processing:

[0042] (1) Extraction of fundamental frequency F0: There is no fixed formula for fundamental frequency extraction because it depends on a specific algorithm or method. The simple autocorrelation formula is as follows:

[0043]

[0044] Where R(τ) represents the autocorrelation function, x(n) is the time series signal, τ is the lag, and N is the signal length.

[0045] (2) Mel-frequency cepstral coefficient (MFCC): First, the signal is pre-emphasized and framed. Then, a Hanning window is used for each frame. That is, a fast Fourier transform (FFT) is performed on each windowed frame signal to calculate the power spectrum. The power spectrum is processed using a Mel filter bank, and a discrete cosine transform (DCT) is performed on each frame to obtain the MFCC.

[0046]

[0047] Where w(n) is the Hanning window of the nth frame, and N is the window size.

[0048] (3) Linear Prediction Coding Coefficient LPC: The LPC model assumes that the value of the current sample can be taken as a linear combination of past sample values ​​plus an error term. The formula can be expressed as:

[0049]

[0050] in, is the predicted value of the current sample, a i is the prediction coefficient, x(ni) is the past sample value, e(n) is the error term, and p is the model order.

[0051] (4) Short-time energy: The calculation formula for short-time energy is:

[0052]

[0053] Wherein, E(m) represents the energy of the m-th frame, x(m+n) represents the n-th sample value of the m-th frame, and N is the frame length.

[0054] 2. Original Influence Function

[0055] (1) We first proposed a primitive influence function. This influence function can calculate the influence of input features on the model. For each input feature x test ,y test , calculate its influence gradient in the model The formula is as follows:

[0056]

[0057] Among them, x and y represent the input and output of the training data point respectively, x test and test They represent the input and output of the test data point, θ represents the parameters of the model, and L(x, y, θ) represents the loss function of the model given the parameters θ. and Denote the gradients of input x and parameter θ respectively. θ is the second-order derivative matrix of the loss function under parameter θ.

[0058] (2) The calculation method of the Hessian matrix H(θ) is shown in the formula.

[0059]

[0060] Among them, θ∈R n is the parameter vector, r i (θ) is the i-th residual term.

[0061] 3. Optimizing influence functions

[0062] (1) In order to avoid the expensive calculation of the second-order derivative terms in the Hessian matrix, the Hessian matrix is ​​replaced by the product of the approximate Jacobian matrix transpose, the weight matrix and the Jacobian matrix. At the same time, the feature importance matrix obtained previously is used as the weight matrix to assign importance weights to the feature residuals, making the optimization process more robust and efficient. The calculation method of the Jacobian weight matrix G(θ) is shown in the formula.

[0063] G(θ)=J(θ) T WJ(θ)

[0064] Among them, G(θ) represents the first-order derivative matrix of the loss function with respect to the parameter θ, and J(θ) represents the nonlinear function r i (θ) is the partial derivative matrix of the parameter vector θ. W is a diagonal matrix, and the elements on the diagonal represent the feature weights corresponding to each residual.

[0065] (2) The Jacobian matrix J(θ) is calculated as shown in formula 4.13

[0066]

[0067] Among them, θ∈R n Parameter vector, r i (θ) the i-th residual term and the i-th row is

[0068] (3) The optimized influence function is shown in the formula

[0069]

[0070] 4. Voice Detection

[0071] To optimize the influence function, you need to first calculate the Jacobian matrix, then use the Jacobian matrix and feature weights to calculate the feature importance weight matrix, and use the loss function to calculate the loss of the feature. Finally, you can get the impact of a single sample on the model. If the impact exceeds the set threshold, the sample is considered to be a malicious sample.

[0072] The present invention provides a powerful solution to the shortcomings of current deep learning technology by introducing influence functions through the above method. It is a concept from the field of reinforcement learning, which can quantitatively estimate the influence of a single training sample on the model prediction output. By calculating the impact of each data point on the model loss after deletion, the influence function can identify key samples that have a significant impact on the final performance of the model. This method is particularly suitable for selecting or excluding abnormal samples that may cause the performance of the model to deteriorate, such as data points containing noise, mislabeling or malicious content. In the field of malicious speech detection, influence functions can identify samples that cause the model to deviate from the correct learning trajectory. For example, if a malicious speech sample contains features that are highly similar to normal samples, but is mistakenly labeled as malicious, this will force the model to learn the wrong decision boundary. By locating these samples, the influence function allows decision makers to decide whether to correct them or remove them from the training set, thereby improving the generalization ability and accuracy of the model.

[0073] The application of this technology can go beyond malicious speech detection and extend to any task that requires anomaly detection and data cleaning, including financial fraud detection, abnormal pixel identification in image recognition, and any scenario that may be disturbed by abnormal data. The influence function provides a mechanism to help researchers and developers clearly understand and identify potential problem points in the data set, so that they can more accurately adjust their models to adapt to the complexity and variability in practical applications. In addition, the application of influence functions can also enhance the transparency and explainability of the data processing process. When developers can clearly show the specific reasons why a data point affects the model, they can better explain and prove the decision-making process of the model to stakeholders, such as auditors, managers, and end users, further enhancing the trust and acceptance of the model.

Claims

1. A malicious speech detection method based on influence function, It is characterized in that The steps are: 1) Extraction of speech data set features: extraction of fundamental frequency, Mel-frequency cepstral coefficients, linear prediction coding coefficients, and short-time energy; 2) Original influence function: Calculate the influence of input features on the model. For each input feature x test ,y test , calculate the influence gradient in the model The formula is as follows: Among them, x and y represent the input and output of the training data point respectively, x test and test They represent the input and output of the test data point, θ represents the parameters of the model, and L(x, y, θ) represents the loss function of the model given the parameters θ. and Respectively represent the gradients of input x and parameter θ; H θ is the second-order derivative matrix of the loss function under parameter θ; The calculation method of the Hessian matrix H(θ) is shown in the formula: Among them, θ∈R n is the parameter vector, r i (θ) is the i-th residual term; 3) Optimize the influence function: Approximate the Jacobian matrix transpose, the product of the weight matrix and the Jacobian matrix to replace the Hessian matrix, use the previously obtained feature importance matrix as the weight matrix, assign importance weights to the feature residuals, and the Jacobian weight matrix G(θ) is calculated as shown in the formula: G(θ)=J(θ) T WJ(θ) Among them, G(θ) represents the first-order derivative matrix of the loss function with respect to the parameter θ, and J(θ) represents the nonlinear function r i (θ) is the partial derivative matrix of the parameter vector θ, W is a diagonal matrix, and the elements on the diagonal represent the feature weights corresponding to each residual; The Jacobian matrix J(θ) is calculated as shown in the formula Among them, θ∈R n Parameter vector, r i (θ) the i-th residual term and the i-th row is The optimized influence function is shown in the formula: 4) Speech detection: The Jacobian matrix is ​​calculated using the method in 3). The feature importance weight matrix is ​​calculated using the Jacobian matrix and feature weights. The feature loss is calculated using the loss function. Finally, the impact of a single sample on the model is obtained. If the impact exceeds the set threshold, the sample is considered to be a malicious sample. If the impact is lower than the set threshold, the sample is considered not to be a malicious sample.

2. According to claim 1, a malicious speech detection method based on influence function, It is characterized in that In the above 1), the specific method is: 1.1) Fundamental frequency F0: There is no fixed formula for fundamental frequency extraction because it depends on a specific algorithm or method. The simple autocorrelation formula is as follows: Where R(τ) represents the autocorrelation function, x(n) is the time series signal, τ is the lag, and N is the signal length; 1.2) Mel-frequency cepstrum coefficient (MFCC): First, the signal is pre-emphasized and framed, and then a Hanning window is used for each frame, that is, a fast Fourier transform (FFT) is performed on each frame of the windowed signal to calculate the power spectrum, and the power spectrum is processed using a Mel filter bank, and a discrete cosine transform (DCT) is performed on each frame to obtain the MFCC. Where w(n) is the Hanning window of the nth frame, and N is the window size; 1.3) Linear Prediction Coding Coefficient LPC: The LPC model assumes that the value of the current sample is a linear combination of past sample values, plus an error term; the formula can be expressed as: in, is the predicted value of the current sample, a i is the prediction coefficient, x(ni) is the past sample value, e(n) is the error term, p is the model order, 1.4) Short-time energy: The calculation formula of short-time energy is: in, E(m) represents the energy of the m-th frame, x(m+n) represents the n-th sample value of the m-th frame, and N is the frame length.