Action potential detection method and chip, and multi-channel neural signal acquisition system
Through the template matching algorithm of signal regularization, the detection accuracy and real-time problems caused by low signal-to-noise ratio in large-scale multi-channel neural signal acquisition systems are solved, and efficient action potential detection in a low signal-to-noise ratio environment is achieved, which is suitable for multi-channel neural signal acquisition equipment.
Patent Information
- Application Number
- CN202310683169.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-06-09
- Publication Date
- 2025-08-26
- Estimated Expiration
- 2043-06-09
AI Technical Summary
In the existing technology, in large-scale multi-channel neural signal acquisition systems, the low signal-to-noise ratio leads to insufficient accuracy and real-time performance of action potential detection. In particular, the template matching algorithm requires strict signal strength and signal-to-noise ratio, making it difficult to effectively detect in a low signal-to-noise ratio environment.
The template matching algorithm for signal regularization is adopted to cache input signals and align input signals, calculate the degree of convolution correlation between the input signals and template action signals, and regularize the input signals, and use the mode length to determine whether it is an action potential, and combine the built-in template and threshold information update module to realize multi-channel neural signal acquisition.
It improves the accuracy and real-time performance of action potential detection in a low signal-to-noise environment, and is suitable for multi-channel neural signal acquisition devices, reducing the complexity and power consumption of hardware implementation.
Smart Images

