Robot real-time voice interaction method and system based on spiking neural network

By introducing a cyclic leakage integral distribution layer and a dense feedback layer into the pulsed neural network, combining regression labels and gradient replacement functions, the problem of 'dead neurons' and noise influence is solved, and the speech interaction accuracy and resistance of the pulsed neural network are improved. Noise capability.

CN119049460AActive Publication Date: 2024-11-29ZHEJIANG UNIV

Patent Information

Application Number
CN202411011749.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-26
Publication Date
2024-11-29
Estimated Expiration
2044-07-26

AI Technical Summary

Technical Problem

Pulse neural networks are prone to 'dead neuron' problems during training, resulting in degradation of expression ability and performance, and it is difficult to effectively resist the impact of running noise when processing real-time voice data, resulting in low accuracy of voice interaction.

Method used

Using the cyclic pulse neural network model, the model is trained to reduce overfitting and overfitting by introducing robot running noise into the training data, and the cyclic leakage integral distribution layer and dense feedback layer structure is used, combined with regression labels and gradient replacement functions, and the model is trained to reduce overfitting and Improve noise resistance.

Benefits of technology

It effectively prevents the problem of 'dead neurons', improves the network's expression ability and speech interaction accuracy, reduces interaction power consumption, and allows real-time adjustment of the sensitivity of speech interaction instructions.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119049460A_ABST
    Figure CN119049460A_ABST
Patent Text Reader

Abstract

The invention discloses a robot real-time voice interaction method and system based on a pulse neural network, and the method comprises the steps: obtaining a voice data set, carrying out the superposition collection of the operation noise of a robot, generating an expansion sample, extracting the voice signal features of the sample, and carrying out the data enhancement; a cyclic pulse neural network model with cyclic connection is constructed, training is carried out through enhanced data, voice recognition is carried out, real-time voice stream input is obtained through a robot, features are extracted, the features are input to the trained cyclic pulse neural network model for reasoning, and the robot is controlled to execute action interaction according to a pulse decoding result. According to the invention, the recognition power consumption is reduced, the influence of the operation noise of the robot on the real-time voice interaction accuracy is reduced, the problem that the pulse neuron has no pulse is avoided, and the system is allowed to adjust the sensitivity of the voice interaction instruction during operation.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of neuromorphic computing and human-computer interaction, and specifically relates to a robot real-time voice interaction method and system based on a spiking neural network. Background Art

[0002] As a neural network model that simulates the operation of the nervous system, the spiking neural network has attracted much attention in the field of robot control in recent years. It simulates the pulse information processing mechanism of the biological brain. The spiking neural network works in an event-driven manner, that is, it only performs calculations and communications when neurons emit pulses. This feature enables the spiking neural network to significantly reduce power consumption when processing sparse data, and is particularly suitable for embedded systems and mobile robot applications. In addition, the event-driven mechanism of the spiking neural network makes it very suitable for processing real-time data, and it can respond quickly to sensor inputs in a dynamic environment, thereby providing efficient real-time processing capabilities.

[0003] However, for the training of spiking neural networks, as the network depth increases, the "dead neuron" problem becomes more prominent, that is, during the network training or reasoning process, some neurons never emit pulses, resulting in a decrease in the network's expressiveness and performance. In addition, during the training process, suppressing the pulse emission of neurons of incorrect categories in the output layer can easily lead to overfitting of the network; for voice interaction tasks, the spiking neural network model that performs well on the training data set cannot reach the expected level when actually applied to the robot. This gap stems from the fact that the real-time voice data collected on the robot microphone contains a lot of operating noise, such as cooling fan noise, robot foot contact noise when moving, etc. Summary of the invention

[0004] In order to solve the shortcomings of the prior art and achieve the purpose of improving the accuracy of robot voice interaction, the present invention adopts the following technical solutions:

[0005] A robot real-time voice interaction method based on a spiking neural network comprises the following steps:

[0006] Step 1: Obtain a voice data set and collect robot operation noise;

[0007] Step 2: Superimpose the robot operation noise on the samples of the voice dataset to generate extended samples, preprocess all samples, extract voice signal features and perform data enhancement;

