Project thumbnail image

College of Engineering Unit(s): 
Electrical Engineering and Computer Science

Team: 
Natalie Coppa and Julian Fortune

Project Description: 

Overview

The Paper ECG application enables cardiology professionals to convert digital scans or images of electrocardiogram (ECG) print-outs to digital signal data, and is the first free and open source application to provide such functionality. Users annotate the image with rectangular regions to mark where each signal is located and specify the scale information, and the application handles the rest of the process to create accurate digital signals. The source code is available on Github and contributions are welcome. The results of validating the digitization process on images with ground-truth labels will be published, and the application will be available on PhysioNet.

Background

The heart generates electricity with every heartbeat, and by using electrodes, specialized electronics can measure the changes in electrical potentials. The original ECG machines were analog, and they traced the potentials directly on paper in ink. The shapes of the potential graphs can be analyzed via visual examination by cardiologists to detect abnormalities and diagnose diseases. While this paper format is useful for diagnosis, it is not ideal for algorithms that analyze the signals, which expect a digital signal input. ECG machines transitioned to digital in the 70s and 80s, and the electrocardiograms are now printed based on digital signals. However, the digital data is often discarded since clinicians are primarily interested in the graphical format. As a result, large amounts of ECG data—especially for patients with rare diseases—are trapped in paper print form.

Technical Achievements

The application is programmed in Python using the Fman Build System and PyQt. Creating the graphics view to enable viewing an image and placing lead bounding boxes was a significant technical undertaking. Furthermore, the project involved the implementation of existing published ECG digitization algorithms that operate on individual leads, as well as the development of novel approaches for grid detection and signal extraction.

Impact

The application will be used by Dr. Tereschenko's lab at OHSU to enable numerical analysis on ECG data that is currently trapped in paper format. Due to the open source nature and the availability of binaries for all major operating systems, any other researchers interested in digitizing ECGs will have access to this tool to enable their work.

Future Work

The algorithms implemented in the application can continue to be tuned and improved, and new algorithms can be added. Furthermore, this tool will enable creating datasets that can be used for machine learning. There has been recent work demonstrating end-to-end ECG digitization (directly converting an entire ECG image into all 12 digital signals), but even adding machine learning-based algorithms for individual lead conversion will ameliorate noise reduction and may produce more accurate results.

Paper ECG — Overview
Paper ECG — Demo

Project Website(s):