the design and hardware implementation of a low-power real ... · j. neural eng. 6 (2009) 056005 s...

13
IOP PUBLISHING JOURNAL OF NEURAL ENGINEERING J. Neural Eng. 6 (2009) 056005 (13pp) doi:10.1088/1741-2560/6/5/056005 The design and hardware implementation of a low-power real-time seizure detection algorithm Shriram Raghunathan 1, 4 , Sumeet K Gupta 2 , Matthew P Ward 1 , Robert M Worth 3 , Kaushik Roy 2 and Pedro P Irazoqui 1 1 Department of Biomedical Engineering, Purdue University, West Lafayette, IN 47906, USA 2 School of Electrical and Computer Engineering, Purdue University, West Lafayette, IN 47906, USA 3 Department of Neurosurgery, Indiana University School of Medicine, Indianapolis, IN, USA E-mail: [email protected] Received 13 June 2009 Accepted for publication 4 August 2009 Published 28 August 2009 Online at stacks.iop.org/JNE/6/056005 Abstract Epilepsy affects more than 1% of the world’s population. Responsive neurostimulation is emerging as an alternative therapy for the 30% of the epileptic patient population that does not benefit from pharmacological treatment. Efficient seizure detection algorithms will enable closed-loop epilepsy prostheses by stimulating the epileptogenic focus within an early onset window. Critically, this is expected to reduce neuronal desensitization over time and lead to longer-term device efficacy. This work presents a novel event-based seizure detection algorithm along with a low-power digital circuit implementation. Hippocampal depth-electrode recordings from six kainate-treated rats are used to validate the algorithm and hardware performance in this preliminary study. The design process illustrates crucial trade-offs in translating mathematical models into hardware implementations and validates statistical optimizations made with empirical data analyses on results obtained using a real-time functioning hardware prototype. Using quantitatively predicted thresholds from the depth-electrode recordings, the auto-updating algorithm performs with an average sensitivity and selectivity of 95.3 ± 0.02% and 88.9 ± 0.01% (mean ± SE α=0.05 ), respectively, on untrained data with a detection delay of 8.5 s [5.97, 11.04] from electrographic onset. The hardware implementation is shown feasible using CMOS circuits consuming under 350 nW of power from a 250 mV supply voltage from simulations on the MIT 180 nm SOI process. (Some figures in this article are in colour only in the electronic version) 1. Introduction Epilepsy is the second most common neurological disorder after strokes affecting over 1% of the world’s population [1]. Around 30% of this epileptic population does not respond to drugs and is not a candidate for resective surgery. Electrical stimulation promises to address this large patient population, and do so without the side effects often seen with pharmacological approaches. Vagus nerve stimulation [2], deep brain stimulation [3], and even direct electric 4 Author to whom any correspondence should be addressed. stimulation of the seizure focus [4] have been explored in the past and shown to suppress electrographic activity. However, a majority of reported devices use continuous or non-responsive stimulation (either intentionally or as a result of ineffective prediction or detection algorithms and large numbers of false positives) [25]. Closed-loop studies that trigger stimulation on seizure detection are very few and not thoroughly documented [6, 7]. Intermittent or periodic stimulation tends to decrease in efficacy over time, due to the neurons acclimating to the stimulus [8]. A responsive closed-loop electrical stimulator would limit the stimulus to the immediate pre-ictal period, decreasing 1741-2560/09/056005+13$30.00 1 © 2009 IOP Publishing Ltd Printed in the UK

Upload: others

Post on 16-Jul-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

IOP PUBLISHING JOURNAL OF NEURAL ENGINEERING

J. Neural Eng. 6 (2009) 056005 (13pp) doi:10.1088/1741-2560/6/5/056005

The design and hardware implementationof a low-power real-time seizure detectionalgorithmShriram Raghunathan1,4, Sumeet K Gupta2, Matthew P Ward1,Robert M Worth3, Kaushik Roy2 and Pedro P Irazoqui1

1 Department of Biomedical Engineering, Purdue University, West Lafayette, IN 47906, USA2 School of Electrical and Computer Engineering, Purdue University, West Lafayette, IN 47906, USA3 Department of Neurosurgery, Indiana University School of Medicine, Indianapolis, IN, USA

E-mail: [email protected]

Received 13 June 2009Accepted for publication 4 August 2009Published 28 August 2009Online at stacks.iop.org/JNE/6/056005

AbstractEpilepsy affects more than 1% of the world’s population. Responsive neurostimulation isemerging as an alternative therapy for the 30% of the epileptic patient population that does notbenefit from pharmacological treatment. Efficient seizure detection algorithms will enableclosed-loop epilepsy prostheses by stimulating the epileptogenic focus within an early onsetwindow. Critically, this is expected to reduce neuronal desensitization over time and lead tolonger-term device efficacy. This work presents a novel event-based seizure detectionalgorithm along with a low-power digital circuit implementation. Hippocampaldepth-electrode recordings from six kainate-treated rats are used to validate the algorithm andhardware performance in this preliminary study. The design process illustrates crucialtrade-offs in translating mathematical models into hardware implementations and validatesstatistical optimizations made with empirical data analyses on results obtained using areal-time functioning hardware prototype. Using quantitatively predicted thresholds from thedepth-electrode recordings, the auto-updating algorithm performs with an average sensitivityand selectivity of 95.3 ± 0.02% and 88.9 ± 0.01% (mean ± SEα=0.05), respectively, onuntrained data with a detection delay of 8.5 s [5.97, 11.04] from electrographic onset. Thehardware implementation is shown feasible using CMOS circuits consuming under 350 nW ofpower from a 250 mV supply voltage from simulations on the MIT 180 nm SOI process.

(Some figures in this article are in colour only in the electronic version)

1. Introduction

Epilepsy is the second most common neurological disorderafter strokes affecting over 1% of the world’s population[1]. Around 30% of this epileptic population does notrespond to drugs and is not a candidate for resective surgery.Electrical stimulation promises to address this large patientpopulation, and do so without the side effects often seenwith pharmacological approaches. Vagus nerve stimulation[2], deep brain stimulation [3], and even direct electric

4 Author to whom any correspondence should be addressed.

stimulation of the seizure focus [4] have been exploredin the past and shown to suppress electrographic activity.However, a majority of reported devices use continuous ornon-responsive stimulation (either intentionally or as a resultof ineffective prediction or detection algorithms and largenumbers of false positives) [2–5]. Closed-loop studies thattrigger stimulation on seizure detection are very few andnot thoroughly documented [6, 7]. Intermittent or periodicstimulation tends to decrease in efficacy over time, due to theneurons acclimating to the stimulus [8].

A responsive closed-loop electrical stimulator would limitthe stimulus to the immediate pre-ictal period, decreasing

1741-2560/09/056005+13$30.00 1 © 2009 IOP Publishing Ltd Printed in the UK

Page 2: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

overall stimulus delivery over time and thus the likelihoodof desensitization and neuronal damage. In fact, studiesreport that closed-loop neurostimulation enhances the efficacyof this therapy over time [9]. There have been severalstudies that model the spread of an electrographic seizurefrom a single or multiple clearly defined foci before leadingto clinical manifestations [10, 11]. These studies support theneed to integrate stimulator hardware with seizure detectionalgorithms to form a closed-loop epilepsy prosthesis, openingup avenues for reducing tissue damage over the long termand increasing stimulus efficacy. We present a seizure onsetdetection algorithm along with an ultra-low power hardwareimplementation that is designed to make this closed-loopsystem possible.