[0008] Step 3: Construct a recurrent pulse neural network model with recurrent connections, including an input layer, a hidden layer, and an output layer. The hidden layer and the output layer both adopt a recurrent leakage integral release layer structure. The recurrent leakage integral release layer includes a pulse release layer and a dense feedback layer. The pulse release layer adopts a set of leakage integral release models, and the dense feedback layer adopts a set of dense neuron models. After the input features of a time step are calculated by the pulse release layer, the output pulses will be added element by element to the feature input of the next time step after passing through the dense feedback layer.

[0009] Step 4: Generate a training set target regression label and construct a loss function, and perform error back propagation along the time dimension to train the recurrent spiking neural network model;

[0010] Step 5: Obtain real-time voice stream input from the robot microphone and extract features, input it into the trained recurrent pulse neural network model for inference, and control the robot to perform action interaction based on the pulse decoding results.

[0011] Furthermore, the step 2 comprises the following steps:

[0012] Step 2.1, traverse the data in the voice data set, randomly extract a segment of equal length to the current data from the running noise, randomly select a target noise level within the set noise range, scale the noise segment to the target noise level, and add it to the voice command data element by element to generate an expanded sample with noise;

[0013] Step 2.2, preprocessing the original samples and the expanded samples; first, resample the samples according to the set sampling rate, and normalize the length of each sample, then pre-emphasize through a first-order high-pass filter to enhance the high-frequency components, divide the signal into short-time frames and apply a window function to reduce the boundary effect, perform a fast Fourier transform on each windowed frame, calculate the power spectrum, map the frequency domain information to the Mel frequency scale through a Mel filter bank, perform a logarithmic transformation on the filtered energy value to obtain a logarithmic energy spectrum, and finally, perform a discrete cosine transform on the logarithmic energy spectrum to obtain the Mel frequency cepstrum coefficients;

[0014] Step 2.3, based on the Mel-frequency cepstral coefficients, data enhancement is performed through random time masking and frequency masking, and the data is divided into a training set and a test set.

[0015] Furthermore, in step 2.2, if the current sample exceeds the threshold of the number of sample points, the two ends are truncated to equal length, otherwise the head is zero-filled to achieve tail alignment of the voice command.

[0016] Furthermore, in the step three, a recurrent pulse neural network model with recurrent connections is constructed, wherein the input layer is used to receive speech features, the hidden layer is used to learn high-level feature representations of input data, and the output layer is used to classify speech data. One neuron represents one type of speech data, and for each input sample, the output layer neuron with the largest number of cumulative pulse emissions during the simulation cycle represents the predicted category.

[0017] Furthermore, the neuron membrane potential formula of the leaky integral release model in step 3 is as follows:

[0018] U[t+1]=βU[t]+I in [t+1]+V(S out [t])-U thr

[0019]

[0020] Among them, U[t+1] represents the membrane potential of the neuron at time t+1, β represents the membrane potential decay rate, U[t] represents the neuron membrane potential at time t, and I in [t+1] represents the input current at time t+1, V(·) represents the dense feedback layer, S out [t] represents the pulse emitted at time t, U thr Represents the neuronal membrane potential threshold.

[0021] Furthermore, the step 4 includes the following steps:

[0022] Step 4.1: Set the target pulse firing rates for the correct and incorrect categories, and generate the target regression labels for the training set, where each element corresponds to the target number of pulses fired by the output layer neuron in one simulation cycle;

[0023] Step 4.2: Construct a mean square error loss function based on the output layer pulse count;

[0024] Step 4.3: Use the gradient substitute function instead of the pulse emission step function, and propagate the error back along the time dimension based on the chain rule, that is, the gradient flows back from the final output loss of the recurrent spiking neural network to the trainable parameters;

[0025] Step 4.4: Train the recurrent spiking neural network on the training set and save the trained model structure and weights.

[0026] Furthermore, in step 4.1, the generated tags are as follows:

[0027]

[0028] Among them, y i represents the target regression label, rneg represents the target pulse firing rate of the incorrect category, r pos represents the target pulse firing rate of the correct category, and T represents the number of time steps in the simulation cycle.

