A software for visualization of high-resolution long-duration time series and associated segmentations

Christoffer Simonsen1 and Bjørn-Jostein Singstad2
1University of South-Eastern Norway, 2Akershus University Hospital


Abstract

Introduction: Visualizing and analyzing long-duration, high-resolution physiological signals, such as Holter-ECGs, is essential for diagnosing and monitoring cardiac disorders like arrhythmias, which occur unpredictably. However, reviewing high-resolution time series (>500 Hz) over long periods (>24 hours) is difficult, both for manual inspection and for rendering the data in a clinically meaningful way. Additionally, machine learning now enables segmentation models that identify regions of interest in such data, but their outputs must also be displayed so that clinicians can easily interpret and use the results.

Methods: In this work, we use a seven-day ECG recording acquired from a pig with myocardial infarction, originally sampled at 1000 Hz. The ECG is annotated over time with segments denoting five different rhythm types. To enable efficient visualization, we apply a level-of-detail (LOD) sampling strategy by resampling and storing the ECG at 100 Hz, 20 Hz, and 1 Hz. The application dynamically switches among these three datasets based on the user-selected time window. In addition, we employ the largest-triangle three-bucket (LTTB) algorithm to further downsample the data while retaining the characteristic morphology of the ECG waveform. The visualization software is implemented in Python with Plotly and Flask. To evaluate performance, we measured latency as the time from issuing a command to completion of the requested view, performing 100 random zoom and time-span operations and then 100 repetitions of rendering an identical zoom and time span.

Results and Discussion: Loading the seven-day, 1000 Hz dataset and deriving the 1 Hz, 20 Hz, and 100 Hz datasets required 39 seconds. The 100 random rendering trials exhibited a median duration of 482 (IQR, 603) ms, whereas the corresponding identical rendering trials had a median duration of 1837 (IQR, 19) ms. Overall, the system enables sub-second response times for most interactions, but performance varies considerably across different visualization requests.