Non-autoregressive speech recognition method
Through the combination of the non-autoregressive speech recognition model and the speech error correction model, the delay and misjudgment problems of the autoregressive model in long speech processing are solved, and speech recognition effects with high accuracy and low delay are achieved.
Patent Information
- Application Number
- CN202410568181.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-09
- Publication Date
- 2024-09-13
AI Technical Summary
The existing autoregressive speech recognition model takes a long time to decode when processing long speech, and is prone to misjudgment, especially when facing homophones or non-standard pronunciation, the recognition accuracy is low.
Using a non-autoregressive speech recognition method, combined with a non-autoregressive model and a speech error correction model, the non-autoregressive model is decoded through two two-dimensional convolutional layers and an attention module. The speech error correction model is divided into homophone errors, pitch errors and Similar pronunciation errors are corrected using the dynamic masking scheme and the GRU network.
It achieves speech recognition with high recognition accuracy and low latency, simplifies the non-autoregressive model, improves operating efficiency, and improves the recognition accuracy of homophones and non-standard pronunciation through the error correction model.
Smart Images

Figure CN118645092A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of language recognition, and in particular to a non-autoregressive speech recognition method. Background Art
[0002] Non-autoregressive speech recognition is a speech recognition technology based on neural networks. Compared with the autoregressive model, it uses a more complex neural network structure and can better handle noise and changes in speech signals, thereby improving the accuracy of speech recognition.
[0003] However, current speech recognition products are mainly based on autoregressive recognition, but each decoding step requires the result of the previous step and cannot be decoded in parallel, resulting in a rapid increase in computational complexity as speech recognition increases. Therefore, when faced with long speech, the decoding time will be longer. At the same time, existing speech recognition systems often make misjudgments when dealing with homophones or when the speaker's pronunciation is not standard. Summary of the invention
[0004] In view of the problems existing in the above-mentioned existing non-autoregressive speech recognition method with error correction model, the present invention is proposed.
[0005] In order to achieve the above object, the present invention provides the following technical solutions:
[0006] A non-autoregressive speech recognition method includes two modules: a non-autoregressive model and a speech error correction model. The non-autoregressive model is responsible for non-autoregressive decoding of audio. The method includes the following steps:
[0007] Step 1: In the non-autoregressive model, it is divided into two parts: model encoder and position-dependent decoder. The model encoder contains two two-dimensional convolutional layers and an attention module. The attention module is composed of a basic multi-head attention mechanism. The step size of each convolutional layer is set to 2, and the sequence length is compressed to 1 / 4 of the original. It contains a multi-head attention mechanism, a Layer Norm layer, a Position-wise FFN layer, and a residual structure. The attention module is the basic component of the entire model encoder, which is responsible for modeling global dependencies.
[0008] Step 2: In the decoder part, the input is a fixed-length position encoding vector, and the output is the predicted text. The predicted text is regarded as the text corresponding to the predicted fixed position, and the text at each position is predicted. The position encoding is a sine encoding to capture the feature sequence corresponding to each position. The formula is as follows:
[0009]
[0010]
[0011] The position vector is sine-cosine encoded, which will interact with the speech information passed through the encoder in the subsequent non-autoregressive process. Since there is a strong one-to-one correspondence between speech and text, that is, the speech range corresponding to each text should be limited, the speech can be decoded non-autoregressively in a frame-independent manner. The final experiment shows that this method can achieve accurate speech recognition.
[0012] where i=1,2,3,…,L, j=1,2,3…,D m / 2, represents the vector encoding of the even term 2j in the ith position, represents the vector encoding of the odd item 2j+1 in the ith position, D m represents the position vector dimension, and L represents the longest sequence length.
[0013] The position encoding is used as the query vector, and the model encoder output is used as the key and value to calculate the cross attention between the two. Then, a fully connected network is used to obtain the final prediction of each position. The calculation formula of the entire non-autoregressive model is as follows:
[0014] H = Conv2d(X)
[0015] H′=AttentionBlock(H,H,H)
[0016] H out =LayerNorm(H)
[0017]
[0018] The variable dimension in the formula is The three positions of AttentionBlock() represent the three variables Q, K, and V. Instead of inputting three times, it means that the input H is used as Q, K, and V in the calculation. The calculation of AttentionBlok is as follows
[0019]
[0020] MHA(Q,K,V)=Concat(h1,…,h H )W o
[0021]
[0022] Output=W2Activation(W1x+b1)+b2
[0023] The final Output is the output of AttentionBlok, where MHA(Q, K, V is multi-head attention. Each attention block executes the steps of Attention(Q, K, V) separately, and finally splices the multiple heads together for output. Therefore, in the final step, after matrix transposition, V can be achieved. position and H out These two matrices of different dimensions are multiplied to get the final output.
[0024] Among them, Conv2d(·) is a two-dimensional convolutional layer, Attentionblock(·) is an attention block, LayerNorm(·) is a normalization layer, Linear(·) is a fully connected layer, X = {x1,x2,x3,...,x T} is the input feature, x i represents the i-th frame in the input feature, T represents the total number of frames of the input feature, H = {h1,h2,h3,...,h T / 4} is the sequence after the convolution layer, h i represents the i-th item in the output sequence of the convolutional layer, T / 4 means that the length of the sampled sequence is reduced to 1 / 4 of the original length after the convolutional layer. In the convolutional layer, two convolutional layers with a step size of 2 are set, V position ={v1,v2,...,v L} length is L positional encoding, where v i represents the i-th item of the positional encoding, and the entire positional encoding has a total of L items, is the predicted label sequence, where Represents the i-th item of predicted text.
[0025] Furthermore, the speech error correction model is responsible for correcting the decoded text, which includes the following operations:
[0026] S1. By randomly blocking a portion of the input text, common speech errors are divided into three categories according to the characteristics of Chinese pronunciation: homophone errors, tone errors, and similar pronunciation errors;
[0027] S2. Homophone errors refer to words that are pronounced exactly the same but are different characters, tone errors refer to words that are the same but have different tones, and similar pronunciation errors refer to words that are pronounced similarly due to nasal or tongue sounds. Based on the frequency of these three errors in speech recognition, a dynamic shielding scheme is used, where a 15% probability of the text in the entire sentence being selected, a 70% probability of the selected text being replaced with a text with a pronunciation error, a 15% probability of being replaced with a random text, and a 15% probability of remaining unchanged. The text selected to be replaced with a pronunciation error will be randomly selected from the three types of pronunciation errors at a ratio of 30%, 30%, and 40%;
[0028] S3. By dividing Chinese pinyin into three parts: initial consonants, finals, and tones, the model encodes these three parts separately and converts them into corresponding embedding vectors. Then, the GRU network is used for the three parts of each character's pinyin, and the final output is used as the pinyin encoding of the character. After adding it to the text's Embedding and position Embedding, the vector representation of the text is obtained and sent to a regular Transformer Encoder, whose structure is similar to the BERT network. Subsequently, the fully connected network is used to predict the masked text.
[0029] Furthermore, the non-autoregressive model uses an 80-dimensional Mel filter (FBANK) feature as input in model training. The convolution kernel size used in the convolution layer in the model encoder of the non-autoregressive model is 3x3, and the step size in the time dimension is 2. The entire model encoder contains 4 attention modules, each attention module has 8 heads, and the dimension of the middle hidden layer is set to 512.
[0030] Furthermore, for the speech error correction model, the embedding dimensions of the initial consonants, finals, and tones in the text pronunciation are represented as d i ,d v ,d t , the hidden dimension after the GRU network is represented as h p , denote the hidden dimension of Transformer Encoder as h e , by setting d i =d v =d t =256,h p =h e =512, set the number of Transformer Encoder layers to 6.
[0031] Furthermore, the model training includes the following contents:
[0032] The model training starts by inputting CLS, and ends by inputting SEP, which indicates the end of the sentence. After encoding and masking some words in the text and converting them into MASK, MASK represents the replaced part and embeds it into the code. At this time, it is represented by E[MASK], and restored through the BERT network. The output through the BERT network is T[MASK]. At this time, T[MASK] is converted into predicted text. When performing pre-model training, the Adam optimizer is used, and the warm-up learning rate change strategy is set, and the warmup is set to 4 batch sizes.
[0033]
[0034] Where D m In this project, the dimension of the vector in the model is 512, min(·) represents the minimum function, step represents the training step, and 1 is automatically added for each training batch. Warmup is the learning rate turning point parameter, and lr is the learning rate. It will first increase linearly from the minimum value until the warmup step, and then begin to decay exponentially, first increasing and then decreasing, to train the model. To avoid overfitting, the data is trained by setting dropout to 0.1 and performing data enhancement on the training data of the non-autoregressive model.
[0035] In the above technical solution, the technical effects and advantages provided by the present invention are:
[0036] The present invention realizes a speech recognition algorithm that can simultaneously achieve high recognition accuracy and low latency based on non-autoregressive recognition and combined with an error correction model. The main advantages of the algorithm are as follows: the algorithm combines a simplified non-autoregressive speech recognition model to improve operating efficiency; the algorithm combines a pre-trained error correction model for ASR errors, and the algorithm can achieve high-accuracy speech recognition with low latency. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments 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 also be obtained based on these drawings.
[0038] Figure 1 It is a schematic diagram of the overall structure of the present invention;
[0039] Figure 2 Schematic diagram of the structure of the attention block of the present invention;
[0040] Figure 3 It is a schematic diagram of the pronunciation coding network structure of the present invention;
[0041] Figure 4 This is a comparison chart of processing time under different speech durations of the present invention.
[0042] Figure 5 This is a diagram representing the BERT network of the present invention. DETAILED DESCRIPTION
[0043] In order to enable those skilled in the art to better understand the technical solution of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings.
[0044] The embodiments of the present invention provide Figure 1-5 A non-autoregressive speech recognition method is shown, comprising three modules: a non-autoregressive model, a speech error correction model and a model training module. The non-autoregressive model (NA-ASR) is responsible for non-autoregressive decoding of the audio, which comprises the following steps:
[0045] Step 1: In the non-autoregressive model (NA-ASR), it is divided into two parts: the model encoder (NA-ASR Encoder) and the position-dependent decoder (POSDependent Decoder). The model encoder (NA-ASR Encoder) contains two two-dimensional convolutional layers and an attention module (Attention Block). The attention module (Attention Block) is composed of a basic multi-head attention mechanism. The step size of each convolutional layer is set to 2, and the sequence length is compressed to 1 / 4 of the original. It contains a multi-head attention mechanism, a Layer Norm layer, a Position-wise FFN layer, and a residual structure. The attention module (Attention Block) is the basic component of the entire model encoder (NA-ASR Encoder), which is responsible for modeling global dependencies;
[0046] Step 2: In the decoder part, the input is a fixed-length position encoding vector, and the output is the predicted text. The predicted text is regarded as the text corresponding to the predicted fixed position, and the text at each position is predicted. The position encoding is a sine encoding to capture the feature sequence corresponding to each position. The formula is as follows:
[0047]
[0048]
[0049] The position vector is sine-cosine encoded, which will interact with the speech information passed through the encoder in the subsequent non-autoregressive process. Since there is a strong one-to-one correspondence between speech and text, that is, the speech range corresponding to each text should be limited, the speech can be decoded non-autoregressively in a frame-independent manner. The final experiment shows that this method can achieve accurate speech recognition;
[0050] where i=1,2,3,…,L, j=1,2,3…,D m / 2, represents the vector encoding of the even term 2j in the ith position, represents the vector encoding of the odd item 2j+1 in the ith position, D m represents the position vector dimension, and L represents the longest sequence length.
[0051] The position encoding is used as the query vector, and the output of the model encoder (NA-ASR Encoder) is used as the key and value. The cross attention between the two is calculated, and then a fully connected network is used to obtain the final prediction of each position. The calculation formula of the entire non-autoregressive model (NA-ASR) is as follows:
[0052] H = Conv2d(X)
[0053] H′=AttentionBlock(H,H,H)
[0054] H out =LayerNorm(H)
[0055]
[0056] The variable dimension in the formula is The three positions of AttentionBlock() represent the three variables Q, K, and V. Instead of inputting three times, it means that the input H is used as Q, K, and V in the calculation. The calculation of AttentionBlok is as follows
[0057]
[0058] MHA(Q),K,V)=Concat(h1,…,hH)W o
[0059]
[0060] Output=W2Activation(W1x+b1)+b2
[0061] The final Output is the output of AttentionBlok, where MHA(Q, K, V is multi-head attention. Each attention block executes the steps of Attention(Q, K, V) separately, and finally splices the multiple heads together for output. Therefore, in the final step, after matrix transposition, V can be achieved. position and H out These two matrices of different dimensions are multiplied to get the final output;
[0062] Among them, Conv2d(·) is a two-dimensional convolutional layer, Attentionblock(·) is an attention block, LayerNorm(·) is a normalization layer, Linear(·) is a fully connected layer, X = {x1,x2,x3,...,x T} is the input feature, xi represents the i-th frame in the input feature, T represents the total number of frames of the input feature, H = {h1,h2,h3,...,hT / 4} is the sequence after the convolution layer, h i represents the i-th item in the output sequence of the convolutional layer, T / 4 means that the length of the sampled sequence is reduced to 1 / 4 of the original length after the convolutional layer. In the convolutional layer, two convolutional layers with a step size of 2 are set, V position ={v1,v2,...,v L} length is L positional encoding, where v i represents the i-th item of the positional encoding, and the entire positional encoding has a total of L items, is the predicted label sequence, where Represents the i-th item of predicted text.
[0063] Reference Figure 5 The speech error correction model (ASR-Correction) is responsible for correcting the decoded text, which includes the following operations:
[0064] S1. Based on the characteristics of Chinese pronunciation, Chinese speech recognition errors are divided into three categories: homophone errors, tone errors, and similar pronunciation errors, as shown below:
[0065] Voice Error Correct sentence Error statement Homophone Error Voice (yuyin) Yuyin (yuyin) Wrong pitch Voice (yuyin) Yuyin Similar pronunciation errors Four (si) Yes(shi)
[0066] Homophone errors refer to words that are pronounced exactly the same but are different characters; tone errors refer to words that are the same but have different tones; similar pronunciation errors refer to words that have similar pronunciations due to nasal sounds, tongue sounds, front nasal sounds, and back nasal sounds;
[0067] S2. According to the frequency of these three errors in speech recognition, a dynamic masking scheme is used to randomly mask part of the input text. The strategy of replacing text is that the text in the whole sentence has a 15% probability of being selected, and the selected text has a 70% probability of being replaced with text with speech errors, a 15% probability of being replaced with random text, and 15% remains unchanged. The text selected to replace the speech error will be randomly selected from the three speech errors at a ratio of 30%, 30%, and 40%, as shown in the following table;
[0068]
[0069] First, the training process of the speech error correction model (ASR-Correction) is given. A part of the input text is randomly replaced by a plan, and then restored through the BERT network;
[0070] The model training starts by inputting CLS, and ends by inputting SEP, which indicates the end of the sentence. After encoding and masking some words in the text and converting them into MASK, MASK represents the replaced part and embeds it into the code. At this time, it is represented by E[MASK] and restored through the BERT network. The output through the BERT network is T[MASK]. At this time, T[MASK] is converted into predicted text. CLS represents the sentence start symbol, SEP represents the sentence end symbol, and BERT represents pre-model training.
[0071] This will give you a pre-trained BERT model.
[0072] S3. After the pre-model training is obtained, further fine-tuning is required for the voice data. The pronunciation of the text is calculated using the GRU network. The Chinese pinyin can be divided into three parts: initial consonants, finals, and tones. After the model encodes the three parts into corresponding embedding vectors, the GRU network is used for the three parts of each character's pinyin, and the final output is extracted as the pinyin encoding of the character, and then added to the text's embedding and position embedding to obtain the encoding vector corresponding to the text. After obtaining the vector representation of the text, it is sent to the conventional Transformer Encoder. Its structure is similar to the BERT network. In order to reduce the amount of calculation, the fully connected network is used to predict the text after the output of the Transformer Encoder in the error correction module, so as to obtain the corrected speech recognition text.
[0073] Preferably, the non-autoregressive model uses an 80-dimensional Mel filter (FBANK) feature as input on the non-autoregressive model (NA-ASR) in model training, and the convolution kernel size used in the convolution layer in the model encoder (NA-ASR Encoder) of the non-autoregressive model (NA-ASR) is 3x3, and the step size in the time dimension is 2. The entire model encoder (NA-ASR Encoder) includes 4 attention modules (Attention Block), each attention module (Attention Block) has 8 heads, and the dimension of the middle hidden layer is set to 512.
[0074] Preferably, for the speech error correction model (ASR-Correction), the embedding dimensions of the initial consonants, finals, and tones in the text pronunciation are represented as d i ,d v ,d t , the hidden dimension after the GRU network is represented as h p , denote the hidden dimension of TransformerEncoder as h e, by setting d i =d v =d t =256,h p =h e =512, and in order to further shorten the calculation time, the number of Transformer Encoder layers is set to 6.
[0075] Preferably, the model training includes the following contents:
[0076] In terms of training strategy, in order to avoid drastic changes in parameters at the beginning, the Adam optimizer was used for all models, and a warm-up learning rate change strategy was set, as shown below, and the warmup was set to a batch size of 4.
[0077]
[0078] Where D m In this project, the dimension of the vector in the model is 512, min(·) represents the minimum function, step represents the training step, and 1 is automatically added for each training batch. Warmup is the learning rate turning point parameter, and lr is the learning rate. It will first increase linearly from the minimum value until the warmup step, and then begin to decay exponentially, first increasing and then decreasing, to train the model. To avoid overfitting, the data is trained by setting dropout to 0.1 and performing data enhancement on the training data of the non-autoregressive model;
[0079] The learning rate change strategy is mainly to prevent the parameters from changing too drastically in the initial stage of training, which may lead to a large number of operations that cannot be converged. The changes within a certain range are set to be within an acceptable range.
[0080] At the same time, in order to avoid overfitting, the dropout value is set to 0.1, and the data enhancement method is used for the training data of the non-autoregressive model (NA-ASR). The model is tested on the AISHELL-1 dataset and compared with other mainstream speech recognition models. Its structure is shown in the table.
[0081] It can be seen that when the correction module is not added, although the lowest real-time rate is achieved, the overall recognition rate is not high. However, after adding the error correction module, the recognition rate is increased by 2%, which has reached the current advanced level in the industry. By adopting the non-autoregressive model and the error correction module, a very low delay is achieved while also achieving a good recognition accuracy rate to train the data to improve the accuracy rate. The performance comparison table of its speech recognition model is as follows:
[0082] Model CER(test)% RTF MACs Transformer 7.1 0.014 17.57G Transformer+beanseach 6.7 0.037 44.06G LASO-base 6.9 0.0028 15.0G KERMIT 7.5 - - ASR-NA 8.5 0.00094 11.43G ASR-NA-Correction 6.5 0.0021 13.41G
[0083] Reference Figure 4 , by comparing the difference in inference speed between the traditional autoregressive model and this model under different speech durations, it can be seen that the processing speed of the non-autoregressive model hardly changes when facing speech of different durations, but the processing time of the autoregressive model increases with the increase of speech duration, which shows that the non-autoregressive model proposed in this model has more advantages in processing long speech sequences;
[0084] The above only describes certain exemplary embodiments of the present invention by way of illustration. Undoubtedly, a person skilled in the art can modify the described embodiments in various ways without departing from the spirit and scope of the present invention. Therefore, the above drawings and descriptions are illustrative in nature and should not be construed as limiting the scope of protection of the claims of the present invention.
Claims
1. A non-autoregressive speech recognition method, characterized in that: It includes two modules: a non-autoregressive model and a speech error correction model. The non-autoregressive model is responsible for performing non-autoregressive decoding on the audio, which includes the following steps: Step 1: In the non-autoregressive model, it is divided into two parts: model encoder and position-dependent decoder. The model encoder contains two two-dimensional convolutional layers and an attention module. The attention module is composed of a basic multi-head attention mechanism. The step size of each convolutional layer is set to 2, and the sequence length is compressed to 1 / 4 of the original. It contains a multi-head attention mechanism, a LayerNorm layer, a Position-wise FFN layer, and a residual structure. Step 2: In the decoder part, the input is a fixed-length position encoding vector, and the output is the predicted text. The predicted text is regarded as the text corresponding to the predicted fixed position, and the text at each position is predicted. The position encoding is a sine encoding to capture the feature sequence corresponding to each position. The formula is as follows: The position vector is sine-cosine encoded, which will interact with the speech information passed through the encoder in the subsequent non-autoregressive process. Since there is a strong one-to-one correspondence between speech and text, that is, the speech range corresponding to each text should be limited, the speech can be decoded non-autoregressively in a frame-independent manner. The final experiment shows that this method can achieve accurate speech recognition. where i = 1, 2, 3, ..., L, j = 1, 2, 3, ..., D m / 2, represents the vector encoding of the even term 2j in the ith position, represents the vector encoding of the odd item 2j+1 in the ith position, D m represents the position vector dimension, and L represents the longest sequence length. The position encoding is used as the query vector, and the model encoder output is used as the key and value to calculate the cross attention between the two. Then, a fully connected network is used to obtain the final prediction of each position. The calculation formula of the entire non-autoregressive model is as follows: H = Conv2d(X) H′=AttentionBlock(H, H, H1 H out =LayerNorm(H) The variable dimension in the formula is The three positions of AttentionBlock() represent the three variables Q, K, and V. Instead of inputting three times, it means that the input H is used as Q, K, and V in the calculation. The calculation of AttentionBlok is as follows MHA(Q,K,V)=Concat(h1,...,h H )W o Output=W2Activation(W1x+b1)+b2 The final Output is the output of AttentionBlok, where MHA(Q, K, V) is a multi-head attention. Each attention block executes the steps of Attention(Q, K, V) separately, and finally splices the multiple heads together for output. Therefore, in the final step, after matrix transposition, V can be achieved. position and H out These two matrices of different dimensions are multiplied to get the final output. Among them, Conv2d(·) is a two-dimensional convolutional layer, Attentionblock(·) is an attention block, LayerNorm(·) is a normalization layer, Linear(·) is a fully connected layer, X = {x1, x2, x3, ..., x T } is the input feature, x i represents the i-th frame in the input feature, T represents the total number of frames of the input feature, H = {h1, h2, h3, ..., h T / 4 } is the sequence after the convolution layer, h i represents the i-th item in the output sequence of the convolutional layer, T / 4 means that the length of the sampled sequence is reduced to 1 / 4 of the original length after the convolutional layer. In the convolutional layer, two convolutional layers with a step size of 2 are set, V position = {v1, v2, ..., v L } length is L positional encoding, where v i represents the i-th item of the positional encoding, and the entire positional encoding has a total of L items, is the predicted label sequence, where Represents the i-th item of predicted text.
2. The non-autoregressive speech recognition method with an error correction model according to claim 1, characterized in that: The speech error correction model is responsible for correcting the decoded text, which includes the following operations: S1. According to the characteristics of Chinese pronunciation, common pronunciation errors are divided into three categories: homophone errors, tone errors, and similar pronunciation errors. Homophone errors refer to the pronunciations being exactly the same but for different characters, tone errors refer to the characters being the same but with different tones, and similar pronunciation errors refer to the characters being similar in pronunciation due to nasal or tongue sounds. S2. Based on the frequency of these three errors in speech recognition, a dynamic masking scheme is used to randomly mask part of the input text, so that the text in the entire sentence has a 15% probability of being selected, and the selected text has a 70% probability of being replaced with text with speech errors, a 15% probability of being replaced with random text, and 15% remains unchanged. The text selected to be replaced with speech errors will be randomly selected from the three speech errors at a ratio of 30%, 30%, and 40%; S3. By dividing Chinese pinyin into three parts: initial consonants, finals, and tones, the model encodes these three parts separately and converts them into corresponding embedding vectors. Then, the GRU network is used for the three parts of each character's pinyin, and the final output is used as the pinyin encoding of the character. After adding it to the text's Embedding and position Embedding, the vector representation of the text is obtained and sent to a regular Transformer Encoder, whose structure is similar to the BERT network. Subsequently, the fully connected network is used to predict the masked text.
3. The non-autoregressive speech recognition method with an error correction model according to claim 1, characterized in that: The non-autoregressive model uses 80-dimensional Mel filter (FBANK) features as input in model training. The convolution kernel size used in the convolution layer of the model encoder of the non-autoregressive model is 3x3, and the step size in the time dimension is 2. The entire model encoder contains 4 attention modules, each attention module has 8 heads, and the dimension of the middle hidden layer is set to 512.
4. The non-autoregressive speech recognition method with an error correction model according to claim 3, characterized in that: The speech error correction model represents the embedding dimensions of initials, finals, and tones in text pronunciation as d i , d v , d t , the hidden dimension after the GRU network is represented as h p , denote the hidden dimension of Transformer Encoder as h e , by setting d i =d v =d t =256,h p =h e =512, set the number of Transformer Encoder layers to 6.
5. The non-autoregressive speech recognition method with an error correction model according to claim 3, characterized in that: The model training includes the following contents: The model training starts by inputting CLS, and ends by inputting SEP, which indicates the end of the sentence. After encoding and masking some words in the text and converting them into MASK, MASK represents the replaced part and embeds it into the code. At this time, it is represented by E[MASK], and restored through the BERT network. The output through the BERT network is T[MASK]. At this time, T[MASK] is converted into predicted text. When performing pre-model training, the Adam optimizer is used, and the warm-up learning rate change strategy is set, and the warmup is set to 4 batch sizes. Where D m In this project, the dimension of the vector in the model is 512, min(·) represents the minimum function, step represents the training step, and 1 is automatically added for each training batch. Warmup is the learning rate turning point parameter, and lr is the learning rate. It will first increase linearly from the minimum value until the warmup step, and then begin to decay exponentially, first increasing and then decreasing, to train the model. To avoid overfitting, the data is trained by setting dropout to 0.1 and performing data enhancement on the training data of the non-autoregressive model.
Citation Information
Cited By
Voice interaction method, vehicle and computer readable storage medium
CN119181363A
Non-autoregressive speech recognition method based on feature difference integration
CN119811373A
Non-autoregressive speech recognition method based on feature difference ensemble
CN119811373B