[0029] Furthermore, the loss function formula in step 4.2 is as follows:

[0030]

[0031] Among them, n represents the number of categories, that is, the number of neurons in the output layer, Represents the prediction result, that is, the pulse emission result of the output layer neurons within the simulation period.

[0032] Furthermore, the step five comprises the following steps:

[0033] Step 5.1: The robot obtains real-time speech blocks and adds the speech blocks to the queue to be detected. If the data in the sliding window does not reach the target length, it continues to read; if it reaches the target length, it extracts the MFCC features of the speech data in the window and moves the window backward;

[0034] Step 5.2: Input the extracted features into the trained recurrent pulse neural network model, perform feedforward reasoning, record the output layer pulse emission sequence until the set feedforward time step is reached, and input the accumulated pulse emission data into the message queue to be decoded;

[0035] Step 5.3: Read the real-time category sensitivity offset and the pulse sequence at the head of the queue of messages to be decoded, add the category sensitivity offset and the pulse sequence to be decoded element by element, and select the neuron category with the largest number of pulses as the decoding result;

[0036] Step 5.4: Based on the decoding results, control the quadruped robot to perform preset action interactions.

[0037] A robot real-time voice interaction system based on a pulse neural network comprises a data acquisition module, a data preprocessing and expansion module, a network construction module, a network training storage module and a real-time perception interaction module. According to the robot real-time voice interaction method based on a pulse neural network, a voice data set and a robot operation noise are acquired by the data acquisition module, a training data set is obtained after the data preprocessing and expansion module, the network construction module is used to construct a recurrent pulse neural network model, and the network training storage module trains the model through the training data set, the real-time perception interaction module acquires a real-time voice stream through the robot, and the trained recurrent pulse neural network model generates an output pulse sequence, and the robot is controlled to perform action interaction according to the decoding result of the sequence.

[0038] The advantages and beneficial effects of the present invention are:

[0039] The present invention adopts regression labels for training data during the training process of the pulse neural network, that is, the pulse emission rates of the correct category and the incorrect category are set respectively. Compared with the One-hot label commonly used in traditional multi-classification tasks, the regression label encourages the incorrect category neurons in the output layer and the neurons on the corresponding feedforward path to emit a small number of pulses during network training, which effectively prevents the "dead neuron" problem and network overfitting; in addition, the running noise of the quadruped robot is introduced into the training data to ensure the consistency of the model during training and real-time voice interaction, and reduce the impact of the running noise; finally, the present invention reduces the interaction power consumption and allows the sensitivity of the voice interaction instructions to be adjusted in real time during operation. BRIEF DESCRIPTION OF THE DRAWINGS

[0040] Figure 1 This is a flow chart of a robot real-time voice interaction method based on a pulse neural network in an embodiment of the present invention.

[0041] Figure 2 It is a schematic diagram of the structure of the cyclic leakage points issuance layer in an embodiment of the present invention.

[0042] Figure 3 Schematic diagram of the structure of the recurrent pulse neural network model in an embodiment of the present invention.

[0043] Figure 4 It is a flow chart of a robot performing real-time voice interaction based on a trained spiking neural network in an embodiment of the present invention.

[0044] Figure 5 It is a structural schematic diagram of a robot real-time voice interaction system based on a pulse neural network in an embodiment of the present invention. DETAILED DESCRIPTION

[0045] The specific implementation of the present invention is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the present invention, and is not used to limit the present invention.

[0046] like Figure 1As shown, the present invention discloses a real-time voice interaction method for a quadruped robot based on a spiking neural network. Compared with traditional artificial neural networks, spiking neural networks provide higher biological fidelity by simulating the pulse emission mechanism of biological neurons, especially in processing time series data. At the same time, the event-driven computing, sparse pulse activity and asynchronous processing of spiking neural networks give them the characteristics of high efficiency and low power consumption, which are suitable for resource-constrained platforms such as mobile robots. Therefore, the use of robot perception algorithms based on spiking neural networks can not only solve the defects of current traditional neural networks, but also give robots more intelligent and adaptive capabilities, which specifically include the following steps:

