Anomalous: A faster approach to ECG analysis in emergency situations

The recent explosion of Big Data in the medical field has paved the way for the automatic analysis of vital signals. Currently, the majority of the diagnoses in critical situations are based on information obtained with outdated instrumentations that do not take advantage of newer technologies. 

By Ian Di Dio Lavore, Marco Di Gennaro and Luigi Fusco
Undergraduated students in Computer Science and Engineering, Politecnico di Milano

Cardiovascular diseases are the first cause of death worldwide as stated by the World Health Organization. The “Golden-Hour” in emergencies refers to the short amount of time in which the patient has the highest chance of survival. The goal of the Anomalous project is to reduce the time needed for diagnosis to fall within the Golden-Hour.

It has become a standard procedure to acquire an electrocardiogram (ECG) as soon as possible in case of heart conditions. Medical devices in use today have several defects: they are often too heavy, take a lot of time to be deployed and they perform analyses based on old and unreliable methods.

In recent years Computer Science has become interconnected with medicine: from e-health wearables to remote microscopic surgeries done with robots (thanks to the 5G network) or even to automated detection of anomalies, technology is no longer of support, but drives the evolution of care. Anomalous falls within this exciting field, as an open-source, full-stack solution for the acquisition and automatic analysis of ECG signals. This software recognizes common problems present in the ECG  and shows the results of its analysis to the medical staff  through a simple and intuitive user interface.

We adopted an innovative technique for acquiring the ECG signal, known as EASI, in order to reduce the time needed to prepare the patient. By doing so, we were able to lower the number of electrodes to be applied to the patient’s body by half, reconstructing the missing views of the heart with proven techniques of signal processing.

As shown in the flow chart, the data is filtered for noise and baseline shift after the acquisition. The filtered signal is then processed and analyzed using different signal processing and machine learning techniques.

Signal processing is used to identify specific points in the wave, called QRS complexes, that are associated with each beat. Using those results, we compute the beats per minute (BPM) to detect forms of irregularity in the rhythm like tachycardia and bradycardia. 

For what concerns the classification of the anomalies in the signal we relied on machine learning and, in particular, we explored different typologies of neural networks. A first version of our algorithm relied on recurrent neural network architectures (RNN), chosen for their flexibility in analyzing time-series data, but we later developed a convolution-based neural network (CNN), which offered better results in terms of accuracy. One of the greatest challenges we faced was to find a rich and reliable dataset to train our neural networks. This is common to many machine learning problems as data, especially in the medical field, is often held private and not released to the public. The dataset of our choice came from PhysioNet and required a significant amount of preprocessing before use.

The last phase of our project was to develop a user interface tailored for the target audience of Anomalous: medical staff and paramedics. We focused on eliminating the need for a manual research of the problem, by presenting both a classic visualization of the ECG and a direct view on the detected anomalies, identified by a letter and displayed with a dedicated graph.