2. Background and significance

The field of seizure monitoring is broadly divided intoprediction and detection domains, which differ in the amountof time before clinical or electrographic seizure onset thatthese methods determine in the presence of an upcoming event.While seizure identification algorithms for data screening havemet with a fair amount of success, seizure prediction hasremained controversial due to uncertainty in the existence ofa ‘pre-ictal’ state in the brain that is different from its ‘inter-ictal’ state. A recent review of the state of the art in seizureprediction algorithms reports that most metrics previouslyconsidered suitable pre-cursors of seizure activity performno better than random predictors [12]. Seizure identificationis made easy due to relaxed requirements both from analgorithmic and hardware perspective, mainly because delayand hardware feasibility are not important considerations inthese data screening algorithms [13]. Early seizure detection,on the other hand, relies on accurately identifying either time orfrequency domain features that are different during the initialonset of an electrographic seizure episode. While it is hardto draw a strong temporal boundary between these categories,a recent classification made by the international workshop onseizure prediction (IWSP) considers any detection less than10 s prior to electrographic onset (EO) of the seizure to be in thedomain of early detection (figure 1). The exact quantificationof electrographic onset still remains unclear, with a number ofinterpretations based on amplitude, rhythmicity and frequencyof the signal [14, 15].

2.1. Temporal evolution and spread of seizures

The progression of a seizure has been commonly documentedto follow a relatively low-amplitude high-frequency start(tonic), followed by a higher-amplitude low-frequency middleperiod (clonic) and concluded with a significant decrease inthe amplitude of signals [13, 16]. In general, it is observedthat there is a decreased randomness during the ictal periodand an increased overall amplitude of signals compared tonon-seizing parts. The presented algorithm utilizes local fieldpotential data sampled at 1525 Hz from microelectrodes todetect the high-frequency onset of an electrographic seizure atits epileptogenic focus. The EO at the focus usually precedes

Figure 1. Temporal progression of seizure from thelower-amplitude high-frequency tonic phase to the higher-amplitudelower-frequency clonic phase with electrographic onset marked.Detection delay is represented by the two sided arrow bar betweenonset and actual detection. Early detection point as per thedefinition of IWSP 2009 is also marked.

the clinical onset (CO) of the seizure, allowing for detectionalgorithms to be employed rather than prediction. It is tobe understood however, that not all electrographic seizuresdetected in the focus are known to spread and generalize withclinical manifestations.

Jung and Milton model the spread of an ictal event radiallyaway from the focus at speeds up to 60 cm s−1 [17]. Ossorioand Frei report that a detection window of 0.8 s after EO wouldbe more than sufficient for effective warning or treatmenteven from ECoG data [16]. This is justified by a numberof literature reports of spontaneous seizure suppression withelectrical stimulation [18–20]. Spencer reports large intra-and inter-patient variations in the propagation time of aseizure event from the hippocampus to the neocortical regions,ranging from 2 to 70 s [20]. Other groups observe fromanimal studies that seizures starting in the temporal lobe oftentake over 20 s to spread outside of the focus region [21].Given the large body of evidence supporting the spread ofan ictal event away from a clearly defined focus, we proposeto implement the presented algorithm to aid an implantableepilepsy prosthesis to suppress electrographically detectedseizures before they spread outside of the focal regions. Theproposed seizure onset detection algorithm is designed to workin real time, using hippocampal local field potential recordingsobtained using implanted microelectrodes. A recent review ofseizure detection metrics points out that all compared metricsperformed significantly better in their ability to detect seizureswhen acquiring data from microelectrodes sampled at a higherfrequency as compared to scalp EEG [22]. Microelectroderecordings from deep brain structures are also relatively free ofcommonly observed artifacts seen in scalp EEG which hinderthe performance of the algorithm and prevent spatially andtemporally specific corrective treatment.

2.2. Seizure detection

Electrographic seizures are commonly recognized byincreased levels of spiking activity with corresponding changesin average amplitude and frequency [13, 14]. In fact, Osorioet al report that any attempt at detecting seizures must be basedon the recognition of changes in the power and frequency of

2

Page 3: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

the recorded signal [16]. One of the earliest attempts thatapplied a simple amplitude-based seizure detection algorithmreported 20 false detections out of 66 total detections [23]. Theresponsive neurostimulation system (eRNS) (Neuropace Inc.),which is the only currently known implantable closed-loopepilepsy prosthesis, employs among others a line-length-baseddetection algorithm that is a simplified version of the originalfractal dimensionality index first proposed by Katz [24]. Theline length is approximated to be the sum of distances betweensuccessive points on the data curve indicating either increasedamplitude or frequency or both. The presented approachutilizes a combination of amplitude and frequency along witha third rhythmicity index to classify seizures.

There have also been several more computationallyintense mathematical models proposed that employ artificialneural networks (ANN), genetic algorithms (GA) and waveletbased (WT) filtering schemes to eliminate artifacts [25].It is important to understand that algorithms that involveextensive windowed processing or memory intensive neuralnetwork computations are not likely candidates for real-time implantable devices due to hardware power andtiming constraints. A brief summary comparing estimatedand reported power consumption by published attempts atimplantable devices is presented in the results section ofthis work. A recent study reports that an ANN that is fedunprocessed neural data performs just as well as a trainednetwork that is fed with features selected from a groupof published algorithms [26]. It is therefore unclear ifcomputational complexity relates to significant increases inalgorithmic efficiency. Metrics such as energy [27], line length[28], variance energy [27], spectral power [22], dominantfrequency and wave duration [29], and wavelet scale [30] haveall been explored and reported to be promising tools aiding thedetection of seizures with varying amounts of efficacy.

We propose to use both time and frequency informationcombined with the amplitude of recorded LFP data fromthe hippocampal focus to distinguish between seizure andbaseline states. By combining hardware aspects to the normaldesign process, we statistically demonstrate a quantitativethreshold setting mechanism that would help enable cliniciansto optimally tune the algorithm on a case-by-case basis. Theimportance of quantifying the procedure to set thresholds fora designed algorithm has been stressed in the past as it directlyrelates to the efficacy of the algorithm [12, 22]. Commonmetrics such as false positives and detection sensitivity arerelated to hardware metrics such as power consumption anddetection latency. The designed algorithm can be implementedusing ultra-low-power digital CMOS circuits on a microchip.Such a microchip can easily interface with reported multi-channel neural recording arrays [31]. Circuit simulationsindicate that the device can operate at continuous power-consumption levels as low as 350 nW (180 nm SOI process),strongly implicating extended battery life. The algorithm isdesigned to operate on local field potential data recorded fromdepth electrodes implanted in the epileptic focus, typically inproximity to the hippocampus. The process of customizing thealgorithm relies on a statistical analysis presented in the paperthat uses kainate-treated rat LFP data to validate results. As a

proof of working principle, the algorithm is implemented on aprinted circuit board with commercially available componentsand tested in a simulated real-time environment to mimic atypical prospective study on six implanted animals.

3. Algorithm design