[0047] Step 1: Obtain an open source voice dataset and collect robot operation noise, including:

[0048] Part of the data from the Google Speech Commands v2 dataset was obtained, with a total of 8,000 samples and 8 categories, namely UP, DOWN, LEFT, RIGHT, GO, STOP, YES, and NO. The robot running noise was collected from the microphone of the quadruped robot for a total of 10 minutes, including the cooling fan noise and the foot contact noise during movement.

[0049] Step 2: Superimpose robot operation noise on the samples of the open source voice dataset to generate extended samples, preprocess all samples, extract voice signal features, and perform data enhancement, including:

[0050] Step 2.1: Traverse the selected data in the open source speech dataset, randomly extract a segment of equal length to the current data from the running noise, and randomly select a target noise level within the set noise range (0.2-0.4), scale the noise segment to the target noise level, and add it to the speech command data element by element to generate an expanded sample with noise.

[0051] Step 2.2: Preprocess the original samples and the expanded samples. First, set the sampling rate to 16000Hz to resample the samples, and normalize the length of each sample. If the current sample exceeds 16,000 sample points, the two ends are truncated to equal length. Otherwise, the head is zero-filled to achieve the tail alignment of the voice command. The normalized data length contains 16,000 sample points, that is, 1 second in length. Then, a first-order high-pass filter is used for pre-emphasis to enhance the high-frequency components. The signal is divided into a batch of short time frames with a length of 32 milliseconds and a window function is applied to reduce the boundary. Effect, the interval between adjacent frame headers is 16 milliseconds, each frame has 0.032*16000=512 sampling points, and a complete sample contains 63 frames; fast Fourier transform is performed on each windowed frame to calculate the power spectrum; the frequency domain information is mapped to the Mel frequency scale through the Mel filter bank, and the energy value after filtering is logarithmically transformed; finally, discrete cosine transform is performed on the logarithmic energy spectrum to obtain the Mel frequency cepstrum coefficients, and the 1st to 20th coefficients are taken as the features of a single speech sample, with a shape of (63,20).

[0052] Step 2.3: Perform random time masking and frequency masking on the obtained Mel-frequency cepstral coefficient data for data enhancement, and divide it into training set and test set in a ratio of 9:1.

[0053] Step 3: Build a spiking neural network model with recurrent connections, including:

[0054] Step 3.1: If Figure 2 As shown in the figure, the cyclic leaky integral emission layer used in constructing the pulse neural network model with recurrent connection is composed of a pulse emission layer and a dense feedback layer. The pulse emission layer adopts a leaky integral emission model, and the dense feedback layer adopts a dense neuron model. After the input features of a time step are calculated by the pulse emission layer, the output pulses will be added element by element to the input of the next time step after passing through the dense feedback layer.

[0055] like Figure 3As shown in the figure, the network structure of the spiking neural network model with recurrent connections includes 1 input layer, N(2) hidden layers and 1 output layer. Both the hidden layer and the output layer adopt the cyclic leaky integral release layer structure, and the layers are fully connected. The number of neurons in the input layer is 1260, which is consistent with the feature dimension of a single speech sample after preprocessing; the number of neurons in the first hidden layer is 256; the number of neurons in the second hidden layer is 128; the number of neurons in the output layer is 8; the dense feedback layer in the cyclic leaky integral release layer uses dense neurons, and the number is consistent with the connected hidden layer. The input layer is used to receive speech features; the hidden layer is used to learn the high-level feature representation of the input data; the output layer is used to classify speech data, and one neuron represents one type of speech data. The simulation cycle is set to 8 time steps. For each input sample, the output layer neuron with the largest number of cumulative pulse releases in the simulation cycle represents the predicted category.

[0056] Step 3.2: The leaky integral release model is used in both the hidden layer and the output layer of the model, and the neuron membrane potential is calculated according to the following formula:

[0057] U[t+1]=βU[t]+I in [t+1]+V(S out [t])-U thr

[0058]