Figure CN116636860B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of action potential detection, and in particular to an action potential detection method and chip, and a multi-channel neural signal acquisition system. Background Art
[0002] Action potentials (APs) are a key analytical data point in neurophysiology. Recording and analyzing APs is the foundation and prerequisite for subsequent decoding. Its applications range from brain-computer interfaces to neural coding, and it holds significant significance for the prevention and detection of brain disorders such as epilepsy. The accuracy of AP signal detection algorithms is positively correlated with the signal-to-noise ratio (SNR) of the raw signal output by the front-end multi-channel signal acquisition IC. However, these ICs are often limited by factors such as the impedance of the signal acquisition electrodes, the application environment, system power consumption, and system area, resulting in low SNR outputs. Currently, neural signal acquisition chips are becoming increasingly large, with many now boasting thousands of channels. The real-time nature of action potential detection is becoming increasingly critical, necessitating a detection IC with low SNR and high accuracy for neural signal recognition in large-scale multi-channel acquisition systems.
[0003] Action potential detection algorithms can be categorized into threshold detection algorithms, template matching algorithms, and, more recently, deep learning algorithms. Threshold detection algorithms have lower hardware requirements and offer good classification performance. Whether it's the early manual threshold setting or the various derivative algorithms that have emerged, such as calculating the mean squared value of the input signal or the dual-threshold AP signal detection method with automatic threshold calculation, these algorithms focus solely on time-domain information. When the signal-to-noise ratio decreases, missed detections and false detections can occur. While deep learning algorithms can achieve good detection results, they are very resource-intensive. A convolutional neural network with two convolutional layers for action potential detection has nearly 700,000 weight parameters, which consumes a significant amount of area and power for hardware implementation. Template matching algorithms, on the other hand, detect an AP signal when the correlation between the original acquired signal and the AP template action signal exceeds a specific threshold. Template matching algorithms also include AP signal detection methods based on discrete wavelet transforms. These transforms can be implemented using multiple filter banks, leveraging scale invariance to achieve high detection rates. However, the discrete wavelet transform method has strict requirements on the intensity and signal-to-noise ratio of the original collected signal, and also requires setting a large number of filter parameters, which is not conducive to the implementation of on-chip detection systems. Summary of the Invention
[0004] The purpose of the present invention is to overcome the defects of the above-mentioned prior art and to provide an action potential detection method and chip, as well as a multi-channel neural signal acquisition system, which can achieve good neural signal detection and recognition effects in a low signal-to-noise ratio environment.
[0005] The purpose of the present invention can be achieved by the following technical solutions:
[0006] According to a first aspect of the present invention, there is provided a method for detecting action potentials, the method comprising the following steps:
[0007] Step S1: Buffer the input original signal and align the input signal;
[0008] Step S2: Calculate the convolution of the input signal and the template action signal to obtain the correlation between the two;
[0009] Step S3: regularize the input signal and calculate the input signal modulus;
[0010] Step S4: take the product of the input signal modulus and the set judgment threshold as a benchmark, and judge whether the convolution of the input signal and the regularized template action signal is greater than the benchmark; if it is greater than the benchmark, judge that the input frame data is an action potential.
[0011] Preferably, the aligning of the input signal in step S1 specifically includes aligning the peak value of the input signal of each frame with the peak value of the preset action template potential.
[0012] Preferably, in step S2, the convolution of the input signal and the template action signal is calculated to obtain the correlation between the two. Considering each input signal vector as a frame, the correlation degree y[m] between the input signal of the mth frame and the template action signal is expressed as:
[0013]
[0014] Where N is the sampling length, X m The input vector for the mth frame, i.e. X m =[x[m],x[m-1],…,x[m-N+1]] T ; t is the preset template vector, which is also N sampling points, that is, t=[t[1],…,t[N-1]] T .
[0015] Preferably, the step S3 is specifically as follows:
[0016] Regularize the input signal and the expression is:
[0017]
[0018] Where, is the input vector The normalized vector, is the regularized vector of the preset template vector t, ||X m || is vector X m Length of the module;
[0019] Calculate the input signal modulus ||X m ||, the expression is:
[0020] ||X m || 2 =||X m-1 || 2 -x 2 [mN]+x 2 [m] (3)
[0021] In the formula, ||·|| represents the vector modulus length, and the input signal X m and X m-1 Repeat N-1 points, x[mN] is the input vector X m-1 The first data, x[m] is the input vector X m-1 The last data.
[0022] Preferably, the action potential determination condition in step S4 is:
[0023]
[0024] In the formula, α is the judgment threshold, is the preset template vector after regularization.
[0025] Preferably, the step S1 further comprises pre-screening the input vector according to the local peak value and the height of the local peak value. , the filter conditions are:
[0026]
[0027] Where, is the normalized input vector, max() is for finding the maximum value of the vector, abs() is for finding the absolute value of all numbers in the vector, c is the set constant, and refvalue is the reference amplitude value.
[0028] According to a second aspect of the present invention, an action potential detection chip is provided, which uses the method described above to convert an input raw acquisition signal into a one-bit information stream, wherein the position where the action potential appears is marked as 1, and the remaining positions are marked as 0. The action potential detection chip includes:
[0029] Data preprocessing module, used to cache the input raw signal and align the input signal;
[0030] Convolution module, used to calculate the convolution of the input signal and the template action signal, and calculate the modulus of the input signal;
[0031] Regularization module, used to regularize the input signal and calculate the modulus of the input signal;
[0032] The comparator module is used to use the product of the input signal module length and the set judgment threshold as a benchmark to determine whether the convolution of the input signal and the regularized template action signal is greater than the benchmark. If it is greater than the benchmark, the input frame data is determined to be an action potential.
[0033] According to a third aspect of the present invention, a multi-channel neural signal acquisition device is provided, in which a plurality of action potential detection chips are integrated, and the device further comprises:
[0034] A built-in template and threshold information updating module is used to update and judge the built-in template action signal and threshold information of the action potential detection chip;
[0035] The scheduling module is used to schedule the plurality of action potential detection chips.
[0036] Preferably, the built-in template and threshold information updating module is specifically as follows: if the built-in template and threshold information are updated, the relevant registers in the action potential detection chip are configured through the SPI interface, and the action potential detection chip returns the register data to verify whether the configuration is correct.
[0037] Preferably, the specific detection process of the device is as follows:
[0038] 1) Preselect channels where action potentials are more concentrated;
[0039] 2) combining the action potential detection chips of the idle channels, configuring a template action potential for each of the action potential detection chips, and simultaneously providing the signals selected in 1) to the action potential detection chips;
[0040] 3) The outputs of multiple action potential detection chips are simultaneously ANDed to perform single-channel multi-template neural action potential detection.
[0041] Compared with the prior art, the present invention has the following advantages:
[0042] 1) The action potential detection method designed in this invention introduces signal regularization based on the template matching algorithm to eliminate redundant information in neural signals. This overcomes the problem of decreased detection performance caused by large differences between template action potentials and can achieve better detection results in low signal-to-noise ratio environments.
[0043] 2) The action potential detection chip of the present invention has high real-time performance, has been implemented in hardware, and can be integrated into a front-end acquisition chip;
[0044] 3) The action potential detection chip designed by the present invention is suitable for multi-channel neural signal acquisition equipment, and can realize multi-channel neural action potential detection through the scheduling algorithm. BRIEF DESCRIPTION OF THE DRAWINGS
[0045] Figure 1 This is a flow chart of the action potential detection chip method of the present invention;
[0046] Figure 2 This is a workflow diagram of the action potential detection chip of the present invention;
[0047] Figure 3 is a block diagram of the action potential detection system of the present invention;
[0048] Figure 4 Schematic diagram of the structure of the action potential detection chip of the present invention;
[0049] Figure 5 It is a detection and recognition timing diagram and effect diagram in the embodiment. DETAILED DESCRIPTION
[0050] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of them. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without making creative efforts should fall within the scope of protection of the present invention.
[0051] Example 1
[0052] First, this embodiment provides an action potential detection method, such as Figure 1 As shown, the method includes the following steps:
[0053] Step S1, buffering the input original signal and aligning the input signal; wherein, aligning the input signal specifically includes: aligning the peak value of each frame of the input signal with the peak value of the preset action template potential.
[0054] Step S2: Calculate the convolution of the input signal and the template action signal to obtain the correlation between the two, specifically:
[0055] Considering each input signal vector as a frame, the expression of the correlation degree y[m] between the input signal of the mth frame and the template action signal is:
[0056]
[0057] Where N is the sampling length, X m The input vector for the mth frame, i.e. X m =[x[m],x[m-1],…,x[m-N+1]] T ; t is the preset template vector, which is also N sampling points, that is, t=[t[1],…,t[N-1]] T From formula (1), we can see that the greater the correlation y is, the greater the input signal vector X is.m The closer it is to the template action signal vector t.
[0058] Step S3: Based on formula (1), data regularization is introduced to improve the detection performance of the algorithm in a low signal-to-noise ratio environment. The expression is:
[0059]
[0060] Where, is the input vector The normalized vector, is the regularized vector of the preset template vector t, ||X m || is vector X m The modulus of the input vector ||X m ||.
[0061] The neural signal is continuously input by the acquisition chip, so the input signal X m and X m-1 Repeat N-1 points, so calculate the input signal modulus || X m ||, it is better to calculate ||X first m || 2 , the expression is:
[0062] ||X m || 2 =||X m-1 || 2 -x 2 [mN]+x 2 [m] (3)
[0063] Where ||·|| represents the vector modulus, and x[mN] is the input vector X m-1 The first data, x[m] is the input vector X m-1 Compared with the definition of vector modulus, this greatly reduces the amount of calculation.
[0064] Step S4: Using the product of the input signal modulus and the set judgment threshold as a reference, determine whether the convolution of the input signal and the regularized template action signal is greater than the reference. If it is greater than the reference, determine that the input frame data is an action potential. The calculation and derivation process of the judgment condition of the action potential is as follows:
[0065] The Euclidean distance between vectors can measure the similarity between two vectors. and The distance between The calculation expression is:
[0066]
[0067] Where: ||·|| represents the vector modulus, is the regularization signal The modulus length is 1. According to formula (4), we can get From formula (2), we can see that The larger the value, the and The closer, so when hour, and Totally consistent.
[0068] when and When the similarity reaches a certain level, it can be considered is a spike potential, that is, set the judgment condition:
[0069]
[0070] In the formula, α is the judgment threshold.
[0071] According to formula (2), formula (5) is transformed into:
[0072]
[0073] In summary, every time a frame of neural signal value is input, equations (3) and (6) are used to determine whether the acquired signal is an action potential.
[0074] Next, this embodiment provides an action potential detection chip, which uses the above-mentioned action potential detection method to convert the input original acquisition signal into a one-bit information stream, where the position where the action potential appears is marked as 1, and the other positions are all 0, such as Figure 3 As shown, the action potential detection chip includes:
[0075] Data preprocessing module, used to cache the input raw signal and align the input signal;
[0076] Convolution module, used to calculate the convolution of the input signal and the template action signal, and calculate the modulus of the input signal;
[0077] Regularization module, used to regularize the input signal and calculate the modulus of the input signal;
[0078] The comparator module is used to use the product of the input signal module length and the set judgment threshold as a benchmark to determine whether the convolution of the input signal and the regularized template action signal is greater than the benchmark. If it is greater than the benchmark, the input frame data is determined to be an action potential.
[0079] Next, a multi-channel neural signal acquisition device is provided, in which a plurality of the aforementioned action potential detection chips are integrated, and the device also includes:
[0080] The built-in template and threshold information update module is used to update and judge the built-in template action signal and threshold information of the action potential detection chip; specifically: if the built-in template and threshold information are updated, the relevant registers in the action potential detection chip are configured through the SPI interface, and the action potential detection chip returns the register data to verify whether the configuration is correct.
[0081] The scheduling module is used to schedule the plurality of action potential detection chips.
[0082] The specific detection process of the multi-channel neural signal acquisition device is as follows:
[0083] 1) Preselect channels where action potentials are more concentrated;
[0084] 2) combining the action potential detection chips of the idle channels, configuring a template action potential for each of the action potential detection chips, and simultaneously providing the signals selected in 1) to the action potential detection chips;
[0085] 3) The outputs of multiple action potential detection chips are simultaneously ANDed to perform single-channel multi-template neural action potential detection.
[0086] Example 2
[0087] An action potential detection chip suitable for multi-channel neural signal acquisition uses a template matching algorithm and introduces signal regularization to reduce the differences between templates and realize action potential detection. The chip converts the input raw acquisition signal into a one-bit information stream, where the position where the action potential occurs is marked as 1, and the rest of the positions are marked as 0. The action potential detection chip mainly includes a three-stage pipeline:
[0088] Pipeline segment 1, data preprocessing, mainly involves aligning the extreme values of the input signal and the template signal, detecting whether the local peak potential meets the minimum peak requirement, and screening the input signals that meet the conditions.
[0089] Pipeline segment 2 mainly implements the convolution of the input signal and the template signal, and calculates the modulus of the input vector, which is used to calculate the regularized input vector.
[0090] Pipeline segment 3 is a comparator that determines whether the input is an AP signal based on built-in threshold information.
[0091] At the same time, the main working steps of the chip include:
[0092] (1) Determine whether to update the built-in template and threshold information of the detection IC;
[0093] (2) If the template information is updated, the relevant registers in the IC are configured through the SPI interface;
[0094] (3) If not updated, enter pipeline section 1 for data preprocessing;
[0095] (4) After passing through pipeline segment 1, the chip's pipeline segment 2 starts working at the same time;
[0096] (5) After passing through pipeline section 2, the chip's pipeline section 3 starts working and outputs the test results at the same time.
[0097] like Figure 2 The specific workflow of the action potential detection chip shown below includes:
[0098] Step 101: In a multi-channel neural signal acquisition chip, not all channels contain the action potential of interest at a certain time. All channels begin detection, and channels with a relatively high concentration of action potentials are pre-screened. Then, detection chips for idle channels are used for the channels with a relatively high concentration of action potentials.
[0099] Step 102: The signal collected by the front-end acquisition chip is input into the action potential detection chip, and is pre-detected for a period of time for the next step to determine the detection effect;
[0100] Step 103: Based on the pre-detection result, if the detection effect is not good, the configuration information of the action potential detection IC may be updated, such as the action potential template and threshold information;
[0101] Step 104: This involves using a neural signal with a higher signal-to-noise ratio outside the chip and applying a more complex algorithm to obtain a better action potential template.
[0102] Step 105: Configure the updated data to the motion detection IC through the SPI serial port protocol. At the same time, the motion detection IC will return the configured data to verify whether the configuration is correct.
[0103] Step 106: Detecting action potentials in the collected neural signals. The chip is mainly divided into three pipelines, which are performed simultaneously in steps 108, 109, and 110;
[0104] Step 108: Since the action detection template has 48 sampling points, and the peak is generally placed at the 12th sampling point, this embodiment pre-buffers 12 sampling points and aligns the action potential template with each frame of input signal based on the peak position.
[0105] Step 109: This pipeline segment mainly calculates the convolution of the input neural signal and the template action potential of each frame, as well as the modulus of the input signal, mainly through 48 parallel multipliers;
[0106] Step 110: By comparing the convolution and threshold information, determine whether the input signal of the frame is an action potential, that is, determine whether the similarity between the input signal of each frame and the template neural signal reaches the threshold.
[0107] Step 107: The action potential detection chip outputs the result. If multiple detection chips detect a certain channel at the same time, the results are output after an AND operation.
[0108] like Figure 3 As shown in FIG, the structural block diagram of the action potential detection chip of the present invention includes:
[0109] Data preprocessing module: Filter neural signals according to extreme amplitude. Both the input signal and the template action signal are signed 8-bit data, and the length of the template action signal is 48 sampling points.
[0110] Convolution module: This module convolves the input signal with the action potential template and calculates the similarity between the two for template matching. The convolution module uses 48 parallel signed 8-bit multipliers and can obtain the convolution result within two clock cycles.
[0111] Regularization module: Calculates the regularization of the input signal. First, calculate the square of the input vector modulus, and then take the square root to get the input vector modulus.
[0112] Comparator module: Combined with the pre-set judgment threshold information, it intercepts the corresponding data length and compares to confirm whether the input signal is an action potential signal.
[0113] like Figure 4 The diagram shows the entire chip architecture. External clock, reset, and enable signals are provided. CS is the chip select signal for controlling the SPI interface. A template action potential and threshold information must be configured. Indata is an 8-bit data stream that is connected to the ADC output of the front-end multi-channel acquisition chip. The entire system operates at 1 MHz. The dout output is a 1-bit data stream. This output can also be transmitted via Bluetooth, enabling a wireless system.
[0114] like Figure 5 , we are usually only interested in the location and frequency of action potentials, according to Figure 3 and Figure 4 The comparator module in the detection chip outputs a 1-bit data stream. Figure 5 As shown, after passing through the comparator, if the convolved Conv_data is greater than the product of the normalized Norm_data and the 8-bit threshold information Threshold, a high level is output in the next clock cycle as a sign that an action potential has been detected. Figure 5As shown on the left, the detection chip extracts the action signal from a neural signal, marks it as 1, and outputs a 1-bit data stream.
[0115] In order to save computational effort, in this embodiment, the local peak values and their heights are pre-screened. The filter criteria are:
[0116]
[0117] Where max() is the maximum value of the vector, abs() is the absolute value of all numbers in the vector, and refvalue is the reference amplitude. In this embodiment, the next step is performed when the peak value of each frame of the input signal is aligned with the peak value of the preset AP template potential and is greater than 1 / 4 of the reference amplitude.
[0118] In this embodiment, the judgment threshold range is set to α∈[0.5,0.6]. After a large number of experiments, it is known that good detection effects can be achieved within this range.
[0119] The other settings in this embodiment are the same as those in embodiment 1.
[0120] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any person skilled in the art can easily conceive of various equivalent modifications or substitutions within the technical scope disclosed in the present invention, and such modifications or substitutions are intended to be within the scope of protection of the present invention. Therefore, the scope of protection of the present invention shall be subject to the scope of protection of the claims.
Claims
1. A method for detecting action potential, characterized in that: The method comprises the following steps: Step S1, buffering the input original signal and aligning the input signal; the aligning the input signal specifically includes: aligning the peak value of each frame of the input signal with the peak value of the preset action template potential; Step S2: Calculate the convolution of the input signal and the template action signal to obtain the correlation between the two; Step S3: regularize the input signal and calculate the input signal modulus; The input signal is regularized, and the expression is: Where, is the input vector The normalized vector, is the regularized vector of the preset template vector t, ||X m || is vector X m Length of the module; Step S4: taking the product of the input signal modulus and the set judgment threshold as a reference, judging whether the convolution of the input signal and the regularized template action signal is greater than the reference; if so, judging that the input frame data is an action potential; The judgment conditions of the action potential are: In the formula, α is the judgment threshold, is the preset template vector after regularization.
2. The action potential detection method according to claim 1, wherein: In step S2, the convolution of the input signal and the template action signal is calculated to obtain the correlation between the two. Considering each input signal vector as a frame, the correlation y[m] between the input signal of the mth frame and the template action signal is expressed as: Where N is the sampling length, X m The input vector for the mth frame, i.e. X m =[x[m],x[m-1],...,x[m-N+1]] T ; t is the preset template vector, which is also N sampling points, that is, t=[t[1],...,t[N-1]] T .
3. The action potential detection method according to claim 2, wherein: The step S3 is specifically as follows: Calculate the input signal modulus || X m ||, the expression is: ||X m || 2 =||X m-1 || 2 -x 2 [m-N]+x 2 [m] (3) In the formula, ||g|| represents the vector modulus length, and the input signal X m and X m-1 Repeat N-1 points, x[mN] is the input vector X m-1 The first data, x[m] is the input vector X m-1 The last data.
4. The action potential detection method according to claim 1, wherein: The step S1 also includes pre-screening the input vector according to the local peak value and the height of the local peak value. The filter criteria are: Where, is the normalized input vector, max() is used to find the maximum value of the vector, abs() is used to find the absolute value of all numbers in the vector, c is a set constant, and refvalue is the reference amplitude value.
5. An action potential detection chip, characterized in that: The method according to any one of claims 1 to 4 is used to convert the input raw acquisition signal into a one-bit information stream, wherein the position where the action potential appears is marked as 1 and the other positions are marked as 0, and the action potential detection chip comprises: Data preprocessing module, used to cache the input raw signal and align the input signal; Convolution module, used to calculate the convolution of the input signal and the template action signal, and calculate the modulus of the input signal; Regularization module, used to regularize the input signal and calculate the modulus of the input signal; The comparator module is used to use the product of the input signal module length and the set judgment threshold as a benchmark to determine whether the convolution of the input signal and the regularized template action signal is greater than the benchmark. If it is greater than the benchmark, the input frame data is determined to be an action potential.
6. A multi-channel neural signal acquisition device, characterized in that: A plurality of action potential detection chips according to claim 5 are integrated therein, and the device further comprises: A built-in template and threshold information updating module is used to update and judge the built-in template action signal and threshold information of the action potential detection chip; The scheduling module is used to schedule the plurality of action potential detection chips.
7. The multi-channel neural signal acquisition device according to claim 6, characterized in that: The built-in template and threshold information update module is specifically as follows: if the built-in template and threshold information are updated, the relevant registers in the action potential detection chip are configured through the SPI interface, and the action potential detection chip returns the register data to verify whether the configuration is correct.
8. The multi-channel neural signal acquisition device according to claim 7, characterized in that: The specific detection process of the device is as follows: 1) Preselect channels where action potentials are more concentrated; 2) combining the action potential detection chips of the idle channels, configuring a template action potential for each of the action potential detection chips, and simultaneously providing the signals selected in 1) to the action potential detection chips; 3) The outputs of multiple action potential detection chips are simultaneously ANDed to perform single-channel multi-template neural action potential detection.
Citation Information
Patent Citations
Electroneurographic signal compressed sensing processing verification system and construction method thereof
CN103617140A
Peak potential classification system and method for neural signals
CN112971813A