This repository contains a Python script for preprocessing EEG data for seizure detection using EDF files.
Ensure you have the following installed:
- Python 3.8 or higher
- Required Python packages (see Installation)
- Dataset: Download the Seizure Epilepsy CHB-MIT EEG Dataset (Pediatric), extract it, and place it in the
datafolder inside the project directory.
-
Clone the repository:
git clone https://github.com/yourusername/EEG-Detection-CNN-LSTM.git cd EEG-Detection-CNN-LSTM/scripts -
Install required dependencies:
pip install -r requirements.txt
-
Move to scripts folder in terminal:
cd scripts
python preprocess.pypython train.pypython evaluate.pyProject/
├── data/ # Raw EEG data files (not included in the repository)
│ ├── chb01/ # Patient 1
│ ├── chb02/ # Patient 2
│ └── ...
├── processed_data/ # Preprocessed features and labels (automatically generated)
│ ├── features.npy
│ └── labels.npy
├── model/ # Saved trained models
│ └── model.h5
├── scripts/
│ ├── preprocess.py/ # Data preprocessing script
│ ├── train.py/ # Training script
│ └── evaluate.py/ # Evaluation script
└── requirements.txt # Project requirements