[0059] Among them, U[t+1] represents the membrane potential of the neuron at time t+1, β represents the membrane potential decay rate, U[t] represents the neuron membrane potential at time t, and I in [t+1] represents the input current at time t+1, V(·) represents the dense feedback layer, S out [t] represents the pulse emitted at time t, U thr represents the neuron membrane potential threshold. In this embodiment, β is 0.9, U thr is 1.0.

[0060] Step 4: Generate the target regression label of the training set and construct the loss function, perform error backpropagation along the time dimension to train the recurrent spiking neural network, and save the model structure and weights, including:

[0061] Step 4.1: Set the target pulse firing rate for the correct and incorrect categories, and generate the target regression labels for the training set, where each element corresponds to the target number of pulses fired by the output layer neuron in one simulation cycle. The generated labels are as follows:

[0062]

[0063] Among them, y irepresents the target regression label, r neg represents the target pulse firing rate of the incorrect category, r pos represents the target pulse emission rate of the correct category, and T represents the number of simulation cycle time steps. neg is 0.2, r pos is 0.8, and T is 8.

[0064] Step 4.2: Construct the mean square error loss function based on the output layer pulse count, and the calculation formula is as follows:

[0065]

[0066] Wherein, n represents the number of categories, that is, the number of neurons in the output layer. In this embodiment, n is 8. Represents the prediction result, that is, the pulse emission result of the output layer neurons within the simulation period.

[0067] Step 4.3: Use a gradient substitute function to replace the pulse emission step function, and propagate the error back along the time dimension based on the chain rule, that is, the gradient flows back from the final output loss of the recurrent spiking neural network to the trainable parameters. In this embodiment, the inverse tangent function is used as the gradient substitute function.

[0068] Step 4.4: Train the recurrent spiking neural network on the training set. In this embodiment, a batch training method is used, the batch size is set to 128, the learning rate is 0.0005, the optimizer is Adam, each batch is input to the network for 8 time steps of feedforward calculation, the error is calculated according to the loss function, and the error is back-propagated along the time dimension to train the recurrent spiking neural network. After 20 rounds of training, the trained model structure and weights are saved.

[0069] Step 5: If Figure 4 As shown in the figure, real-time voice stream input is obtained from the robot microphone and features are extracted, which are then input into the recurrent pulse neural network model for inference. The robot is controlled to perform action interaction according to the pulse decoding results, which specifically includes:

[0070] Step 5.1: Read real-time speech blocks from the microphone and add the speech blocks to the queue to be detected. If the data in the sliding window does not reach the target length, continue to read; if the target length is reached, extract the MFCC features of the speech data in the window and move the window backward. In this embodiment, the speech block length is 16 milliseconds, the sliding window target length is 63 speech blocks, and the backward window step size is 1 speech block.

[0071] Step 5.2: Input the extracted features to the network, perform feedforward reasoning, record the output layer pulse emission sequence, until the set feedforward time step number is reached, and input the accumulated pulse emission data into the queue of messages to be decoded. In this embodiment, the feedforward time step number is set to 8.

[0072] Step 5.3: Read the real-time class sensitivity offset and the pulse sequence at the head of the queue of messages to be decoded, add the class sensitivity offset and the pulse sequence to be decoded element by element, and select the neuron class with the largest number of pulses as the decoding result. In this embodiment, the initial class sensitivity offsets are all zero.

[0073] Step 5.4: According to the decoding result, the quadruped robot is controlled to perform preset action interactions. In this embodiment, the preset actions include standing up, sitting down, walking left, walking right, walking forward, resting, nodding, and shaking the head, which correspond to UP, DOWN, LEFT, RIGHT, GO, STOP, YES, and NO in the training data, respectively.

[0074] like Figure 5 As shown, the present invention also discloses a real-time voice interaction system for a quadruped robot based on a pulse neural network, including a data acquisition module, a data preprocessing and expansion module, a network construction module, a network training storage module and a real-time perception interaction module.

[0075] Data acquisition module, used to obtain open source voice data sets and collect robot operation noise;

