Method and device for detecting a neural response in a neural measurement
10426409 ยท 2019-10-01
Assignee
Inventors
Cpc classification
A61B5/4848
HUMAN NECESSITIES
G06F2218/00
PHYSICS
A61B5/7282
HUMAN NECESSITIES
A61B5/7246
HUMAN NECESSITIES
A61B5/6846
HUMAN NECESSITIES
A61B5/24
HUMAN NECESSITIES
International classification
Abstract
A method for processing a neural measurement obtained in the presence of artifact, in order to detect whether a neural response is present in the neural measurement. A neural measurement is obtained from one or more sense electrodes. The neural measurement is correlated against a filter template, the filter template comprising at least three half cycles of an alternating waveform, amplitude modulated by a window. From an output of the correlating, it is determined whether a neural response is present in the neural measurement.
Claims
1. A method for processing a neural measurement obtained in the presence of artifact, in order to detect whether a neural response is present in the neural measurement, the method comprising: obtaining a neural measurement from one or more sense electrodes, the neural measurement being obtained in the presence of artifact; correlating the neural measurement against a filter template, the filter template comprising at least three half cycles of an alternating waveform, amplitude modulated by a window; and determining from an output of the correlating whether a neural response is present in the neural measurement.
2. The method of claim 1 wherein the window comprises a triangular window.
3. The method of claim 2 wherein the triangular window is a standard triangular window of length L comprising coefficients w(n) as follows:
4. The method of claim 2 wherein the triangular window is a Bartlett window in which samples 1 and L are zero.
5. The method of claim 1 wherein the window comprises one of a Hanning window, a rectangular window or a Kaiser-Bessel window.
6. The method of claim 1 wherein the window comprises one or more basis functions derived from a sinusoidal binomial transform.
7. The method of claim 1 wherein the filter template comprises four half-cycles of an alternating waveform.
8. The method of claim 1 wherein the filter template comprises half cycles of a sine wave, modified by being amplitude modulated by the window.
9. The method of claim 1 wherein the filter template comprises half cycles of a cosine wave, modified by being amplitude modulated by the window.
10. The method of claim 1 wherein only a single point of the correlation is calculated.
11. The method of claim 10 wherein the single point of the correlation is calculated at a predefined optimal time delay.
12. The method of claim 11, further comprising determining the optimum time delay when a signal to artifact ratio is greater than one, at which a first or single point of the cross-correlation between the neural measurement and the filter template should be produced, by: at an approximate time delay between the neural response and the filter template, computing real and imaginary parts of the fundamental frequency of the DFT of the neural measurement; calculating a phase defined by the real and imaginary parts; relative to a fundamental frequency of the template, calculating the time adjustment needed to change the calculated phase to /2; and defining the optimum time delay as being the sum of the approximate time delay and the time adjustment.
13. The method of claim 11, wherein the optimum time delay is recalculated prior to every attempted detection of a neural response.
14. The method of claim 11, wherein the optimum time delay is recalculated in response to a detected change in the user's posture.
15. An implantable device for processing a neural measurement obtained in the presence of artifact, in order to detect whether a neural response is present in the neural measurement, the device comprising: measurement circuitry for obtaining a neural measurement from one or more sense electrodes, in the presence of artifact; and a processor configured to correlate the neural measurement against a filter template, the filter template comprising at least three half cycles of an alternating waveform, amplitude modulated by a window; and the processor further configured to determine from an output of the correlating whether a neural response is present in the neural measurement.
Description
BRIEF DESCRIPTION OF THE DRAWINGS
(1) An example of the invention will now be described with reference to the accompanying drawings, in which:
(2)
(3)
(4)
(5)
(6)
(7)
(8)
(9)
(10)
(11)
(12)
(13)
(14)
(15)
(16)
(17)
DESCRIPTION OF THE PREFERRED EMBODIMENTS
(18)
(19)
(20) The evoked CAP measurements in this embodiment are made by use of the neural response measurement techniques set out in International Patent Publication No. WO2012/155183.
(21)
(22)
(23)
(24) It is noted that when sampling at 10 kHz, for example, 20 samples will be obtained in a 2 ms window, so that to determine the entire cross correlation will require 400 multiply/add operations. Accordingly, rather than calculating the entire cross-correlation between a measured neural response and the filter template, the present embodiment further provides for calculation of only a single point of the correlation as the output 316 of detector 300, as a single point requires only 20 samples when sampling a 2 ms window at 10 kHz. Noting that the arrival time of the neural response, or its position within the neural measurement 302, is not known a priori, it is necessary to determine an optimal time delay or offset between the neural measurement and the template filter, at which the single point of the correlation should then be calculated. The aim is to calculate the single point at the peak of the curve 504, and no other. To this end, the present embodiment efficiently determines the optimal time delay, by noting the following.
(25) The DFT is defined by:
(26)
(27) In equation (1), and in the rest of this document, frequency-domain signals are represented by capital letters, and time-domain signals using lower-case. When using the DFT for spectral analysis, it is usual to multiply the data by a window W(n) so this becomes:
(28)
(29) This can be expressed in traditional magnitude and phase terms where the magnitude of the windowed DFT term is
|X.sub.k|={square root over (Re(X.sub.k).sup.2+Im(X.sub.k).sup.2)}(3)
and the phase of the windowed DFT term is
(30)
(31) The hardware 600 used to compute one term of X.sub.k is illustrated in
(32)
it is noted that detector 300 using the filter template 304 (
(33) This also provides insight into what happens as the time delay is adjusted during a clinical fitting procedure, as shown in
(34) When considering the entire cross correlation as the evoked response slides across the window (
(35) 1. Roughly align the window and the signal S(t);
(36) 2. Calculate the imaginary (sin) and real (cosine) terms:
I=S(t).Math.W(t).Math.sin(1 KHz.Math.2.Math.t), anda.
Q=S(t).Math.W(t).Math.cos(1 KHz.Math.2.Math.t);b.
(37) 3. Find the angle to the y-axis using atan(Q/I);
(38) 4. As the template has fixed known frequency, calculate the time shift needed to set the sin term to its maximum;
(39) 5. Calculate the imaginary (sin) and real (cosine) terms for the new delay. The cosine term should be much smaller than the sin term confirming that the method worked.
(40) Such embodiments may be particularly advantageous as compared to a clinical process requiring exploration of the varying delays in order to find a peak.
(41) The present embodiment further incorporates the third and fourth aspects of the invention, and recognises that the artifact 506 can be well modelled as being a sum of two exponentials, of differing time constant. Each exponential component has a voltage and a time value, leading to
(42)
where v.sub.1 and .sub.1 are constants for each component.
(43) If
e(t)=v exp(t/)(7)
then we can consider its windowed DFT E.sub.k, for which each term will have a magnitude and phase, and the term E.sub.2 can be calculated with the complex correlator 600 of
(44) If we take some signal e.sup.t/ and shift the point in the signal at which the correlation is performed by some arbitrary time T, since
e.sup.(t+T)/=e.sup.t/e.sup.T/
e.sup.(t+T)/=e.Math.e.sup.t/(8)
where e is some constant.
(45) Thus, the phase of the DFT terms of a single exponential depend on the time constant of the exponential, as shown in
(46)
(47)
(48) When modelling the artifact as a sum of two exponential terms, it has been determined from measurements of actual artifact that the time constant .sub.1 of the first (slow) exponential term is typically in the range 300 ms to 30 ms, more typically 500 s to 3 ms and most commonly about 1 ms, and that the time constant .sub.2 of the second (fast) exponential term is typically in the range 60-500 s, more typically 100-300 s, and most commonly about 150 s.
(49) The method of this embodiment, utilising the third and fourth aspects of the invention, relies on making two complex measurements of the evoked response, at points in time separated by one quarter of a cycle, as shown in
(50)
(51)
(52) Knowing k also allows the evaluation of , and of the fast artifact exponential:
(53)
(54) To find the voltage of the fast exponential term for the artifact, one can further calculate the DFT of the exponential which is what would be expected from the detectors for an exponential input of that time constant, normalized to 1.0:
(55)
(56) Then, an estimation of the fast artifact term is:
(57)
(58) Having calculated the above, it is possible to improve the SAR of the signal by subtracting the estimated exponential, as shown in
(59) A difficulty in implementing this algorithm with measured data is that it measures two signals at once, namely the evoked response and the fast exponential, and each forms a noise source for the other. Usually, the phase of the evoked response is not known exactly, and this introduces errors into
(60) When the relative phase () of the evoked response to the sampling window is unknown, the proposal of
(61)
(62) In turn, the five terms a, b, k, and c can be found. For some phase between the measurement window and the evoked response:
m1=a+c sin
m2=b+c cos
m3=ak+c cos
m4=bk+c sin (15)
so:
(63)
(64) The phase will change slowly, so once is known, it is possible to adjust the delay of the sampling window, and then revert to the four point algorithm of
(65) When considering implementation of the six point technique of
(66)
(67) It is further noted that running the calculation after the evoked response is finished allows the slow exponential to be measured.
(68) The evoked response in the spine (having three phases) takes approximately 1 ms. In embodiments employing a sample rate of 30 KHz or a simple interval of 33 s, the evoked response will take around 30 samples. Consequently in such embodiments the filter template having four phases will comprise approximately 40 tap values, or data points. In alternative embodiments, using an alternative sampling rate or measuring a faster or slower CAP, the length of the filter may comprise correspondingly greater or fewer filter taps.
(69) While the preceding embodiments have been described in relation to a filter template which comprises four half cycles, alternative embodiments of the present invention may nevertheless usefully employ a filter template comprising greater or fewer lobes. The present invention thus recognises that the ideal number if lobes is four. This is in contrast to a two lobe filter, which will have equal first and second lobes and will thus put more emphasis on the early parts of the signal where the signal-to-artifact is worse. Further, a filter with an odd number of lobes does not tend to have good artifact rejection properties. Moreover, if one were to use a six-lobe filter, or higher even-number lobed filter, the window becomes too wide relative to the 3-lobed neural response, and at least half the correlation time would just be looking at noise. Since most of the problematic artifact is in the first two lobes, a 6 lobe filter will tend not to provide better artifact rejection than the four-lobe filter. Four lobes thus provides the optimal trade-off between rejection of artifact and noise gain.
(70) Nevertheless, alternative embodiments of the present invention may usefully employ a filter template comprising greater or fewer lobes. We now describe the mathematical properties of templates of other embodiments of the invention. The term template is used to refer to a filter used via correlation to detect an ECAP. A template may be comprised of one or more wavelets or basis functions, or may be derived by some other method, and is configured to preferentially pass an ECAP but preferentially block or be orthogonal to artifact.
(71) That is, an important property of the sinusoidal binomial transform (SBT) is its ability to reject polynomial signals. If an SBT template of order n is used, it will reject all the terms of the Taylor series up to order n.
(72)
(73) It is further to be appreciated that cosine templates of 3, 5 or more lobes can be similarly generated, noting the
(74) The preceding embodiments further describe a filter template built using a triangular window. The triangular window is superior to the Bartlett, Hanning, rectangular and the Kaiser-Bessel for a variety of beta values. The performance of the four-lobe triangular template can be within 2 dB of a matched filter for optimised offset. Nevertheless, alternative embodiments may utilise windows other than the triangular window to useful effect, and such embodiments are thus within the scope of the present invention.
(75) Moreover, while the described embodiments use a single term of the SBT for response detection, the present invention further recognises that there are possible extensions to this method. Therefore, some embodiments of the invention may use multiple identical templates, but shifted in time. Even though these are not orthogonal, a successive approximation method creating a compound template may provide better approximation. Additionally or alternatively, some embodiments may use templates that are a sum of templates of different frequencies, templates of different offset and/or templates of different numbers of lobes.
(76) A benefit of some embodiments of the present invention is that in some embodiments the detector produces an output based on a single neural measurement, without requiring multiple neural measurements to produce a detector output. Such embodiments may thus provide a swift response time of a feedback control loop utilising the detector output.
(77) It will be appreciated by persons skilled in the art that numerous variations and/or modifications may be made to the invention as shown in the specific embodiments without departing from the spirit or scope of the invention as broadly described. The present embodiments are, therefore, to be considered in all respects as illustrative and not restrictive.