Deep pulse neural network construction method based on STDP rule
By introducing adaptive threshold LIF neurons and batch update STDP rules into the deep spiking neural network, combined with dynamic side inhibition and synaptic filters, the problem of limited functions of traditional spiking neural networks is solved, and the adaptive and batch-updated STDP rules of the model are significantly improved. Anti-noise capability, achieving more efficient image recognition performance.
Patent Information
- Application Number
- CN202410769014.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-14
- Publication Date
- 2024-09-03
AI Technical Summary
Among the existing impulse neural network learning algorithms, the neuron models are mostly traditional IF, LIF, SRM, etc., with simple calculation forms and limited functions, which cannot meet the needs of algorithm development, especially in terms of adaptive ability and anti-noise ability. lacking.
Adopt a deep spiking neural network construction method based on STDP rules, use adaptive threshold LIF neurons, combine batch update STDP and dynamic strategies, and improve the sparsity, anti-noise ability and automaticity of the model through dynamic side suppression and dynamic synaptic filters. Adaptability.
Significantly improves the model's classification performance, improves sparsity and noise immunity, avoids convergence instability, and enhances learning ability and emission frequency stability.
Smart Images

Figure CN118586458A
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of image recognition, and in particular relates to a method for constructing a deep pulse neural network based on STDP rules. Background Art
[0002] Spiking Neural Network (SNN) is a new generation of artificial neural network model inspired by biology. It is a subset of deep learning and has a strong biological basis. Its design idea is: neurons in dynamic neural networks are not activated in every iterative propagation (as in typical multi-layer perceptron networks), but are activated only when their membrane potential reaches a certain value; when a neuron is activated, it will generate a signal to other neurons to increase or decrease their membrane potential. In common spiking neural network learning algorithms, neuron models are mostly traditional models such as IF, LIF, SRM, etc., with simple calculation forms and limited functions. The adaptive ability and noise resistance ability need to be improved, and cannot meet the needs of algorithm development. Summary of the invention
[0003] In order to solve the above problems, the present invention provides a method for constructing a deep pulse neural network based on the STDP rule. It improves the model's adaptability and noise resistance by means of adaptive threshold LIF neurons, greatly improving the model's classification performance.
[0004] The technical solution adopted by the present invention is:
[0005] In a first aspect, the present application discloses a method for constructing a deep pulse neural network based on the STDP rule, comprising the following steps:
[0006] Modeling: Building a spiking neuron model;
[0007] Encoding: constructing neural pulse sequences to encode the information transmitted by neurons;
[0008] And, training: model training based on STDP rules;
[0009] Wherein, the neuron adopts an adaptive threshold LIF neuron, and the dynamic change of the threshold satisfies the following formula;
[0010]
[0011] in, represents the threshold value that changes with time, V th0 is the initial threshold, g(t) represents the tolerance of the neuron to the input stimulus when it fires, and g(t) is determined by the following two equations:
[0012]
[0013] g(t)=g(t-1)+g 0
[0014] Among them, τ g is the time constant, g 0 is a constant.
[0015] As an optional technical solution, the encoding adopts a rate encoding method.
[0016] As an optional technical solution, in the STDP rule, the modification of the weight is determined by the time interval between the presynaptic and postsynaptic pulses. The larger the time interval, the smaller the correlation between the two pulses, and the smaller the impact on the synaptic weight:
[0017]
[0018] When Δt=t a -t b >0, then
[0019]
[0020] Among them, Δw b is the change in synaptic weight between neurons a and b, W is the STDP function, Δt is the time difference, χ offset Used to determine whether synaptic connections are enhanced or depressed, A + represents the enhancement coefficient, τ + Represents the time constant.
[0021] As an optional technical solution, in the case of a single sample, when the postsynaptic neuron emits a pulse, the weight changes as shown in the following formula:
[0022]
[0023] in, is the synaptic trace; when a pulse is received from the presynaptic neuron, χ pre is 1, the change of synaptic trace is as follows:
[0024]
[0025] Among them, λ + for
[0026] As an optional technical solution, in the case of batch samples, when the postsynaptic neuron emits a pulse, the weight changes as shown in the following formula:
[0027]
[0028] Among them, B S That is, BatchSize represents the number of samples in a single batch, and T represents the time step of a single batch; the change of synaptic trace is shown as follows:
[0029]
[0030] As an optional technical solution, for the convolutional layer, the normalization operation is as follows:
[0031]
[0032] in, is the normalization scale factor of the convolutional layer, mean() is the mean function, and std() is the standard deviation function.
[0033] For the fully connected layer, the normalization operation is as follows:
[0034]
[0035] in, is the normalization scale factor of the fully connected layer, represents the synaptic weight between neurons a and b.
[0036] As an optional technical solution, the membrane potential of the neuron is controlled by a dynamic lateral inhibition mechanism, with the maximum input current I max As a reference value, let the threshold current be If the current I (t) When the threshold is exceeded, the following equation is used:
[0037]
[0038] in, Represents the inhibition value of the synaptic connection between neurons a and b, α inh is the coefficient for adjusting the degree of suppression, l represents the sample batch number, m, p and q represent the number of output channels and output size, The inhibition can only act on neurons that are not currently emitting pulses; the input current I (t) The synaptic weight and pulse Calculated as follows:
[0039]
[0040] As an optional technical solution, a dynamic synaptic filter is established according to the input current, as shown in the following formula:
[0041]
[0042] Among them, δ represents the filter function, μ and β are the control coefficients of the filter.
[0043] In a second aspect, the present application discloses an electronic device comprising: one or more processors; one or more memories; the one or more memories storing one or more computer programs, the one or more computer programs comprising instructions, which, when executed by the one or more processors, enable the electronic device to perform the method disclosed above.
[0044] In a third aspect, the present application also discloses a computer-readable medium, comprising a computer program, which enables the computer to execute the method disclosed above when the computer program is executed on the computer.
[0045] The beneficial effects of the present invention are as follows: for the STDP unsupervised learning algorithm, the present application proposes an unsupervised learning method based on adaptive threshold LIF neurons, batch update STDP and dynamic strategy. The adaptive threshold is used to improve the sparsity, noise resistance and adaptability of the model. The use of batch update synaptic weights helps to speed up training and avoid convergence instability. For the synaptic connection between neurons, dynamic lateral inhibition is used to ensure the diversity of features within the layer and improve learning ability. In addition, a dynamic synaptic filter is used to adjust the input current and enhance the stability of the firing frequency. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] Figure 1 is a flow chart of a method for constructing a deep spiking neural network based on STDP rules in an exemplary embodiment;
[0047] Figure 2 is a schematic diagram of an adaptive threshold LIF neuron in an exemplary embodiment;
[0048] Figure 3 It is a schematic diagram of rate coding in an exemplary embodiment. DETAILED DESCRIPTION
[0049] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all of the embodiments. The components of the embodiments of the present invention generally described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the claimed invention, but merely represents selected embodiments of the present invention. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.
[0050] Before introducing this embodiment, the background of this application is further explained.
[0051] Different from the global mechanism in direct training, the update of weights in the learning algorithm based on local learning rules only depends on local spatiotemporal information during training, that is, the update of each neuron is only related to the activity information of itself or its neighboring neurons.
[0052] The Hebbian rule is a typical example, which follows the principle that "the strength of the connection between neurons depends on their common activity". Local learning rules are very suitable for SNNs because the dynamics of SNNs are local and sequential in nature, and this type of learning rule is more consistent with the working method of biological neural systems. However, when dealing with complex tasks, this method performs worse than direct or indirect training methods.
[0053] The Hebbian rule is a fundamental concept in neuroscience and has an important impact on unsupervised learning algorithms in modern machine learning. Hebbian learning is a self-organizing process in which the network can autonomously discover correlations in input data and make adaptive adjustments to them. However, the original Hebbian learning has some limitations. It may cause problems such as the continuous growth of synaptic weights, and some mechanisms need to be added to stabilize the learning process.
[0054] The STDP rule is a form of Hebbian plasticity and can be seen as an extension of the Hebbian rule. The STDP rule is common in unsupervised learning algorithms for SNNs and has good training effects. Peter et al. proposed an SNN based on a biologically feasible mechanism for digital recognition. The network uses the STDP rule for unsupervised learning, and the performance of the trained SNN is better than previous unsupervised methods. On this basis, Saunders et al. applied STDP to convolutional spike neural networks to learn grid data in an unsupervised manner. Local neurons can share parameters or learn features independently. Ferré et al. proposed a STDP unsupervised feature learning based on Winner-Takes-All (WTA). Through WTA and simple feature normalization to stabilize training, effective features are extracted from image datasets, and it is proved that these features are relevant for classification.
[0055] Inspired by the idea of reinforcement learning, technologies such as reward signals were introduced into the STDP rule. Eugene et al. solved the "distal reward problem" in Pavlov and instrumental conditioning by simulating cortical SNN and adding dopamine signals to the STDP rule. Fre′maux et al. focused on the application of reward-modulated STDP (R-STDP) in SNN through theoretical derivation and simulation experiments. The study found that R-STDP is very sensitive to success offsets, and even a small offset will prevent it from learning the target pulse sequence. Mozafari et al. used a deep convolutional spike neural network (DCSNN) and a delay coding scheme to combine STDP and R-STDP for training without the need for an external classifier, and the trained model performed well.
[0056] Of course, there are also applications of STDP rules to supervised learning. Strain et al. proposed a supervised training method based on STDP, which promotes the association between spatial patterns and categories in input data through dynamic thresholds. The trained model structure has only two layers and is verified on nonlinear separable classification problems. Beyeler et al. proposed a supervised learning method based on STDP-like rules for training deep SNN models, combining low-level memory encoding mechanisms and high-level decision-making processes to perform real-time visual classification tasks. Tang et al. proposed a fast feedforward calculation algorithm based on time encoding. Through comparative experiments, it was found that the tempotron method is superior to the ReSuMe method in learning speed, and the tempotron method is superior to the support vector machine (SVM) in traditional machine learning in performance. Liu et al. proposed an efficient supervised learning algorithm based on STDP. By combining the global optimization of back propagation and the local characteristics of STDP, the training performance gap between SNN and traditional ANN was narrowed, and good accuracy was achieved on commonly used image data sets. Tavanaei et al. combined event-driven STDP with IF neural networks and proposed a supervised learning algorithm with local time efficiency. The trained SNN performed well.
[0057] As can be seen from the above, there are many studies on unsupervised and supervised learning algorithms based on STDP. In recent years, some semi-supervised learning algorithms that combine unsupervised and supervised learning have also emerged. Lee et al. combined STDP unsupervised pre-training and BP supervised fine-tuning and proposed a semi-supervised learning method. The results show that STDP unsupervised pre-training significantly improves the robustness and training speed of the training process, and helps to optimize and generalize the system. Furuya et al. used the STDP back-propagation algorithm for supervised learning, and then used unsupervised STDP for fine-tuning, and still achieved good performance in the case of a small number of labeled samples. In order to solve the overfitting problem in the SNN training process, Jongseok et al. introduced teacher neurons and negative label signals, first performed STDP supervised pre-training, and then performed STDP unsupervised fine-tuning, which effectively improved the model classification performance.
[0058] There are a lot of research results on the pulse neural network learning algorithm, most of which are through conversion or direct training, while the STDP rule series algorithm with more biological authenticity has developed slowly, and the gap with the former is obvious. For this reason, the present application studies the pulse neural network learning algorithm based on the STDP rule, and proposes a corresponding method from unsupervised learning. The main ideas are as follows: This embodiment proposes an unsupervised learning algorithm based on the STDP rule. In the common pulse neural network learning algorithm, the neuron model is mostly traditional models such as IF, LIF, SRM, etc. The calculation form is simple and the function is limited, which cannot meet the needs of algorithm development. For this reason, this embodiment introduces a LIF neuron model with an adaptive threshold to improve the model's adaptive ability and noise resistance. The adaptive threshold can be closer to the refractory period mechanism in biological neurons, and the problem of input-output mismatch caused by calculation disorder can also be solved. In addition, the current STDP weight update is basically adjusted in the form of a single sample and a single time step, which is likely to aggravate the convergence instability caused by the sample distribution deviation, and the convergence speed of the model is also slow. The STDP updated by batches summarizes the changes brought by batch samples in multiple time steps to adjust the synaptic weights, which can solve this problem well. After the sample is encoded and passed into the network, each layer will learn its features. During this period, it is easy to learn repeated features, and feature redundancy will reduce computational efficiency, generalization ability and interpretability. For this reason, a dynamic lateral inhibition mechanism is introduced to enhance feature learning ability and reduce feature redundancy. During the pulse transmission process, if the neuron input current is too high or too low, it will cause the firing rate to be unstable, which is not conducive to effective information representation. This embodiment uses a dynamic synaptic filter to adjust the current and improve the stability of the model. Finally, according to a series of experiments, the results show that the method of this embodiment has a significant improvement in image recognition tasks compared with other similar methods. The combined modules have also been proven to be effective, and the model performance has been improved to varying degrees.
[0059] The present invention will be further described below in conjunction with the accompanying drawings and specific embodiments.
[0060] Example
[0061] like Figure 1 As shown, this embodiment discloses a method for constructing a deep pulse neural network based on the STDP rule, comprising the following steps:
[0062] Modeling: Building a spiking neuron model;
[0063] Encoding: constructing neural pulse sequences to encode the information transmitted by neurons;
[0064] And, training: model training based on STDP rules;
[0065] Wherein, the neuron adopts an adaptive threshold LIF neuron, and the dynamic change of the threshold satisfies the following formula;
[0066]
[0067] in, represents the threshold value that changes with time, V th0 is the initial threshold, g(t) represents the tolerance of the neuron to the input stimulus when it fires, and g(t) is determined by the following two equations:
[0068]
[0069] g(t)=g(t-1)+g 0
[0070] Among them, τ g is the time constant, g 0 is a constant.
[0071] As an optional implementation, the encoding adopts a rate encoding method.
[0072] As an optional implementation, in the STDP rule, the modification of the weight is determined by the time interval between the presynaptic and postsynaptic pulses. The larger the time interval, the smaller the correlation between the two pulses, and the smaller the impact on the synaptic weight:
[0073]
[0074] When Δt=t a -t b >0, then
[0075]
[0076] Among them, Δw b is the change in synaptic weight between neurons a and b, W is the STDP function, Δt is the time difference, χ offset Used to determine whether synaptic connections are enhanced or depressed, A + represents the enhancement coefficient, τ + Represents the time constant.
[0077] As an optional implementation, in the case of a single sample, when the postsynaptic neuron emits a pulse, the weight change is as follows:
[0078]
[0079] in, is the synaptic trace; when a pulse is received from the presynaptic neuron, χ pre is 1, the change of synaptic trace is as follows:
[0080]
[0081] Among them, λ + for
[0082] As an optional implementation, in the case of batch samples, when the postsynaptic neuron emits a pulse, the weight change is as follows:
[0083]
[0084] Among them, B S That is, BatchSize represents the number of samples in a single batch, and T represents the time step of a single batch; the change of synaptic trace is shown as follows:
[0085]
[0086] As an optional implementation, for the convolutional layer, the normalization operation is as follows:
[0087]
[0088] in, is the normalization scale factor of the convolutional layer, mean() is the mean function, and std() is the standard deviation function.
[0089] For the fully connected layer, the normalization operation is as follows:
[0090]
[0091] in, is the normalization scale factor of the fully connected layer, represents the synaptic weight between neurons a and b.
[0092] As an optional embodiment, the membrane potential of the neuron is controlled by a dynamic lateral inhibition mechanism, with the maximum input current I max As a reference value, let the threshold current be If the current I (t) When the threshold is exceeded, the following equation is used:
[0093]
[0094] in, Represents the inhibition value of the synaptic connection between neurons a and b, α inh is the coefficient for adjusting the degree of suppression, l represents the sample batch number, m, p and q represent the number of output channels and output size, The inhibition can only act on neurons that are not currently emitting pulses; the input current I (t) The synaptic weight and pulse Calculated as follows:
[0095]
[0096] As an optional implementation, a dynamic synaptic filter is established according to the input current, as shown in the following formula:
[0097]
[0098] Among them, δ represents the filter function, μ and β are the control coefficients of the filter.
[0099] In order to better understand the present application, the above embodiments are further described in the following parts.
[0100] 1. Adaptive threshold neuron.
[0101] As one of the most commonly used neuron models in spiking neural network learning algorithms, LIF neurons receive presynaptic spikes as input current and accumulate them on the decaying membrane potential. th When the neuron fires a pulse, the membrane potential gradually returns to the resting potential V rest If V ≥ V th , then S=1, and V=0; otherwise, S=0, and:
[0102]
[0103] Where R is the resistance, I is the input current, τ m is the time constant. The current between neurons can be regarded as the sum of synaptic weights, that is, I = ∑ a w ab v a , S a represents the impulse from the presynaptic neuron, w ab represents the synaptic weight.
[0104] For LIF neurons, due to their simpler form, the complexity of biological neurons is ignored, especially the adaptive ability in terms of thresholds. Fixed thresholds mean that LIF neurons may be very sensitive to noise, which will lead to unpredictable firing behavior of neurons and lack of sparsity in the network. Figure 2 As shown, in the algorithm of this embodiment, an adaptive threshold LIF neuron is used, and its threshold value changes dynamically as follows:
[0105]
[0106] g(t)=g(t-1)+g 0
[0107] When a neuron fires, its tolerance to input stimuli g(t) and threshold value increase by a constant g 0 , otherwise the threshold will be g Exponential decay to the initial threshold V th0 .
[0108] 2. Rate coding.
[0109] like Figure 3 As shown, for information encoding, this embodiment adopts a rate coding method. Rate coding is a commonly used information encoding method in neuroscience and neural network models, especially in pulse neural networks. In rate coding, information is encoded as the frequency at which a neuron fires pulses, that is, the number of pulses fired in a specific time window. The strength or size of the information is characterized by the rate at which the neuron fires pulses, and a higher signal strength corresponds to a higher pulse firing frequency. Rate coding can simplify the training and processing procedures of pulse neural networks, which is conducive to combining advanced technologies used in other traditional neural networks.
[0110] 3. Batch update STDP rules.
[0111] In the STDP rule, the modification of weights is determined by the time interval between presynaptic and postsynaptic spikes. The larger the time interval, the smaller the correlation between the two spikes, and the smaller the impact on the synaptic weight.
[0112]
[0113] When Δt=t a -t b >0, then:
[0114]
[0115] Among them, Δw b is the change in synaptic weight between neurons a and b, W is the STDP function, Δt is the time difference, χ offset To determine whether synaptic connections are enhanced or depressed, A + represents the enhancement coefficient, τ + Indicates the time constant. For unilateral STDP, before the postsynaptic neuron fires a spike, only the spikes fired by the presynaptic neuron are considered, which makes the synaptic strength continue to grow.
[0116] To improve the efficiency of simulation calculation, the synaptic traces parameter is used to record the changes in synaptic weights. In addition to its own weight, each synapse also needs to save the synaptic trace of the previous synapse, recorded as It can accumulate the pulses from the presynaptic neuron and decay over time. When the postsynaptic neuron sends a pulse, χ post is 1, and the weight changes as shown in formula (1). When a pulse is received from the presynaptic neuron, χ pre is 1. The change of synaptic trace is shown in formula (2), where λ + for
[0117]
[0118] From the above formula, we can see that The lower it is, the lower the synaptic weight changes, which ensures that neurons that cannot fire synchronously are gradually disconnected, which is very useful when the postsynaptic neuron is rarely active. Of course, the same effect can be achieved by adding noise to the input or adding weight decay to the learning rule, but it is less efficient.
[0119] Compared with a single sample, the amount of information involved in the weight update in the case of batch samples is larger. When the postsynaptic neuron emits a pulse, the weight change is as follows:
[0120]
[0121] Among them, B S That is, BatchSize represents the number of samples in a single batch, and T represents the time step of a single batch.
[0122] The change of the synaptic trace is shown in the following formula. The difference from the previous one is that it is no longer a single sample:
[0123]
[0124] During the training process, if the weight is too large or too small, it may cause problems such as gradient explosion or disappearance. Therefore, the weight should be normalized after updating to maintain the stability of the network. In addition, adding a pulse normalization module between layers can stabilize the input and output and limit the input range of the pulse.
[0125] For the convolutional layer, the normalization operation is as follows:
[0126]
[0127] in, is the normalization scale factor of the convolutional layer, mean() is the mean function, and std() is the standard deviation function.
[0128] For the fully connected layer, the normalization operation is as follows:
[0129]
[0130] in, is the normalization scale factor of the fully connected layer, represents the synaptic weight between neurons a and b.
[0131] 4. Dynamic lateral inhibition mechanism.
[0132] The dynamic lateral inhibition mechanism controls the membrane potential of neurons by setting a threshold, thereby inhibiting neurons from tending to the same state and avoiding learning repeated features. max As a reference value, the degree of suppression is determined by the maximum current of different inputs. Let the threshold be If the current I (t) When the threshold is exceeded, the following equation is used:
[0133]
[0134] in, Represents the inhibition value of the synaptic connection between neurons a and b, α inh Is the coefficient for adjusting the suppression degree. Input current I (t) The synaptic weight and pulse Calculated, l represents the sample batch number, m, p and q represent the number of output channels and output size, The inhibition can be made to act only on neurons that are not currently emitting pulses. In addition, using the winner-take-all strategy (wta), randomly select a neuron that is emitting pulses, and set the number of pulses of other neurons to 0, we can get:
[0135]
[0136] Among them, wta() represents the winner-takes-all strategy function.
[0137] 5. Dynamic synaptic filter.
[0138] By increasing or decreasing the signal transmission efficiency of the synapse, the information can be filtered, and a dynamic synaptic filter can be established according to the input current, as shown in the following formula:
[0139]
[0140] Among them, δ represents the filter function, and μ and β are the control coefficients of the filter. The dynamic synaptic filter adjusts the current size through a nonlinear function, making it easier for the current to concentrate near the threshold or resting potential. If the current is concentrated near the threshold, more neurons will be likely to be activated and participate in the calculation of the network, and the competition between neurons will increase. More neurons participating in the competition can help avoid a single neuron from dominating and reduce the noise generated when low-current neurons emit pulses.
[0141] In another embodiment, the present application also discloses an electronic device, comprising: one or more processors; one or more memories; the one or more memories store one or more computer programs, the one or more computer programs include instructions, and when the instructions are executed by the one or more processors, the electronic device executes the method disclosed in the above embodiment.
[0142] In yet another embodiment, the present application further discloses a computer-readable medium, including a computer program. When the computer program is executed on a computer, the computer is enabled to execute the method disclosed in the above embodiment.
[0143] Those skilled in the art can clearly understand that, for the convenience and brevity of description, the specific working processes of the electronic device and computer-readable medium described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0144] Through the description of the above embodiments, it is easy for those skilled in the art to understand that the example embodiments described here can be implemented by software, or by combining software with necessary hardware. Therefore, the technical solution according to the embodiment of the present application can be embodied in the form of a software product, which can be stored in a readable medium or on a network, and includes several instructions to enable an electronic device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the embodiment of the present application.
[0145] The above-mentioned readable medium can be a readable signal medium or a readable storage medium. The readable storage medium can be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples (non-exhaustive list) of readable storage media include: an electrical connection with one or more wires, a portable disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above.
[0146] The above is only a specific implementation method of the present application, but the protection scope of the present application is not limited thereto. Any technician familiar with the technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. All technical solutions that fall within the scope defined by the claims of the present invention fall within the protection scope of the present invention.
Claims
1. A method for constructing a deep pulse neural network based on the STDP rule, characterized in that: The following steps are involved: Modeling: Building a spiking neuron model; Encoding: constructing neural pulse sequences to encode the information transmitted by neurons; And, training: model training based on STDP rules; Wherein, the neuron adopts an adaptive threshold LIF neuron, and the dynamic change of the threshold satisfies the following formula; in, represents the threshold value that changes with time, V th0 is the initial threshold, g(t) represents the tolerance of the neuron to the input stimulus when it fires, and g(t) is determined by the following two equations: g(t)=g(t-1)+g0 Among them, τ g is the time constant and g0 is a constant.
2. The method for constructing a deep pulse neural network based on the STDP rule according to claim 1, characterized in that: The encoding adopts a rate encoding method.
3. The method for constructing a deep pulse neural network based on the STDP rule according to claim 1, characterized in that: In the STDP rule, the modification of weights is determined by the time interval between presynaptic and postsynaptic pulses. The larger the time interval, the smaller the correlation between the two pulses, and the smaller the impact on the synaptic weight: When Δt=t a -t b >0, then: Among them, Δw b is the change in synaptic weight between neurons a and b, W is the STDP function, Δt is the time difference, χ offset Used to determine whether synaptic connections are enhanced or depressed, A + represents the enhancement coefficient, τ + Represents the time constant.
4. The method for constructing a deep pulse neural network based on the STDP rule according to claim 3, characterized in that: In the single sample case, when the postsynaptic neuron emits a pulse, the weight changes as shown below: in, is the synaptic trace; when a pulse is received from the presynaptic neuron, χ pre is 1, the change of synaptic trace is as follows: Among them, λ + for 5. The method for constructing a deep pulse neural network based on the STDP rule according to claim 4, characterized in that: In the case of batch samples, when the postsynaptic neuron fires a spike, the weight changes as follows: Among them, B S represents BatchSize, represents the number of samples in a single batch, and T represents the time step of a single batch; the change of synaptic trace is shown as follows:
6. The method for constructing a deep pulse neural network based on the STDP rule according to claim 5, characterized in that: For the convolutional layer, the normalization operation is as follows: Among them, ζ1 is the normalization scale factor of the convolution layer, mean() is the mean function, and std() is the standard deviation function; For the fully connected layer, the normalization operation is as follows: Among them, ζ2 is the normalization scale factor of the fully connected layer, represents the synaptic weight between neurons a and b.
7. The method for constructing a deep pulse neural network based on the STDP rule according to any one of claims 3 to 6, characterized in that: The membrane potential of the neuron is controlled by a dynamic lateral inhibition mechanism, with the maximum input current I max As a reference value, let the threshold current be If the current I (t) When the threshold is exceeded, the following equation is used: in, Represents the inhibition value of the synaptic connection between neurons a and b, α inh is the coefficient for adjusting the degree of suppression, l represents the sample batch number, m, p and q represent the number of output channels and output size, The inhibition can only act on neurons that are not currently emitting pulses; the input current I (t) The synaptic weight and pulse Calculated as follows:
8. The method for constructing a deep pulse neural network based on the STDP rule according to claim 7, characterized in that: A dynamic synaptic filter is established based on the input current, as shown in the following formula: Among them, δ represents the filter function, μ and β are the control coefficients of the filter.
9. An electronic device, characterized in that: include: one or more processors; One or more memories; the one or more memories store one or more computer programs, the one or more computer programs include instructions, when the instructions are executed by the one or more processors, the electronic device executes the method as described in any one of claims 1-8.
10. A computer-readable medium, characterized in that The method comprises a computer program, which, when being executed on a computer, causes the computer to execute the method according to any one of claims 1 to 8.
Citation Information
Patent Citations
Pulse self-organizing neural network STDP learning method based on LIF neuron model
CN117273089A
Cited By
Multi-modal sensing electromechanical actuator fault prediction system and control method thereof
CN120143610A
Video type physiological signal dynamic extraction method and device
CN122157090A