[0076] The data preprocessing and expansion module is used to superimpose the robot operation noise on the samples of the open source speech data set in the data acquisition module to generate expanded samples, preprocess all samples, extract MFCC speech signal features, and perform data enhancement to generate training data;

[0077] Specifically, we traverse the samples of the open source voice dataset, randomly extract a segment longer than the sample from the running noise, randomly select a target noise level within the set noise range, scale the noise segment to the target noise level, and add it to the voice command data element by element to generate an expanded sample with noise.

[0078] The original samples and the expanded samples are preprocessed: first, the sampling rate is set to resample the samples, and each sample is truncated at both ends or zero-filled at the head to achieve length normalization; then, a first-order high-pass filter is used for pre-emphasis to enhance the high-frequency components; the signal is divided into short-time frames and a window function is applied to reduce the boundary effect; each windowed frame is fast Fourier transformed to calculate the power spectrum; the frequency domain information is mapped to the Mel frequency scale through a Mel filter bank, and the filtered energy value is logarithmically transformed; finally, the logarithmic energy spectrum is discrete cosine transformed to obtain the Mel frequency cepstral coefficients. The obtained Mel frequency cepstral coefficient data is subjected to random time masking and frequency masking for data enhancement, and divided into training set and test set.

[0079] The network construction module is used to construct a recurrent spiking neural network. It contains an input layer, N hidden layers, and an output layer. The layers are fully connected and the layers are recurrently connected. The input layer is used to receive speech features. The hidden layer is used to learn the high-level feature representation of the input data. The output layer is used to classify speech data. One neuron represents one type of speech data. For each input sample, the output layer neuron with the most cumulative pulse emission times within the simulation time step represents the predicted category. The leaky integral emission model is used in both the hidden layer and the output layer of the model. The neuron membrane potential is calculated according to the following formula:

[0080] U[t+1]=βU[t]+I in [t+1]+V(S out [t])-U thr

[0081]

[0082] Where U[t+1] is the membrane potential of the neuron at time t+1, β is the membrane potential decay rate, U[t] is the neuron membrane potential at time t, and I in [t+1] is the input current at time t+1, V(·) is the dense feedback layer, S out [t] is the pulse emitted at time t, U thr is the neuronal membrane potential threshold.

[0083] The network training storage module generates the target regression labels of the training set by setting the target pulse emission rates of the correct and incorrect categories, constructs the mean square error loss function based on the pulse count of the output layer, uses the gradient substitution function to replace the pulse emission step function, performs error back propagation along the time dimension based on the chain rule to train the recurrent spiking neural network, and saves the model structure and weights;

[0084] Specifically, the target pulse emission rates of the correct and incorrect categories are set, and the target regression labels of the training set are generated, where each element corresponds to the target number of pulses emitted by the output layer neurons in one simulation cycle. The generated labels are as follows:

[0085]

[0086] Among them, y i is the target regression label, r neg is the target pulse firing rate for the incorrect class, r pos is the target pulse firing rate for the correct class and T is the number of simulation cycle time steps.

[0087] Construct the mean square error loss function based on the output layer pulse count, and the calculation formula is as follows:

[0088]

[0089] Among them, n is the number of categories, that is, the number of neurons in the output layer, is the prediction result, that is, the pulse emission result of the output layer neurons within the simulation period.

[0090] A gradient substitute function is used to replace the pulse emission step function, and the error is back-propagated along the time dimension based on the chain rule, that is, the gradient flows backward from the final output loss of the recurrent spiking neural network to the trainable parameters;

[0091] Train the recurrent spiking neural network on the training set and save the trained model structure and weights.

[0092] The real-time perception and interaction module is used to obtain real-time voice stream input from the robot's microphone and extract features, input them into the recurrent pulse neural network model for inference, and control the robot to perform action interaction based on the pulse decoding results.

[0093] Specifically, each time a speech block is read from the microphone, a sliding window is used to maintain the latest several speech blocks. The total duration of the data in the sliding window is 1 second. The speech data in the window is pre-emphasized through a first-order high-pass filter to enhance the high-frequency components, divided into short-time frames and applied with a window function. A fast Fourier transform is performed on each windowed frame, and the power spectrum is calculated. The frequency domain information is mapped to the Mel frequency scale through a Mel filter bank. The filtered energy value is logarithmically transformed, and then the logarithmic energy spectrum is discrete cosine transformed to obtain Mel-frequency cepstral coefficients. The obtained Mel-frequency cepstral coefficients are normalized in the same way as on the training set.

