Free, Open Source tools to Alert Carers if someone suffers an Epileptic Seizure
OpenSeizureDetector can run more than one detection algorithm at the same time. This section explains what each algorithm does and which settings you can tune.
In normal operation, the app processes incoming data in analysis cycles and then combines algorithm outputs.
flowchart TD
A[Incoming watch or data source samples] --> B[Run enabled algorithms]
B --> C1[OSD result]
B --> C2[ML result]
B --> C3[Heart Rate result]
B --> C4[Fall result]
C1 --> D[Voting strategy and timing rules]
C2 --> D
C3 --> D
C4 --> E[Fall immediate alarm override]
E --> F[Final app state: OK, WARNING, or ALARM]
D --> F
Use this as a practical guide when choosing which algorithms to enable.
| Algorithm | Main signal used | Best at detecting | Typical strengths | Typical limitations | Key settings to tune |
|---|---|---|---|---|---|
| Original OSD | Wrist accelerometer frequency pattern | Rhythmic tonic-clonic type movement | Proven and transparent logic, works well for sustained rhythmic motion | Can false-alarm on repetitive non-seizure movement (for example brushing teeth or washing dishes) | AlarmFreqMin, AlarmFreqMax, AlarmThresh, AlarmRatioThresh |
| Machine Learning (ML) | Accelerometer waveform features learned by model(s) | Complex movement patterns captured by trained models | Often better balance of sensitivity vs false alarms, supports multiple models | Depends on model quality and thresholds, may need periodic tuning | MlSeizureProbabilityThresholdPct, MlAccelStdThresholdPct, model selection |
| Heart Rate Alarms | Heart rate trend and thresholds | Abnormal heart-rate events, including rapid changes or sustained abnormal rates | Adds physiological signal independent of movement pattern | Needs reliable continuous HR source, can alarm from non-seizure causes of HR change | HRThreshMin/Max, adaptive and average window/threshold settings |
| Fall Detection | Short-window acceleration min/max event pattern | Acute fall-like events (free-fall plus impact sequence) | Fast response to sudden fall-like events | Crude by design, can false-alarm on abrupt non-fall movements | FallThreshMin, FallThreshMax, FallWindow |
flowchart TD
A[Choose data source] --> B{Garmin available?}
B -->|Yes| C[Enable OSD + ML + Heart Rate]
B -->|No| D[Enable OSD + ML]
C --> E{Fall risk concern?}
D --> E
E -->|Yes| F[Also enable Fall Detection]
E -->|No| G[Keep current set]