The detection of electrographic seizures is based on classifyingdepth-electrode data into ‘events’. The definition of anevent is in relation to its amplitude during its seizure statecompared to normal or baseline recordings. A referencewith baseline is established to avoid excessive false detectionsdue to a fluctuation in the DC level of the recorded signalor noise artifacts that tend to change the overall amplitudeof recordings for longer periods of time. The baseline isperiodically updated to track these changes by a medianfiltering mechanism sampled at low rates (<20 Hz). Thiswould track changes under 10 Hz and reduce the probabilityof recording high-frequency activity such as ripples or spikesthat could result in an inaccurate representation of baselineaverage amplitude. Any activity over a proportionalityconstant (Kamp) times the baseline average is consideredand time stamped as an event by an event-marker block.Once time stamped, a digital feature extraction block utilizesthese markers to indirectly extract frequency information bymeasuring the interval between consecutive time stamps. Thenext block compares the measured inter-event intervals (IEIs)to a programmable threshold (IEIthresh), screening out pairs ofevents that do not meet the threshold. A detection based just onsporadic high-amplitude spiking activity could increase falsepositives significantly. In order to increase the selectivityof the algorithm, the hardware incorporates a measure ofrhythmicity into its detection mechanism in the next stage.This final stage looks for consecutive occurrences of theflagged pairs of events that are separated by a time intervalless than or equal to the programmed IEI threshold. In otherwords, any sustained rhythmic high-amplitude activity thatincreases the instantaneous signal energy in the frequencydomain of interest is marked as a detection. The numberof consecutive pairs of events (Nstage) that trigger detectioncan also be digitally programmed post-implantation followingthe methods outlined in the later sections of this paper. Thisflow of events is illustrated by the flowchart shown in figure 2.

3.1. Event marking and digitization

Recorded data from the implanted microelectrodes are firstfiltered and then amplified by an integrated neural recordingamplifier (TDT Systems Inc.). The filtering splits full-bandwidth signal into a low-frequency component (<10 Hz)and an LFP component (10–500 Hz). The low-frequencycomponent is used to periodically update the averaged baselineamplitude to keep the thresholds dynamic with respect to anysustained drift in signal amplitudes. In this study, the baselineaverage was not observed to change significantly as durationsof data used to test the hardware were less than 1 h each.The proposed scheme to update the background (baseline)

3

Page 4: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

Figure 2. Flowchart representing the operation stages of thealgorithm.

amplitude would prove useful with long-term evaluationstudies of the implanted algorithm, with sleep-wake cyclesincluded. The algorithm uses only the LFP component ofthe data, digitizing it right after amplification. The amplifierfilter configuration is a standard part of most neural recordingsystems in use today, and is not specific to the algorithm [32].The digitizing is implemented by comparing the conditioneddata to the threshold amplitude that is a certain proportionalityconstant (Kamp) times the averaged baseline (equations (1a)and (1b)):

Event threshold = Kamp ∗ {baseline average} (1a)

yk = n|xn > event threshold. (1b)

In equation (1b), k represents the index of the array of identifiedevents and xn represents the nth sample of data. A source-follower-based architecture was used to implement an op-amp comparator in the open loop configuration to effect thisoperation in hardware. This 1-bit analog to digital converteracts to timestamp any activity over the threshold as an event.Alternatively, a digital implementation using a Schmitt triggermay also be used to establish this.

3.2. Measurement of an inter-event interval

The next stage in the algorithm utilizes the timestampsextracted from LFP data to measure the time intervalbetween two consecutive events in real time without storinginformation. The measured IEI is immediately compared to aprogrammable threshold and flagged only if it is less than thatvalue. Other events that are spaced further apart from eachother are ignored and not added to the queue of flagged eventpairs:

IEI(k) = yk − yk−1 (2a)