[0094] The preprocessed speech features are input into the saved recurrent pulse neural network for inference, the output layer pulse emission sequence is recorded, and the results are input into the message queue to be decoded.

[0095] Read the real-time category sensitivity offset and the pulse sequence at the head of the queue of messages to be decoded, add the category sensitivity offset and the pulse sequence to be decoded element by element, and select the neuron category with the largest number of pulses as the decoding result.

[0096] According to the decoding results, the quadruped robot is controlled to perform preset action interactions.

[0097] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some or all of the technical features thereof may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the scope of the technical solutions of the embodiments of the present invention.

Claims

1. A robot real-time voice interaction method based on pulse neural network, characterized in that The steps include: Step 1: Obtain a voice data set and collect robot operation noise; Step 2: Superimpose the robot operation noise on the samples of the voice data set to generate extended samples, extract the voice signal features of the samples and perform data enhancement; Step 3: Construct a recurrent pulse neural network model with recurrent connections, including an input layer, a hidden layer, and an output layer. The hidden layer and the output layer both adopt a recurrent leakage integral release layer structure. The recurrent leakage integral release layer includes a pulse release layer and a dense feedback layer. The pulse release layer adopts a set of leakage integral release models, and the dense feedback layer adopts a set of dense neuron models. After the input features of a time step are calculated by the pulse release layer, the output pulses will be added element by element to the feature input of the next time step after passing through the dense feedback layer. Step 4: Generate a training set target regression label and construct a loss function, and perform error back propagation along the time dimension to train the recurrent spiking neural network model; Step 5: The robot obtains real-time voice stream input and extracts features, inputs them into the trained recurrent pulse neural network model for inference, and controls the robot to perform action interaction according to the pulse decoding results.

2. The method for real-time speech interaction of a robot based on a pulse neural network according to claim 1, characterized in that: The step 2 comprises the following steps: Step 2.1, traverse the data in the voice data set, randomly extract a segment of equal length to the current data from the running noise, randomly select a target noise level within the set noise range, scale the noise segment to the target noise level, and add it to the voice command data element by element to generate an expanded sample with noise; Step 2.2, preprocessing the original samples and the expanded samples; first, resample the samples according to the set sampling rate, and normalize the length of each sample, then pre-emphasize through a first-order high-pass filter, divide the signal into short-time frames and apply a window function, perform a fast Fourier transform on each windowed frame, calculate the power spectrum, map the frequency domain information to the Mel frequency scale through a Mel filter bank, perform a logarithmic transformation on the filtered energy value to obtain a logarithmic energy spectrum, and finally, perform a discrete cosine transform on the logarithmic energy spectrum to obtain the Mel frequency cepstrum coefficients; Step 2.3, based on the Mel-frequency cepstral coefficients, data enhancement is performed through random time masking and frequency masking, and the data is divided into a training set and a test set.

3. The method of robot real-time voice interaction based on pulse neural network according to claim 2, characterized in that: In step 2.2, if the current sample exceeds the threshold of the number of sample points, the two ends are truncated to equal length, otherwise the head is zero-filled to achieve tail alignment of the voice command.

4. The method for real-time speech interaction of a robot based on a pulse neural network according to claim 1, characterized in that: In the step three, a recurrent pulse neural network model with recurrent connections is constructed, wherein the input layer is used to receive speech features, the hidden layer is used to learn high-level feature representations of input data, and the output layer is used to classify speech data. One neuron represents one type of speech data, and for each input sample, the output layer neuron with the largest number of cumulative pulse emissions during the simulation cycle represents the predicted category.

