University of Edinburgh
Computational models of seizure activity and brain state dynamics in epilepsy
Abstract
dc:description.abstractEpilepsy is a prevalent neurological disorder characterized by recurrent spontaneous seizures, whose occurrence varies substantially both between and within individuals. This variability is increasingly understood to be structured by underlying circadian and ultradian rhythms that modulate cortical excitability, sleep-wake dynamics, autonomic function, and emotional state. However, most computational approaches to seizure detection and prediction either ignore these temporal patterns or treat them as secondary covariates, and they are rarely designed to generalize across datasets, recording montages, species, or related physiological domains. This thesis addresses these gaps by developing computational models of circadian and ultradian rhythms in seizures that are informed by physiological considerations and integrated within a unified machine learning framework for electroencephalography (EEG) and related biosignals. The detection of seizures in EEG remains a major challenge, not only because of the complexity of the signals, but also because of their scale. Expert agreement on seizure annotations typically reaches only about 90%, and even this level of concordance is difficult to maintain over the ultra-long recordings that are increasingly common in clinical and research practice. The burden of manually inspecting many hours or days of data makes human annotation time-consuming, error-prone, and impractical for large-scale or continuous monitoring. In response to this, the thesis first develops a robust, cross-dataset seizure detection pipeline capable of operating on heterogeneous EEG recordings with minimal manual intervention. The framework accepts any appropriately annotated European data format (EDF) file and applies a standardized preprocessing chain, including a physiologically motivated re-referencing procedure that converts heterogeneous clinical montages into a consistent bipolar configuration. On this harmonized representation, multiple deep learning and classical machine learning models are trained and evaluated across several public and clinical datasets. Their outputs are combined through an ensemble voting strategy, improving robustness and reducing false alarms, particularly when models are applied to datasets that differ from those on which they were trained, and achieving performance that is competitive with state-of-the-art seizure detection methods. Having established this seizure-focused framework, the thesis next extends the computational infrastructure to sleep staging, with a particular emphasis on enabling cross-species analyses. Sleep provides a natural context in which circadian and ultradian rhythms are expressed, and sleep disruption is closely linked to seizure risk in many forms of epilepsy. To bridge human and animal work, I introduce a cross-species channel selection and mapping strategy rooted in anatomical and electrophysiological knowledge of homologous or functionally comparable brain regions in humans and rats. By defining species-agnostic channel groupings and features, the pipeline is adapted to classify sleep states in both human and rat EEG recordings. This enables systematic comparisons of model performance and feature importances across species and provides a principled route for transferring insights from high-resolution experimental models to clinical data. In doing so, the thesis demonstrates that an appropriately constrained computational model can support translational research in sleep, rather than treating human and animal recordings as fundamentally separate domains. The thesis then examines whether the same computational framework can support other EEG-based classification tasks, beginning with the detection of emotional states. Emotions manifest in subtle and distributed electrophysiological signatures that are often less pronounced and less temporally distinct than ictal events. Within the same automated preprocessing, channel handling, and model training pipeline, emotion state detection is formulated using several emotion-labeled datasets, and a set of models is trained and evaluated. This allows an assessment of how far a unified framework, originally optimized for pathological event detection, can generalize to the more nuanced and subjective domain of affective neuroscience, and it highlights task-specific limitations, such as variability in experimental design and labeling schemes. Building on these capabilities in seizure detection, sleep staging, and emotion recognition, the final strand of the thesis focuses explicitly on circadian and ultradian structure. Time-of-day and within-day phase information are incorporated to examine how seizure probability, emotional state dynamics, and sleep architecture vary over 24-hour and shorter cycles. I characterize subject-specific temporal profiles and assess the extent to which these rhythms are stable, transferable, or predictive, with particular attention to the periods preceding seizures. This integrated perspective allows the framework not only to detect events but also to situate them within the broader temporal organization of physiological state. Across these strands, the thesis delivers both methodological and physiological contributions. Methodologically, it provides a modular, extensible library for EEG-based classification that: (i) automates preprocessing and reduces montage variability through bipolar re-referencing; (ii) employs ensemble voting among diverse models for greater robustness; and (iii) supports seizure detection, emotion recognition, and sleep staging, including cross-dataset and cross-species applications, within a single coherent framework. Physiologically, it shows that explicitly modeling circadian and ultradian structure, and respecting cross-species electrophysiological organization, yields more interpretable models and reveals individual temporal signatures associated with seizure risk. By uncovering patterns in the periods leading up to seizures and relating these patterns to sleep, emotion, and biological rhythms, the work lays foundations for future precision medicine strategies in epilepsy aimed at reducing seizure burden and mitigating the risk of sudden unexpected death in epilepsy, while providing a framework that requires minimal bespoke input when applied to new subjects, datasets, or species.
Author and committee
dc:creator, dc:contributor.*- Author dc:creator
-
- Chybowski, Bartłomiej Szymon
- Advisors dc:contributor.advisor
-
- Escudero Rodriguez, Javier
- Gonzalez Sulser, Alfredo
- Wang, Shiwei
Subjects
dc:subject × 9Rights
- Licence dc:rights.license
- Language dc:language.iso
- en
Identifiers
dc:identifier.*- Identifier URI
- https://doi.org/10.7488/era/7634