Nstage ={Nstage + 1|IEI(n) < IEIthresh

0 |IEI(n) > IEIthresh.(2b)

In digital hardware, this is established by using a binary counterthat is triggered on and off by the event timestamps. Thebinary value of the counter is compared to a programmed IEIthreshold set by the clinician following methods documentedlater in this paper, and a queue of successive events (Nstage)is incremented if the pair of events meets this criterion. Thecounter is clocked by a fixed frequency clock, enabling easyconversion of time to programmable digital values that arethen compared to the threshold using a digital comparator atthe end of the count cycle. The counter is then reset after eachcomparison cycle, and the event queue is either incremented orreset depending on the digital comparison made. In effect, thelength of the queue represents the number of consecutive pairsof events that have been flagged by the IEI extraction blockand that fail to meet the minimum IEI threshold criteria. Thearchitecture makes the algorithm iterative till the desired queuelength has been reached at which point a detection is made.This flow of events is illustrated in the circuit implementationshown in figure 3.

3.3. Hardware implementation

The digital implementation of this function translates to anefficient, low power hardware technique to extract frequencyinformation from amplitude-screened data, and incorporates ameasure of rhythmicity by measuring the duration of sustainedhigh-energy activity. This enhances the algorithm’s selectivity.Figure 4 shows a timing diagram of typical operation ofthe circuitry. In figure 4, events are first marked out bythe output of the 1 bit ADC as per the set value of eventthreshold. In the window shown, spiking activity at the onsetof an electrographic seizure is detected as events. The digitallogic resets the master counter that keeps tab of the queueof successive events that fall below the IEI threshold. In theexample shown, seven counts were used as a threshold andthe double arrow indicates the period after which the mastercounter is reset. The digital logic takes in inputs from the IEIcounter and a feedback state machine to measure IEI betweenpairs of events. The staircase waveform shown at the bottomof figure 4 represents the length of the queue. If a thresholdof 4 (Nstage = 4) was used, the episode marked with verticalarrows would be classified a detection exactly when the fourthincrement was made. Usually, much higher values of Nstage

are employed.As is the case with most binary decision algorithms,

the choice of optimal thresholds takes utmost importance indeciding the efficiency of the technique. In the next twosections, we document the materials and methods used tocollect data and develop an optimality function that helpsarrive at a decision for choice of thresholds based on desiredselectivity, sensitivity and hardware efficiency.

4. Materials and methods

4.1. Electrode implantation

All surgical and animal handling procedures were approved bythe Purdue Animal Care and Use Committee (PACUC) priorto performing the study and adhered to the NIH guidelines

4

Page 5: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

Figure 3. Circuit implementation of the proposed seizure detection algorithm with the digital computation block marked with dottedboundary.

Figure 4. Timing diagram showing circuit operation. From top to bottom (a) recorded LFP data with the event threshold in dotted lines andevents marked, (b) clock used to measure IEI, (c) digital logic output that resets counting if IEIthresh is crossed and (d) decimal output of thecounter measuring the number of successive events that meet the IEI criteria.

for the care and use of laboratory animals. A total of tenfemale long Evans rats (250 to 350 g) were used in thisstudy. Seizure data from six of the ten animals are usedin this study after accounting for the loss of animals dueto damaged headcaps, post surgical and kainate treatmentcomplications. All procedures remained consistent for eachanimal. Anesthesia was induced via 5% isoflurane in2 L min−1 O2 and maintained using 0.5–3% isoflurane in2 L min−1 O2 [33]. Post induction, the surgical site was shavedand cleaned with alternating scrubs of dial surgical scrub andbetadine. Using a standard stereotactic frame (David KopfInstruments, Tujunga, CA, USA), a midline incision was madeand the skull was cleaned to expose lambda, bregma and theproposed craniotomy site. Three bone screw locations andthe proposed craniotomy site were marked prior to drillingwith a sterile ruler and cauterizer. To locate and accessthe dentate gyrus, a 1 mm2 craniotomy was made 3.5 mmposterior and 2.0 mm lateral to bregma via stereotaxis [34].Prior to insertion, the electrode pair was mounted on a sterilemicromanipulator and re-sterilized in a 70% ethanol in dH2Osolution. A twisted-pair two-channel stainless steel electrode(Plastics One, Roanoke, VA, USA) was inserted at ∼100–300 mm min−1 such that the exposed tips were 3.5 mm ventral

to the cortex in the dentate gyrus. The electrode assemblyconsists of two 4 mm long polyimide-insulated stainless steelelectrodes (0.280 mm diameter with insulation) in a twisted-pair configuration with a separate uninsulated, stainless steelground/reference wire. Kwik-Cast silicone elastomer (WorldPrecision Instruments, Inc., Sarasota, FL, USA) was usedto cover the remaining exposed cortex followed by a liberalapplication of standard dental cement to cover the remainingexposed, pre-cleaned skull surface [35].

4.2. Kainic acid treatment

Kainate-treated rats were used as models of human temporal-lobe epilepsy in this study [36]. Each treatment wasadministered 15+ days post-implantation. Immediatelyprior to the kainate treatment, baseline local field potential(LFP) recordings (bandpass filtered from 10 Hz to 500 Hz)and video were obtained using a TDT System3 recordingsystem (Tucker–Davis Technologies, Alachua, FL, USA)and Quickcam camera (Logitech, Fremont, CA). Full detailsof the kainate treatment protocol are found in [36]. Inbrief, each implanted rat was intra-peritoneally injected with5 mg kg−1 kainic acid (AscentTM Scientific, Princeton, NJ,

5

Page 6: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

USA) hourly, until it reached a state of convulsive statusepilepticus. LFP recordings were obtained along with videofootage between each of four to six administered injections.Seizures were then marked out by visual inspection of data andcorresponding video. A team of neurologists at the IndianaUniversity School of Medicine (Indianapolis, IN, USA) thenverified the identified seizure patterns and marked onset times.

4.3. Hardware testing and real-time environment simulation

The recorded data were streamed out in real time at the samerate it was recorded (1526 Hz) through a data acquisitionsystem (National Instruments, USA) interfaced to a desktopcomputer. No further processing was done on data apart fromfiltering and amplification implemented in hardware during therecording process. All results reported were recorded fromthis prototyped hardware device with the a priori recordeddata re-streamed in at the same rate to mimic a real-timeenvironment. This technique was structured to closely mimica true real-time prospective environment that the algorithmwould typically be used in. The data used to test the algorithmwere separated from the data analyzed in software to train themodel and set thresholds. The detection algorithm prototypewas implemented on a printed circuit board following thecircuit diagram (figure 3) using commercially available digitalcircuit components and interfaced to an input channel ofthe data acquisition device. The outputs from the hardwarewere processed using Matlab R© (Mathworks Inc.) to computemetrics to quantify algorithm performance.

4.4. Seizure screening and analysis

Each implanted animal underwent treatment of kainic acid asper the protocol till a convulsive state of status epilepticus wasattained. A total of 125 seizures were marked out from sixtreated animals. This included both subclinical and clinicalseizures scored on a racine scale of 1 through 5. Seizure onsetwas identified by visual inspection of electrographic and videorecords by a trained epileptologist at the Indiana UniversitySchool of Medicine, Indianapolis. This was supplemented bymarking out the first point at which the electrographic spikingactivity exhibited a sharp increase in instantaneous energy witha period of gradual amplitude increase. Seizures marked outhad an average duration of 65 s with a standard deviationof 27 s. In this study, no sleep-wake cycle experimentswere performed, and all data used were obtained during thecourse of progression of the animal into chemically inducedstatus epilepticus. As a result, there were no long inter-ictal periods. The designed algorithm does not assume anymorphology or specific seizure pattern, making it more genericand widely applicable to the electrographic data that exhibiteda combination of features including increased amplitude,sustained spiking and high-frequency activity. A set of 3–5seizures and about 15 min of baseline activity was used toextract the thresholds for each animal in the study. Recordeddata were streamed out as is into the hardware prototype exceptfor parts where excessive cable motion artifact was noted, orparts where the animal was in a convulsive state of statusepilepticus, with no clear demarcation between the end of one

Figure 5. (Top) an example of smoothing filter applied to removehigh-frequency noise, and (bottom) events marked out with dots in atypical window of data for a set threshold.

ictal event and the start of another. Typical data segmentlengths varied from 10 to 25 min. Longer continuous dataintervals were used to quantify false positive rates with 20–45 min baseline recordings for each animal.

Commonly observed artifacts in the recorded signal weremainly due to cable motion and other physical movementsuch as wet dog shakes, chewing, grooming and cable touchduring which period the cable had to be re-connected to theheadcap. Electrical noise was notched out using a 60 Hzfilter and all cables were sufficiently shielded and groundedwith minimal exposure. The Nstage threshold had a fairlystrong control over any false triggers due to these artifacts.However, any high-amplitude artifact in the frequency domainof a seizure that sustained for periods over 3–6 s caused a falsedetection. These were logged and included in the calculationsof algorithmic sensitivity and selectivity. Long-term shiftsin the baseline amplitude due to impedance changes in theelectrode–tissue interface are accounted for by the relation ofevent threshold (Kamp) to the background amplitude averagedusing a median filter. Video records were used to verify anyfalse detection due to such a motion artifact. Figure 5 (top)shows a typical filtering scheme applied to the data to smoothout high-frequency activity that would cause multiple eventtriggers and (bottom) with events marked out on the data usingdots.

In order to set thresholds to train the algorithm, threeto five randomly selected seizures from each animal andan equivalent duration of baseline were used to create thenumerical model as elaborated in section 5. These seizureswere excluded from the testing data set.

6

Page 7: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

Figure 6. Log-normal distribution fit for IEI values obtained withdifferent values of event threshold. The dotted line marks a typicalchosen boundary.

5. Metrics and data analysis

The efficacy of the proposed algorithm is strongly dependenton the choice of the threshold values (Kamp, IEIthresh andNstage) used to detect increase in amplitude, frequency andrhythmicity in the seizure phase. Hence, optimal choice ofthese parameters assumes paramount importance in order toco-optimize the algorithm and hardware in terms of detectionlatency, power consumption and number of false positives (FP)and false negatives (FN). As most algorithms need patient-specific programming, a general framework is essential tooptimize this process, reporting its trade-offs at each step.In this section, we describe in detail the process of thresholdsetting for the proposed algorithm, based on statistical analysisof neural recordings.

The threshold setting process is based on the distributionsof IEI obtained for different values of Kamp. As discussed in theprevious sections, Kamp times the average baseline amplitude isused as the threshold for the classification of events. Once theevents are marked, intervals between pairs of successive eventsare calculated to obtain the distribution for IEI correspondingto the chosen Kamp. For this analysis, data corresponding tothe baseline and seizure phases are considered separately andtwo IEI distributions are obtained.

The distribution of IEI data points is highly dependenton the choice of Kamp. Choosing a value of Kamp changesthe number of events identified in each state, and also theintervals between them. The IEI resulting from a particularKamp selection resulted in a log-normal distribution, shownin figure 6. The baseline distribution shows an increasedstandard deviation with an increase in Kamp as fewer eventsare detected with a higher threshold. The seizure distributiontends to get sharper and the two distributions start overlappinglesser with each increase in Kamp, potentially leading toreduction in false positives. The trend indicates that thebaseline and seizure IEI distributions start to disperse awayfrom each other with an increasing Kamp. While this is true,the graph does not capture another trade-off that this increasein Kamp results in false negatives and detection delay. Anexcessively high value of Kamp results in a high probabilityof entirely missing certain electrographic seizure events,increasing false negatives. Therefore, there is a strong needto optimize the choice of these thresholds, taking into account

Figure 7. Progression of IEI from baseline into seizure indicatingthe location of two points on an IEI distribution of specifically theseizure event with reference to their temporal position.

the different trade-offs. Metrics of interest—detection delay,power consumption and number of false positives/negatives—are related qualitatively to cumulative distribution functions(CDFs) of IEI in the baseline and seizure phases. These trade-offs are captured by the distributions of IEI in the baseline andseizure phases resulting from each selection of threshold.

We first discuss briefly how detection delay and numberof false negatives are related to the threshold parametersand CDF of IEI in the seizure phase (denoted, hereafter,by CDFseiz(IEI)). This is followed by a discussion of thedependence of hardware power consumption and numberof false positives on the CDF of IEI in the baseline phase(CDFbase(IEI)). The trade-offs involved at each step are alsodescribed to finally choose optimal values of the thresholdparameters based on the weighted average of CDFbase(IEI)and CDFseiz(IEI).

5.1. Number of false negatives and detection delay

If a seizure is detected beyond a certain point in time,therapeutic intervention may be ineffective. In this analysis,we focus on detection of the tonic phase of the electrographicevent and classify any detection beyond half the duration ofthe seizure as a miss, or false negative. Detection delay isdefined as the time interval between electrographic onset (EO)of the seizure and the algorithm triggering seizure detection.Electrographic onset was defined as discussed in section 4.4.The detection delay is actually a sum of the inherent delayof the algorithm and the delay due to hardware components(equation (3)):

Detection delay = (Algorithm delay + Circuit delay)

∼= Algorithm delay|LF. (3)

At the low frequency (LF) of operation that the applicationneeds, the delay added by the hardware is of the order ofnanoseconds (ns), and is neglected. In effect, the hardwareacts as a real-time implementation of the designed algorithm.

Relation with CDFseiz(IEI). In order to understand therelation between detection delay and IEIthresh, IEI is plotted onthe same timescale as a recorded baseline event progressinginto a seizure, as shown in figure 7. The averaged IEI duringan ictal event is much lower than in baseline. The generaltrend of IEI is captured by the median plotted from raw datapoints averaged using a rectangular window (figure 7). Thearrow indicates the electrographic onset, which is captured by

7

Page 8: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

a significant dip in the overall IEI values recorded for a givenvalue of Kamp.

If the ictal event in figure 7 is snipped out and the logarithmof IEI is plotted using a normal fit, the right-hand side of thedistribution (point A) corresponds to higher IEI values, foundduring the starting phases of the electrographic event, or thetonic part. The lower values of IEI on the left-hand side ofthe normal distribution (point B) represent clonic parts of theseizure. This trend agrees with what has been reported inthe literature to be the progression of a typical electrographicseizure [13, 16]. Choosing a point on the IEI distribution,indirectly reflects the detection delay. If point A was chosenas the IEI threshold, the seizure event would be detected in itstonic build-up stages (shown by the arrow marking point A).Moving the IEI threshold to the left of point A on the normaldistribution implies that the seizure will be detected at a laterstage of its inception—increasing detection delay. Detectiondelay and number of false negatives are, thus, incorporated intothe optimization process by using (1−CDFseiz(IEIthresh)) as themeasure, which is the area under the probability distributionof IEI to the right of IEIthresh marked with dotted lines(figure 6).

5.2. Number of false positives and hardware powerconsumption

In implantable applications, power dissipated by the hardwareis one of the most important factors that decide both batterylife and the heat dissipated into the surrounding tissue.Peukert’s equation relates power dissipated to the chargecapacity of a given battery cell in terms of its discharge time,indicative of battery life [37]. In equation (4), ‘k’ representsthe dimensionless Peukert’s exponent and ‘V’ refers to theoperating voltage needed for the device:

Charge capacity (Q)=[Ptotal

V

]k

∗ Discharge time (t). (4)

The power dissipated by digital circuits is composed of thesum of a static and a dynamic component. While the staticpower consumption is dominated by the leakage current ofthe circuits, its dynamic component is related to the supplyvoltage (VDD), clocking frequency (f ) and the capacitive loadof the circuit seen by the clock (CL) [38]. These relationshipsare described in equations (equations (5)–(6)):

Ptotal = Pstatic + Pdynamic (5)

Pstatic = VDD ∗ IOFF;Pdynamic = α ∗ V 2DD ∗ CL ∗ f.s. (6)

While the algorithmic thresholds have no effect on the supplyvoltage, capacitive load or clock frequency, they affect thenumber of detected events contributing to increased switchingactivity (α), and hence an increased dynamic power component(Pdynamic). It may be observed that switching activity increaseswith increase in the number of (a) events marked, leading toincreased switching at the output of the voltage comparator(figure 3) and (b) pair of events with IEI < IEIthresh, leadingthe increased switching in the master counter and at the clockpin of the IEI counter (figure 3). While switching in theseizure phase is inevitable for detection of the seizure, power

consumption can be minimized by reducing the switchingactivity in the baseline phase. Hence, in this analysis,optimization of power is considered by analyzing the baselinedata only.

In order to relate hardware power consumption andnumber of false positives with a common parameter, we definefalse hit (FH) to be the classification of a pair of events withIEI < IEIthresh outside the seizure episode. Hence, from thediscussion above, hardware power consumption is directlyproportional to the number of false hits. Furthermore, a falsepositive is defined as Nstage consecutive occurrences of falsehits.

Relation with CDFbase(IEI). The baseline IEI is distributedlog normally for any selected value of Kamp. Given a valueof IEIthresh, the area under the IEI baseline distribution to theright of IEIthresh (figure 7) is indicative of the percentage ofevents whose IEI > IEIthresh and hence will not be flagged.Similarly, the area under the IEI baseline distribution to theleft of IEIthresh, which is the CDFbase(IEIthresh), represents thepercentage of events classified as false hits. This is a goodmeasure of the power consumption as well as the number offalse positives.

5.3. Summary of relationships

The trade-offs associated with the thresholds can besummarized by the following equations:

IEIthresh ∝ (Pdynamic, FH)k1

(Detection delay)k2(7)

Kamp ∝ (Detection delay)k3

(Pdynamic, FH)k4. (8)

Here, k1 through k4 are constants determining the exactdependence of the performance metrics on the thresholdparameters. Their values may be different for differentpatients. For this analysis, the exact values of these constantsare not required since the optimization is performed on thebasis of CDFs of IEI, as discussed in the subsequent sub-section.

5.4. The optimality function

As described in the previous sub-sections, given a value forKamp, detection delay and number of false negatives can bereduced by choosing IEIthresh, so that (1−CDFseiz(IEIthresh))is decreased. Similarly, hardware power consumption andnumber of false hits can be reduced by choosing IEIthresh

that lowers CDFbase(IEIthresh). These two requirements haveconflicting implications on IEIthresh. Hence, there exists anoptimal value of IEIthresh such that the weighted combinationof these sets of metrics is minimized. For that, we define anoptimization function O(f ) (equation (9)):

O(f ) = ws

ws + wb

∗ Missseizure +wb

ws + wb

∗ Hitbase (9a)

Missseizure = CDFbase(IEI); Hitbase = 1 − CDFseizure(IEI).

(9b)

8

Page 9: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

Figure 8. Optimality function predicting values of thresholds to beused with a given training set of data.

In equation (9), Ws and Wb represent the relative weights of hitsin the seizure and baseline distributions, respectively. The ratio(Ws/Wb) indicates the relative importance of detection delayover false hits and hardware power dissipation. We obtain theminimum value of O(f ) and corresponding IEIthresh (IEIopt) fora given value of Kamp. This process is re-iterated for differentvalues of Kamp, and the optimal O(f ) and IEIthresh is obtained asa function of the Kamp. Figure 8 shows a plot of optimal O(f )versus Kamp, from which the minimal value of optimal O(f ) ismarked out and is used to obtain the optimal values for Kamp

and IEIthresh. This analysis optimizes the range of operationto be chosen for the most efficient hardware performance,taking into account false hits and detection delay. In orderto improve the selectivity, Nstage is increased till the desiredresults are obtained, keeping in mind that detection delay alsoincreases. It is to be noted that the above detailed procedureis applied on the training data set isolated from each animal toset thresholds to be used on an exclusive testing set from thesame animal.

6. Results

The hardware prototype used the predicted values of Kamp andIEIthresh and implemented nine stages (Nstage = 9) to producethe tabulated results. Setting equal weights to Hitsbase andHitsseizure results in a range for Kamp similar to the analysisshown in the figure 8 for a given set of data. In order to

Figure 9. ROC plot predicting the same results as that obtained from the optimality function.

validate this finding with a standard basis of comparison, weapply receiver operating characteristic (ROC) analysis to thesystem [39]. The algorithm may be classified as a binary statemachine, programmed to detect and differentiate between twoset states (seizure and non-seizure).

The IEI distributions for a number of baseline and seizuresnips for the same animal were analyzed for different valuesof Kamp. The difference between the cumulative distributionfunctions of the baseline and seizure snips was used as a metricfor demarcation. At every point on this curve, the baselineCDF value is marked as a ‘false hit’ and the seizure CDF valueis marked as ‘true hit’. These are plotted against each otherfor the same data file, sweeping values of Kamp. Figure 9shows that without assigning priorities for false hits overmisses or vice versa, the optimal range of Kamp is the same asthat predicted by the optimal function analysis. The ROC plots,however, do not provide any information about the IEIthresh tobe chosen for predicted Kamp values. The proposed analysisgives an estimate of the range of threshold values to be used inthe algorithm based on statistical analysis of limited availabledata.

A hardware implementation of the described algorithmwas fabricated on a printed circuit board with commerciallyavailable digital circuit blocks. False hits were logged foreach pair of events that was flagged by the hardware inthe baseline phases, and detection delay was measured inthe seizure phases. Figure 10 summarizes the relationshipbetween false hits, detection delay and chosen value of eventthreshold (top) and IEIthresh (bottom). The curves are indicativeof the relationship predicted by equations (7)–(8).

In the full implementation of the seizure-detectionalgorithm, a queue length of 9–16 stages was used (Nstage =9–16). Increasing this metric was found to significantlydecrease the number of false positives in detection andmarginally increase detection delay for low values of Nstage

(under 30). The clinician is given the flexibility to programthe hardware to the desired number of stages based on theobserved false positive rate from training data as a coarsecontrol mechanism. The results reported in table 1 wereobtained using a hardware prototype programmed to thethresholds prescribed in the optimization process. A smallsubset of each animal’s data was used to generate specificthresholds and these were tested using untrained data from the

9

Page 10: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

Table 1. Results from hardware implementation tested on real-time depth electrode data.

Total No of AverageID Kamp seizures segments duration (min) Detections FP FN SEL SEN

1 5 18 4 22 16 2 2 0.889 0.8892 4 22 5 18 21 3 1 0.875 0.9553 6 15 8 16 14 2 1 0.875 0.9344 4 18 8 20 17 1 1 0.944 0.9445 4 17 6 12 17 3 0 0.850 1.0006 5 19 12 13 19 2 0 0.904 1.000

Inter-ictal bursts detected were counted false positives when the duration was less than 5 s.

Figure 10. (Top) plot showing measured false hits (FH) anddetection delay plotted against various values of Kamp for a fixedvalue of IEIthresh, and (bottom) plot of the same two metrics againstIEIthresh for a fixed value of Kamp.

same animal. All results reported in table 1 were obtainedusing the simulated real-time environment from the segmentsof continuous data that excluded the training seizures andbaseline. The data were segmented as discussed in section 4,and longer continuous segments were used to test FP rateon baseline data. The average duration of the continuoussegments used is also reported in the table. The algorithmperformed with an average sensitivity and selectivity of 95.3%with 95% confidence intervals [90.8%, 99.9%] and 88.9% with95% confidence intervals [85.5%, 92.4%], respectively. Thedefinitions for selectivity and sensitivity were adopted from[26]. Selectivity was defined as the ratio of the number ofcorrect detections to the total number of detections and falsepositives, indicating a measure of rejection of false positives.Sensitivity was calculated as the ratio of number of correctdetections to the total number of detections and false negatives,indicating a measure of the algorithm to detect seizure activityfrom baseline.

An important parameter deciding the feasibility of thepresented algorithm in a closed-loop prosthesis is detection

Figure 11. Measured seizure detection delay variation both withinand between animals.

delay. As discussed in section 5b, we defined detectiondelay as the time interval between electrographic onset ofthe seizure and when the algorithm triggered a detection.Although it is unclear at what point interventional therapysuch as neurostimulation could work effectively, we defineda false negative as any detection with a delay greater thanhalf the duration of the electrographic seizure. In otherwords, if a detection was not made within 50% of the seizureduration (within the tonic part), it was considered a miss.Figure 11 shows the measured detection delays from each ofthe implanted animals along with their median values. Thealgorithm had an overall average detection delay of 8.5 s[5.97, 11.04] with a standard deviation of 6.85 s. The largestandard deviation was due to differences in a clear definitionof electrographic onset and also due to animal to animalvariations in the progression of a seizure event.

Efficient hardware implementation is one of the keygoals of this study. Although there have been very fewreported detection or prediction algorithms with hardwareimplementation on a custom circuit with power numbers,we compare our hardware power numbers to commonlyused hardware cores in devices. For the purpose of thisstudy, we compare our work to typical power consumptionof a TIC320X DSP processor, TI320 Floating point DSPprocessor(TI320FP), integrated neural recording system(INI3) [31], VLSI implementation of a wavelet engine(DWT) [40], an analog filtering scheme presented foruse with the Flint Hills Scientific (FHS) seizure-detectionalgorithm [41]. Typical active power consumption numberswere used wherever reported (figure 12) and technicalspecification datasheets were used to report numbers for themicroprocessors and DSPs.

10

Page 11: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

Figure 12. Comparison of power consumption of commonly usedcircuit systems to implement seizure detection/prediction algorithmswith the algorithm presented in this work.

The authors of the FHS algorithm, however, do not reportany circuit implementations, process node or architecturesto back up the expected power numbers for an analog FIRfilter proposed. DSPs are commonly used to implementcomputationally intense seizure detection schemes such asartificial neural networks. Devices such as the responsiveneurostimulation system (eRNS) from Neuropace Inc. reportusing a microcontroller to implement the algorithm [42]. Wereport a power consumption of 350 nW from a 250 mVsupply for a fully CMOS sub-threshold implementation ofthe proposed circuit architecture. The power reported is perchannel of use. Given that the frequency of operation of thesystem is very low, we are able to operate the circuits withsupply voltages as low as 250 mV (from simulations on theMIT SOI 180 nm process). The proposed architecture is ordersof magnitude lower in current draw from a same given batterysource, implying much longer intervals between recharges.

7. Discussion

The proposed detection algorithm has been shown to detectthe onset of electrographic seizures in real time using dataavailable from implanted microelectrodes in the epilepticfocus of rats. Although there is enough evidence in theliterature that validates using a detection scheme at the focusto suppress seizures before they spread to other regions inthe brain, it is unclear what range of detection delays wouldbe optimal [17, 20, 21]. The definition of detection delay isalso contingent on a clear, concise definition of electrographiconset of the seizure. The presented algorithm balancescomputational complexity with feasibility in an implantableapplication to facilitate the design of a closed-loop system. Asdiscussed in section 4.4, the algorithm is susceptible to falsetriggers with sustained high-amplitude high-frequency artifact,and this limitation is commonly observed in a number ofreported detection schemes [13, 16]. Integrating the proposedhardware with a wavelet-based filtering scheme could increaseits selectivity, but it remains to be seen if the increase inefficiency warrants the increase in computational power due tothis addition. In this study, we simulate a real-time prospectiveenvironment to test the algorithm on hardware instead ofevaluation in software, although the data were recordeda priori. This is established by streaming the recorded data

Figure 13. (Top) hardware output showing detections marked withdotted lines over a 20 min window and (bottom) inter-ictal burstingthat was detected and counted as false positive.

(excluding training segments) to the hardware prototype withno additional software processing at the same rate at which itwas acquired. While using untrained data mimics a real-timeprospective environment, the actual microchip implementationwould allow a true long-term prospective evaluation of thealgorithm.

The results presented in table 1 indicate the performanceof the hardware using data recorded from implanted animalsin various stages of progression into status epilepticus. Anydetection with a delay greater than half the duration of theseizure was considered a false negative, as we targeted theinitial tonic phases for detection. The false negatives reportedfollow this convention, even though the hardware was ableto detect all electrographic seizures. There is also a fairvariability in the detection delay both within and betweenanimals. Figure 11 shows animals 2 and 6 with a widerdelay distribution compared to the others. This is believedto be due to the poor signal to noise ratio in the qualityof recordings obtained from the specific subject, causingthe optimization process to report much different thresholdsthan other subjects. There was no subjective intervention toalter these numbers and the experiments were performed asper the prescribed thresholds obtained from the optimizationprocess. Figure 13 (top) shows a typical progression ofthree seizures that are detected with no false positives ormisses by the hardware. In certain cases, inter-ictal bursts ofhigh-amplitude high-frequency activity were detected by thehardware as shown in figure 13 (bottom). Activity that wassustained for periods over 5 s and consisted of high-frequencyrhythmic patterns was detected by the hardware. For thepurposes of this classification, such detections were loggedas false positives, although it is unclear if these electrographicabnormalities warrant intervention. While the preliminary

11

Page 12: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

evaluations of the presented algorithm’s efficacy analyzed onthe limited dataset show great promise, it is important toevaluate these metrics with longer durations of continuousdata that include sleep-wake cycles and sufficiently long inter-ictal periods. A large animal study with continuous monitoringis currently underway to perform this evaluation. Evaluationstudies performed on the Neuropace device also report thatthe algorithms trigger a lot more detections during ‘sleep’phase than during the ‘awake’ phase. This finding is alsostrengthened by an observation that high-amplitude short-duration patterns of spontaneous electrical activity (populationspikes) have been reported to follow a circadian rhythm in ananimal model of temporal-lobe epilepsy [43].

The techniques presented in this paper enable a low-power hardware implementation that facilitates such long-term monitoring. The results presented in this work openup avenues for integrating seizure-detection algorithms withhardware design and optimizing the system to be feasible inan implantable prosthesis. The proposed circuit architecturecan also be combined with any custom circuit implementationof a multi-channel neural recording device at almost noadditional cost of power. Such a device would enableresearchers to accurately identify and track the path of aseizure away from its epileptic focus, in turn equipping themwith answers to the questions surrounding when and where tostimulate. Multi-channel neural recording systems equippedwith efficient detection schemes reduce the data bandwidthload on transmission schemes from these systems by onlytransmitting detections as opposed to digitized neural data.This would aid in long-term studies to understand the temporaldynamics of a seizure event to increase the temporal selectivityof intervention.

In order to facilitate the development of closed-loopimplantable devices, it is important to consider the prescribedtrade-offs. In the past there have been reports of suchcomputational trade-offs in order to facilitate hardwareimplementation [28, 44]. The Neuropace (eRNS) deviceis the only known implantable responsive neurostimulationsystem and the authors report using similar computationallyefficient tools such as half wave [45], area under curve [27]and line length [28]. The presented algorithm takes intoaccount amplitude, frequency and rhythmicity while alsoproviding programmability and easy means to interface withother application-specific integrated circuits to better studyand treat the dynamics of epilepsy.

Acknowledgments

This work was supported by funding in part from the WallaceH Coulter Foundation and Cyberonics Inc. The authors wouldlike to thank Dr Edward Bartlett for the use of data acquisitionsetup and Casey Ellison, Adam Petersohn and NeophytosPalletas for performing the surgeries and implantation ofelectrodes. We acknowledge the services of our clinicalcollaborators at the Indiana University School of Medicinein validating and marking seizures from the recorded data (DrDragos Sabao and Dr Michael Veronesi). We also thank thereviewers for their valuable feedback and inputs.

References

[1] Begley C E et al 2000 The cost o f epilepsy in the UnitedStates: an estimate from population-based clinical andsurvey data Epilepsia 41 342–51

[2] Labar D, Murphy J and Tecoma E 1999 Vagus nervestimulation for medication-resistant generalized epilepsyNeurology 52 1510–2

[3] Graves N M and Fisher R S 2005 Neurostimulation forepilepsy, including a pilot study of anterior nucleusstimulation Clin. Neurosurg. 52 127–34

[4] Ghai R S, Bikson M and Durand D M 2000 Effects of appliedelectric fields on low-calcium epileptiform activity in theCA1 region of rat hippocampal slices J. Neurophysiol.84 274–80

[5] Velasco M, Velasco F, Velasco A L, Boleaga B, Jimenez F,Brito F and Marquez I 2000 Subacute electrical stimulationof the hippocampus blocks intractable temporal lobeseizures and paroxysmal EEG activities Epilepsia41 158–69

[6] Osorio I, Frei M G, Manly B F, Sunderam S, Bhavaraju N Cand Wilkinson S B 2001 An introduction to contingent(closed-loop) brain electrical stimulation for seizureblockage, to ultra-short-term clinical trials, and tomultidimensional statistical analysis of therapeutic efficacyJ. Clin. Neurophysiol. 18 533–44

[7] Bergey G K et al 2008 Implementation of an externalresponsive neurostimulator system (eRNS) in patients withintractable epilepsy undergoing intracranial seizuremonitoring Proc. Annual Meeting of American EpilepsySociety (AES) (Seattle, WA, 2008)

[8] Politsky J M, Estellar R, Murro A M, Smith J R, Ray P,Park Y D and Morrell M J 2005 Effects of electricalstimulation paradigm on seizure frequency in medicallyintractable partial seizure patients with a craniallyimplanted responsive cortical neurostimulator Proc. AnnualMeeting of American Epilepsy Society (AES) (2005)

[9] Psatta D M 1983 Control of chronic experimental temporallobe epilepsy by feedback caudatum stimulations Epilepsia24 444–54

[10] Tang H M, Mirowski P, Baptiste S L, Devinsky O,Kuzniecky R I and Ludvig N 2008 Evidence for increasedneuronal electrophysiological activity before EEG seizureonset in the rat neocortical seizure focus (abstract)Epilepsia 49 382

[11] Brazier M A 1972 Spread of seizure discharge in epilepsy:anatomical and electrophysiological considerations Exp.Neurol. 36 263–72

[12] Mormann F, Andrzejak R G, Elger C E and Lehnertz K 2007Seizure prediction: the long and winding road Brain130 314–33

[13] White A M, Williams P A, Ferraro D J, Clark S, Kadam S D,Dudek F E and Staley K J 2006 Efficient unsupervisedalgorithms for the detection of seizures in continuous EEGrecordings from rats after brain injury J. Neurosci. Methods152 255–66

[14] Spanedda F, Cendes F and Gotman J 1997 Relations betweenEEG seizure morphology, interhemispheric spread, andmesial temporal atrophy in bitemporal epilepsy Epilepsia38 1300–14

[15] Spencer S S, Guimaraes P, Katz A, Kim J and Spencer D 1992Morphological patterns of seizures recorded intracraniallyEpilepsia 33 537–45

[16] Osorio I, Frei M G and Wilkinson S B 1998 Real-timeautomated detection and quantitative analysis of seizuresand short-term prediction of clinical onset Epilepsia39 615–27

[17] Milton J and Jung P 2003 Epilepsy as a Dynamic Disease(Berlin: Springer)

12

Page 13: The design and hardware implementation of a low-power real ... · J. Neural Eng. 6 (2009) 056005 S Raghunathan et al overall stimulus delivery over time and thus the likelihood of

J. Neural Eng. 6 (2009) 056005 S Raghunathan et al

[18] Iragui V J and McCutchen C B 1991 Self-abatement of simplepartial epileptic seizures Eur. Neurol. 31 21–2

[19] Zabara J 1987 Time course of seizure control to brief repetitivestimuli Epilepsia 28 606–10

[20] Spencer S S, Williamson P D, Spencer D D and Mattson R H1987 Human hippocampal seizure spread studied by depthand subdural recording: the hippocampal commissureEpilepsia 28 479–89

[21] Litt B, D’Allesandro M, Esteller R, Echauz Jand Vachtsevanos G Translating seizure detection,prediction and brain stimulation into implantable devicesfor epilepsy Proc. 1st Int. IEEE EMBS Conf. on NeuralEngineering (Capri Island, Italy, IEEE, 2003 pp 485–8

[22] Talathi S S, Hwang D, Spano M L, Simonotto J, Furman M D,Myers S M, Winters J T, Ditto W L and Carney P R 2008Non-parametric early seizure detection in an animal modelof temporal lobe epilepsy J. Neural Eng. 5 85–98

[23] Babb T L, Mariani E and Crandall P H 1974 An electroniccircuit for detection of EEG seizures recorded withimplanted electrodes Electroencephalogr. Clin.Neurophysiol. 37 305–8

[24] Katz M J 1988 Fractals and the analysis of waveformsComput. Biol. Med. 18 145–56

[25] Khan Y U and Gotman J 2003 Wavelet based automaticseizure detection in intracerebral electroencephalogramClin. Neurophysiol. 114 898–908

[26] Pang C C, Upton A R, Shine G and Kamath M V 2003 Acomparison of algorithms for detection of spikes in theelectroencephalogram IEEE Trans. Biomed. Eng.50 521–6

[27] Litt B, Alessandro M D, Shor R, Henry T, Pennell P, DichterM and Vachtsevanos G 2001 Epileptic seizures may beginhours in advance of clinical onset: a report of five patientsNeuron 30 51–64

[28] Esteller R, Echauz J, Tcheng T, Litt B and Pless B D Linelength: an efficient feature for seizure onset detection Proc.of the 23rd Annual EMBS International Conf. (Istanbul,Turkey, IEEE, 2001)

[29] Qu H and Gotman J 1995 A seizure warning systemfor long-term epilepsy monitoring Neurology45 2250–4

[30] Osorio I, Frei M G and Wilkinson S B 1998 Real-timeautomated detection and quantitative analysis of seizuresand short-term prediction Epilepsia 39 615–27

[31] Harrison R R 2008 The design of integrated circuits to observebrain activity Proc. IEEE 96 1203–16

[32] Jochum T, Denison T and Wolf P 2009 Integrated circuitamplifiers for multi-electrode intracortical recordingJ. Neural Eng. 6 012001

[33] Swindle M M et al 2002 Laboratory Animal Medicine (NewYork: Elsevier Academic)

[34] Paxinos G and Watson C 2005 The Rat Brain in StereotaxicCoordinates (New York: Elsevier Academic)

[35] Gardiner T W and Togth L A 1999 Stereotactic surgery andlong-term maintenance of cranial implants in researchanimals Contemp. Top. 38 56–63

[36] Hellier J L and Dudek F E 2005 Chemoconvulsant model ofchronic spontaneous seizures Curr. Protoc. Neurosci.9 1911–9

[37] Doerffel D and Sharkh S A 2006 A critical review of using thePeukert equation for determining the remaining capacity oflead-acid and lithium-ion batteries J. Power Sources155 395–400

[38] Rabaey J 1996 Digital Integrated Circuits: A DesignPerspective (Englewood Cliffs, NJ: Prentice-Hall)

[39] Altman D G 1991 Practical Statistics for Medical Research(London: Chapman and Hall)

[40] Aziz J N, Karakiewicz R, Genov R, Bardakjian B L,Derchansky M and Carlen P L 2006 Towards real-timein-implant epileptic seizure prediction Proc. 28th IEEEEMBS Ann. Int. Conf. (New York City, USA, 30 August–3September, 2006) pp 5476–9

[41] Bhavaraju N C, Frei M G and Osorio I 2006 Analog seizuredetection and performance evaluation IEEE Trans. Biomed.Eng. 53 238–245

[42] Archer S T and Pless B D 2001 Stimulation Signal Generatorfor an Implantable Device (Mountain View, CA:Neuropace)

[43] Talathi S S, Hwang D, Ditto W L, Mareci T, Sepulveda H,Spano M and Carney P R 2009 Circadian control of neuralexcitability in an animal model of temporal lobe epilepsyNeurosci. Lett. 455 145–9

[44] Sun F T, Morrell M J and Wharen R E 2008 Responsivecortical stimulation for the treatment of epilepsyNeurotherapeutics 5 68–74

[45] Gotman J 1982 Automatic recognition of epileptic seizures inthe EEG Electroencephalogr. Clin. Neurophysiol.54 530–40

13