5. The method for real-time speech interaction of a robot based on a pulse neural network according to claim 1, characterized in that: The neuron membrane potential formula of the leaky integral release model in step 3 is as follows: U[t+1]=βU[t]+I in [t+1]+V(S out [t])-U thr Among them, U[t+1] represents the membrane potential of the neuron at time t+1, β represents the membrane potential decay rate, U[t] represents the neuron membrane potential at time t, and I in [t+1] represents the input current at time t+1, V(·) represents the dense feedback layer, S out [t] represents the pulse emitted at time t, U thr Represents the neuronal membrane potential threshold.

6. The method for real-time speech interaction of a robot based on a pulse neural network according to claim 1, characterized in that: The step 4 comprises the following steps: Step 4.1: Set the target pulse firing rates for the correct and incorrect categories, and generate the target regression labels for the training set, where each element corresponds to the target number of pulses fired by the output layer neuron in one simulation cycle; Step 4.2: Construct a mean square error loss function based on the output layer pulse count; Step 4.3: Use the gradient substitute function instead of the pulse emission step function, and propagate the error back along the time dimension based on the chain rule, that is, the gradient flows back from the final output loss of the recurrent spiking neural network to the trainable parameters; Step 4.4: Train the recurrent spiking neural network on the training set and save the trained model structure and weights.

7. A robot real-time voice interaction method based on a pulse neural network according to claim 6, characterized in that: In step 4.1, the generated tags are as follows: Among them, y i represents the target regression label, r neg represents the target pulse firing rate of the incorrect category, r pos represents the target pulse firing rate of the correct category, and T represents the number of simulation cycle time steps.

8. The method for real-time speech interaction of a robot based on a pulse neural network according to claim 6, characterized in that: The loss function formula in step 4.2 is as follows: Among them, n represents the number of categories, that is, the number of neurons in the output layer, Represents the prediction result, that is, the pulse emission result of the output layer neurons within the simulation period.

9. The method for real-time speech interaction of a robot based on a pulse neural network according to claim 1, characterized in that: The step five comprises the following steps: Step 5.1: The robot obtains real-time speech blocks and adds the speech blocks to the queue to be detected. If the data in the sliding window does not reach the target length, it continues to read; if it reaches the target length, it extracts the features of the speech data in the window and moves the window backward; Step 5.2: Input the extracted features into the trained recurrent pulse neural network model, perform feedforward reasoning, record the output layer pulse emission sequence until the set feedforward time step is reached, and input the accumulated pulse emission data into the message queue to be decoded; Step 5.3: Read the real-time category sensitivity offset and the pulse sequence at the head of the queue of messages to be decoded, add the category sensitivity offset and the pulse sequence to be decoded element by element, and select the neuron category with the largest number of pulses as the decoding result; Step 5.4: Based on the decoding results, control the robot to perform preset action interactions.

10. A robot real-time voice interaction system based on a pulse neural network, comprising a data acquisition module, a data preprocessing and expansion module, a network construction module, a network training storage module and a real-time perception interaction module, characterized in that: According to a robot real-time voice interaction method based on a pulse neural network according to any one of claims 1 to 9, the voice data set and the robot operation noise are acquired by the data acquisition module, and a training data set is obtained after the data preprocessing and expansion module. The network construction module is used to construct a recurrent pulse neural network model, and the network training storage module trains it through the training data set. The real-time perception interaction module acquires the real-time voice stream through the robot, and the trained recurrent pulse neural network model generates an output pulse sequence. According to the decoding result of the sequence, the robot is controlled to perform action interaction.

Citation Information

Patent Citations

  • Lightweight neural network voice keyword recognition method based on hierarchical quantification

    CN112786021A

  • Hardware-oriented deep pulse neural network speech recognition method and system

    CN116259310A

  • Far field speech acoustic model training method and system

    US20190043482A1

Cited By

  • Robot emotion expression method based on neural network emotion model

    CN119337921A

  • A robot emotion expression method based on neural network emotion model

    CN119337921B

  • Cortical peak potential signal motion decoding method and decoding equipment based on recurrent pulse neural network

    CN119646453A

  • Cortical spike signal motion decoding method and decoding device based on recurrent spiking neural network

    CN119646453B

  • Depth visual identification-based unhooking robot control method and system

    CN120095829A