EEGTrust is a pediatric EEG seizure detection project with:
- data preprocessing and windowing utilities,
- deep-learning training pipelines,
- real-time inference and alerting,
- explainability helpers,
- performance and integration test scripts.
This README focuses on getting the repository running quickly and reliably.
Use Python 3.9-3.11 for best dependency compatibility.
python3 -m venv .venv
source .venv/bin/activate
pip install -U pip
pip install -r requirements.txtFor real-time-only dependencies:
pip install -r requirements_realtime.txtMost training/testing scripts expect preprocessed NumPy files in prepared_data/, for example:
prepared_data/chb01_windows.npyprepared_data/chb01_labels.npyprepared_data/chb02_windows.npyprepared_data/chb02_labels.npy
Optional helpers:
python scripts/download_data.py
python scripts/prepare_training_data.py
python scripts/prepare_training_data_v2.pyPrimary training entrypoint:
python scripts/train_with_existing_data.pySmall/smoke mode (requires prepared_data/small_windows.npy and prepared_data/small_labels.npy):
python scripts/train_with_existing_data.py smallpython scripts/run_all_tests.pyOr run individual suites:
python scripts/test_accuracy.py
python scripts/test_latency.py
python scripts/test_integration.py
python scripts/test_metadata.pypython scripts/run_realtime_detection.pyWith dashboard:
python scripts/run_realtime_with_dashboard.pyStandalone dashboard tools:
python scripts/realtime_dashboard.py
python scripts/simple_dashboard.pyEEGtrust/
├── eegtrust/ # Core package (data, model, train, inference, utils)
├── scripts/ # Training, evaluation, realtime and utility scripts
├── dashboard/ # Dashboard app code
├── requirements.txt
├── requirements_realtime.txt
├── README_REALTIME.md # Detailed realtime system docs
└── TESTING_GUIDE.md # Detailed testing docs
# Quick sanity check
python scripts/quick_test.py
# Full system test
python scripts/test_system.py
# Export ONNX
python scripts/export_onnx.pyscripts/train_with_existing_data.pyis the maintained practical training path.eegtrust/train.pycontains reusable training functions and legacy code paths; its defaultprepare_data()flow is intentionally guarded and not the primary entrypoint.
- Real-time system details:
README_REALTIME.md - Testing details and interpretation:
TESTING_GUIDE.md