CardioBot - ECG Segmentation Challenge
Technical Documentation
ECG Signal Processing
The application performs real-time Peak Detection on the waveform using a Median Absolute Deviation (MAD) thresholding technique to accurately locate the Q, R, and S points. This method is a robust statistical approach for identifying outliers, which in this context are the prominent peaks of the ECG signal.
Key clinical parameters like R-Peak Sharpness (the width at half-max) are calculated to assess ventricular health. This is a measure of the duration of the QRS complex at half of its maximum amplitude.
The application also measures critical intervals such as the PR interval, QRS duration, and QT interval. These measurements are used as inputs for the AI Bot's analysis.
The Fuzzy Logic (AI Bot) Model
The Bot's decision engine uses a lightweight Fuzzy Logic Inference System implemented in JavaScript. This system is designed to mimic human-like reasoning under uncertainty.
This model converts objective measurements (like the numerical "PR Interval duration") into Linguistic Variables. For example, a PR interval of 220ms is not just a number, but can be described as having a degree of "Normal" and a degree of "Long".
The system then uses simple IF/THEN rules to process these linguistic variables. For instance, a rule might be: "IF the R-Peak is 'Wide' AND the PR Interval is 'Long', THEN the Abnormality is 'Likely'". This allows the bot to compute a final, probabilistic Abnormality Score.
Future Directions
Planned expansions for this application include full Defibrillation/Pacing Simulations to provide a more comprehensive cardiac training tool. Additionally, we aim to incorporate more complex filtering and denoising options that will be directly accessible to the user, allowing for a deeper exploration of ECG signal processing.